Skip to content

ROADMAP-09 — P1 — DELETE /runs/{run_id} (cascade delete is wired but unreachable) #101

Open

Description

@getdownandcode

Series: ROADMAP — filed from the 2026-10-27 whole-project assessment · Backlog task: M15-T02 · Priority: P1 · Effort: extra small

Problem

Cascade delete of steps on runs is wired end-to-end (ON DELETE CASCADE, verified by the real-infra tier) but unreachable: there is not a single DELETE route. Operators cannot remove a run's audit trail via the API.

Depends on / pairs with ROADMAP-11 (ownership) so only the owning tenant can delete.

Evidence

  • agentkit/db/models.py:61,78 + migration line 45 — cascade wired
  • agentkit/api/routes.py — zero DELETE routes

Suggested fix / acceptance criteria

  • DELETE /runs/{run_id} → 204 on success, 404 identical to GET semantics
  • Ownership-scoped once ROADMAP-11 lands (state the interim rule if filed first)
  • Integration tests hermetic + real

Suggested branch / commit

feat/run-delete-endpoint · feat(api): add DELETE /runs/{run_id}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions