Delete Session
Delete a session: it disappears from the session lists and can no longer be opened or continued.
Soft delete (mirrors V2’s is_archived): the runs, events and usage records
stay in place so billing and analytics keep reconciling, and ZDR purge is the
only thing that ever destroys V4 content. Idempotent — deleting twice is a
no-op 204.
An in-flight run is cancelled first, and pending queued messages are
cancelled too; otherwise the drain would dispatch a follow-up run whose
session_archived_at is NULL and resurrect the session. Cancel is forwarded
to CP before anything is written (and outside the queue lock, per the
enqueue path’s ordering), so a CP failure (502) leaves the session visible
rather than hiding a run that is still burning credits.