For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
DashboardProduct
DocsAPI ReferenceArchitecture
DocsAPI ReferenceArchitecture
  • System model
    • Monorepo architecture
    • Auth and workspace model
    • Data model
    • Runtime and operations
    • Known risks and drift
LogoLogo
DashboardProduct
On this page
  • Important fields
System model

Data model

Core database tables, migrations, and fallback state
||View as Markdown|
Was this page helpful?
Edit this page
Previous

Auth and workspace model

Next

Runtime and operations

Built with

The canonical schema file is packages/db/src/schema.sql. Migrations exist under both packages/db/migrations and packages/db/supabase/migrations.

Core workspace tables

organizations, users, and projects store workspace identity, membership, plan state, onboarding state, and project thresholds.

Secrets and keys

api_keys stores project key prefix and hash. provider_keys stores encrypted upstream credentials and currently has one provider row per project.

Evidence

request_logs stores request metadata, decision, internal reason, route, provider, model, geo fields, tokens, cost estimate, and timestamp.

Controls

ip_rules, geo_rules, and model_rules back network, region, and model controls.

Operations

workspace_audit_events and credit_purchases support audit history and purchased capacity.

Important fields

organizations.plan_tier
free | plus | business

Workspace plan tier. plus is the internal key for public Pro.

organizations.credit_logs_balance
number

Credit-backed capacity balance used by runtime quota logic.

projects.panic_mode
boolean

Internal storage field for public Sentry Mode.

provider_keys.encrypted_key
string

Encrypted upstream provider credential decrypted during forwarding.

geo_rules.scope
country | region

Region values are Panicly-defined buckets, not arbitrary map polygons.

Type coverage caveat

Research notes found workspace_audit_events in SQL while the typed Database interface did not fully cover it. Verify type coverage before generating typed DB docs.