Built-in Tables
In addition to custom tables you create, every project includes read-only built-in tables in the abstra schema. These tables give you SQL access to workflow data like tasks, users, roles, executions, and Page function calls.
Built-in tables are accessible via SQL SELECT queries only. All writes go through the Abstra API and Python SDK.
Querying built-in tables
Use the abstra schema prefix when querying:
Available tables
abstra.tasks
Stores all workflow tasks and their lifecycle data.
| Column | Type | Description |
|---|---|---|
id | uuid | Task ID |
created_at | timestamp | When the task was created |
updated_at | timestamp | Last update |
deleted_at | timestamp | Soft delete timestamp (null if active) |
project_id | uuid | Project ID |
type | varchar | Task type label used for routing |
payload | jsonb | Task payload data |
status | text | pending, locked, or completed |
target_stage_id | varchar | Destination stage ID |
created_by_stage_id | varchar | Stage that created this task |
created_by_execution_id | uuid | Execution that created this task |
completed_at | timestamp | When the task was completed |
completed_by | uuid | Execution that completed this task |
locked_at | timestamp | When the task was locked |
locked_by | uuid | Execution that locked this task |
abstra.executions
Records every stage execution in your workflow.
| Column | Type | Description |
|---|---|---|
id | uuid | Execution ID |
created_at | timestamp | When the execution started |
updated_at | timestamp | Last status change |
status | text | created, running, success, failure, etc. |
context | jsonb | Execution context (includes taskId if triggered by a task) |
project_id | uuid | Project ID |
build_id | uuid | Build that ran this execution |
stage_id | text | Stage identifier |
stage_run_id | uuid | Stage run ID (for forms threads) |
worker_id | uuid | Worker that ran the execution |
app_id | uuid | App ID (if applicable) |
pid | text | Process ID |
abstra.audit
Records Page function calls through JavaScript RPC in production and calls made by Smart Chat's run_page_function debugging tool. Calls can be queried by function, user, execution, outcome, and source.
| Column | Type | Description |
|---|---|---|
id | uuid | Audit record ID |
created_at | timestamp with time zone | When the audit record was stored |
project_id | uuid | Project ID |
build_id | uuid | Build ID (null for Smart Chat debugging calls) |
stage_id | varchar | Page stage ID (nullable) |
execution_id | uuid | Execution ID, when available (nullable) |
function_name | varchar | Name of the registered function called |
user_email | varchar | Authenticated Page user's email for browser calls; caller's email for Smart Chat calls (nullable) |
status | text | ok or error |
error | text | Error message, when present (nullable; truncated to 2,000 characters) |
duration_ms | integer | Call duration in milliseconds (nullable) |
source | text | browser or smart_chat; defaults to browser for older records |
This is a function-call log, not a complete administrative audit trail. It does not contain IP addresses, function arguments or return values, or before/after snapshots of data changes. Page rendering (__render__) and browser requests rejected before a registered function is called are not recorded here. Recording is best-effort: a failed audit write does not fail the function response. Local CLI preview does not write these records.
Do not infer a retention period or compliance guarantee from the table's availability. Confirm retention and audit requirements with the Abstra team.
abstra.users
Stores access control users for your project.
| Column | Type | Description |
|---|---|---|
id | uuid | User ID |
created_at | timestamp | When the user was added |
updated_at | timestamp | Last update |
deleted_at | timestamp | Soft delete timestamp |
email | varchar | User email |
project_id | uuid | Project ID |
abstra.roles
Stores access control roles.
| Column | Type | Description |
|---|---|---|
id | uuid | Role ID |
created_at | timestamp | When the role was created |
updated_at | timestamp | Last update |
deleted_at | timestamp | Soft delete timestamp |
project_id | uuid | Project ID |
name | varchar | Role name |
description | varchar | Role description |
abstra.users_roles
Junction table linking users to roles.
| Column | Type | Description |
|---|---|---|
id | uuid | Association ID |
created_at | timestamp | When the association was created |
deleted_at | timestamp | Soft delete timestamp |
user_id | uuid | References abstra.users.id |
role_id | uuid | References abstra.roles.id |
abstra.signup_policy
Stores email pattern rules for user sign-up.
| Column | Type | Description |
|---|---|---|
id | uuid | Policy ID |
project_id | uuid | Project ID |
email_patterns | jsonb | Array of allowed email patterns (e.g. ["@company.com"]) |
Example queries
Pending tasks by stage
Recent failed executions
Recent failed Page function calls
The result is a list of dictionaries that you can use in reports or export from your Python code. This example only retrieves the 20 most recent errors; it is not a complete audit export.