app.automation_runs
TablaSeguridad a nivel de fila activa
The automation runs ledger (Section 7.3, ADR 0047): one run per automation and domain event, so an event never runs an automation twice. Written by the fan-out trigger and the worker RPCs only; readable by holders of org.automations.write.
Clave primaria: id
| Columna | Tipo | Admite nulos | Descripción |
|---|---|---|---|
| id | uuid | No | Primary key, UUID v7. |
| org_id | uuid | No | Owning org, derived from app.automations on insert; never accepted from the caller and never changed.Hace referencia a app.organizations.id |
| automation_id | uuid | No | Automation that ran.Hace referencia a app.automations.id |
| domain_event_id | uuid | No | Domain event that started the run.Hace referencia a app.domain_events.id |
| parent_run_id | uuid | Sí | Run whose action raised the event, when an automation caused it.Hace referencia a app.automation_runs.id |
| depth | smallint | No | How many automation runs led to this one: 0 for an event a person or the system raised. |
| run_status | app.automation_run_status | No | Queued, Running, Retrying, Succeeded, Failed or Skipped. |
| event_payload | jsonb | No | The event as webhooks send it (id, type, occurred_at, project_id, subject, data): the run's input, a provider payload (ADR 0002). |
| owner_person_id | uuid | Sí | Person the run acted as, set when it started.Hace referencia a app.people.id |
| job_id | uuid | Sí | automation.run job that carries the run and its retries.Hace referencia a app.job_queue.id |
| attempts | smallint | No | Times the worker started the run. |
| error_code | text | Sí | Rule code of the failure or skip, such as owner_left_org, loop_depth or rate_limited. |
| error_message | text | Sí | Why the run failed or was skipped, in words. |
| started_at | timestamp with time zone | Sí | When the worker first started the run. |
| finished_at | timestamp with time zone | Sí | When the run reached Succeeded, Failed or Skipped. |
| duration_ms | integer | Sí | Milliseconds from the first start to the end. |
| created_at | timestamp with time zone | No | When the row was inserted. Set by the database. |
| created_by | uuid | Sí | Person who inserted the row, or null for a platform process. Set by the database.Hace referencia a app.people.id |
| updated_at | timestamp with time zone | No | When the row last changed. Set by the database. |
| updated_by | uuid | Sí | Person who last changed the row, or null for a platform process. Set by the database.Hace referencia a app.people.id |
| deleted_at | timestamp with time zone | Sí | Soft delete time. A row with deleted_at set is ignored by every access helper. |