Skip to content

Tasks: API /send returns 409 when paused #1265

Closed
coder/coder
#21887

Description

@mafredri

Repo: coder/coder

Scope: Modify send endpoint to return 409 Conflict when task is paused, enabling client-side auto-resume.

Changes:

  • Modify POST /api/v2/tasks/{user}/{task}/send to check task/workspace status early
  • Return 409 Conflict with clear error message if task is paused
  • Error response should indicate task is paused and suggest resuming

Files:

  • coderd/aitasks.go

Acceptance criteria:

  • Returns 409 when task is paused
  • Error message clearly indicates task is paused
  • Existing behavior unchanged for active tasks
  • Response includes enough information for clients to auto-resume and retry send

Dependencies:

References:

Activity

  1. added theissue type on Jan 15, 2026
  2. self-assigned this
    on Feb 2, 2026
  3. added a commit that references this issue on Feb 6, 2026
    2549fc7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions