Workflows are identified by name instead of an ID #2125

Closed
opened 2026-11-23 13:09:27 +00:00 by sam · 1 comment
Owner

A workflow has no ID. Its name is its identity everywhere: the primary key of runs.workflows (org_id, name, version), runs.workflow_drafts and runs.workflow_settings, the workflow column of runs.runs and events.triggers, the API paths (/api/workflows/{name}) and the dashboard URL (/workflows/<name>). AGENTS.md requires references to use immutable IDs, never names.

Because of this a workflow can't be renamed. Renaming would mean rewriting every run, trigger, draft and setting row, and every link to it would break. A deleted workflow's name can also be reused by a new one, and the new workflow then inherits the old one's runs and triggers.

Done when

  • Each workflow has a UUID that is fixed when it is created and never changes. Its versions, drafts, settings, runs and triggers reference that ID.
  • The API and dashboard address a workflow by its ID. The name is an editable label.
  • A workflow can be renamed without touching its runs or triggers.
  • Workflow documents can still name the workflow they call; the name is resolved to the ID when the document is saved.
A workflow has no ID. Its name is its identity everywhere: the primary key of `runs.workflows` (`org_id, name, version`), `runs.workflow_drafts` and `runs.workflow_settings`, the `workflow` column of `runs.runs` and `events.triggers`, the API paths (`/api/workflows/{name}`) and the dashboard URL (`/workflows/<name>`). AGENTS.md requires references to use immutable IDs, never names. Because of this a workflow can't be renamed. Renaming would mean rewriting every run, trigger, draft and setting row, and every link to it would break. A deleted workflow's name can also be reused by a new one, and the new workflow then inherits the old one's runs and triggers. ## Done when - Each workflow has a UUID that is fixed when it is created and never changes. Its versions, drafts, settings, runs and triggers reference that ID. - The API and dashboard address a workflow by its ID. The name is an editable label. - A workflow can be renamed without touching its runs or triggers. - Workflow documents can still name the workflow they call; the name is resolved to the ID when the document is saved.
sam added the bughigh labels 2026-11-23 13:09:27 +00:00
Author
Owner

Landed in 67ce2901a; task check passed.

Landed in 67ce2901a; task check passed.
sam closed this issue 2026-11-23 18:21:18 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sam/archie#2125