Skip to content

Add no-code policy editor in admin UI #51

@haasonsaas

Description

@haasonsaas

Context

Gate requires writing raw Rego to create policies. This blocks security teams who are not developers from owning policies directly. Formal.ai offers a no-code policy editor — this is a key adoption differentiator for the security-team buyer persona.

Proposal

Build a visual policy builder in the embedded admin UI that emits valid Rego:

  • Rule wizard UI: structured form for common patterns (allow/deny by role, IP range, time window, query type, resource)
  • Conditional builder: drag-and-drop or form-based condition chains (AND/OR/NOT)
  • Preview pane: shows the generated Rego so engineers can review/tweak
  • Round-trip editing: policies created in the UI can be edited as raw Rego, and simple Rego can be loaded back into the visual editor
  • Does NOT replace Rego — sits on top of it. Power users still write raw Rego.

Acceptance Criteria

  • Visual policy builder generates valid Rego for at least 5 common patterns
  • Generated policies pass Gate's existing Rego v1 strict validation
  • Preview shows generated Rego before saving
  • Policies created visually go through the same draft → dry_run → active lifecycle
  • Non-technical user can create "block DDL for non-admin roles" without writing code

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions