Files
coder/cli/testdata/coder_list_--output_json.golden
T
Michael Suchacz 9cd38b5373 feat!: remove the Tasks API from coderd and codersdk (#28789)
Removes the Tasks API and task orchestration from coderd and codersdk:
the `/api/v2/tasks` handlers, task middleware and search filters, task
name generation, autobuild pause/resume logic, task notification
enqueues, telemetry, and the codersdk task types. Regenerates apidoc,
the API reference docs, and `typesGenerated.ts`.

**Breaking change:** the Tasks API is removed; requests to
`/api/v2/tasks` fail. Tasks was deprecated in v2.34.

**Stack context:** Coder Tasks removal stack (CODAGT-642): #28743
frontend → #28788 CLI → #28789 API → #28790 provisioner → #29084
notifications → #29085 build reasons → #29086 tables → #28750
permissions. The last four PRs replace the single data-drop migration
that used to live in #28750; each carries one concern and its own
migration number.

**Why:** with the UI (#28743) and CLI (#28788) gone, this deletes the
server surface. Database tables, RBAC, and notification templates stay
until the top of the stack so every layer builds and migrates
independently.

**What to scrutinize:**
- The `enable-ai-tasks` option is removed outright (review feedback):
configs still carrying `enableAITasks` fail to parse until the key is
deleted.
- provisionerdserver now writes `HasAITask: false` on template/build
flags; the column and these lines are dropped in #29085.
- `codersdk.ResourceTypeTask` stays so audit logs recorded before the
removal keep rendering.

**Validation:** `go build ./...`, `go vet ./...`, `go test
./codersdk/...`, site biome and tsc, CLI goldens regenerated, pre-commit
hooks.

**Size:** +242/-10,792 over 76 files; additions are regenerated
docs/goldens and test fixture updates.

> Created by Xum (AI agent) on behalf of @ibetitsmike.
2026-09-11 01:48:56 +00:00

95 lines
3.2 KiB
Plaintext

[
{
"id": "===========[workspace ID]===========",
"created_at": "====[timestamp]=====",
"updated_at": "====[timestamp]=====",
"owner_id": "==========[first user ID]===========",
"owner_name": "testuser",
"owner_avatar_url": "",
"organization_id": "===========[first org ID]===========",
"organization_name": "coder",
"template_id": "===========[template ID]============",
"template_name": "test-template",
"template_display_name": "",
"template_icon": "",
"template_allow_user_cancel_workspace_jobs": false,
"template_active_version_id": "============[version ID]============",
"template_require_active_version": false,
"template_use_classic_parameter_flow": false,
"latest_build": {
"id": "========[workspace build ID]========",
"created_at": "====[timestamp]=====",
"updated_at": "====[timestamp]=====",
"workspace_id": "===========[workspace ID]===========",
"workspace_name": "test-workspace",
"workspace_owner_id": "==========[first user ID]===========",
"workspace_owner_name": "testuser",
"template_version_id": "============[version ID]============",
"template_version_name": "===========[version name]===========",
"build_number": 1,
"transition": "start",
"initiator_id": "==========[first user ID]===========",
"initiator_name": "testuser",
"job": {
"id": "======[workspace build job ID]======",
"created_at": "====[timestamp]=====",
"started_at": "====[timestamp]=====",
"completed_at": "====[timestamp]=====",
"status": "succeeded",
"worker_id": "====[workspace build worker ID]=====",
"file_id": "=====[workspace build file ID]======",
"tags": {
"owner": "",
"scope": "organization"
},
"queue_position": 0,
"queue_size": 0,
"organization_id": "===========[first org ID]===========",
"initiator_id": "==========[first user ID]===========",
"input": {
"workspace_build_id": "========[workspace build ID]========"
},
"type": "workspace_build",
"metadata": {
"template_version_name": "",
"template_id": "00000000-0000-0000-0000-000000000000",
"template_name": "",
"template_display_name": "",
"template_icon": ""
},
"logs_overflowed": false
},
"reason": "initiator",
"resources": [],
"deadline": "====[timestamp]=====",
"max_deadline": null,
"status": "running",
"daily_cost": 0,
"matched_provisioners": {
"count": 0,
"available": 0,
"most_recently_seen": null
},
"template_version_preset_id": null,
"has_external_agent": false
},
"latest_app_status": null,
"outdated": false,
"name": "test-workspace",
"autostart_schedule": "CRON_TZ=US/Central 30 9 * * 1-5",
"ttl_ms": 28800000,
"last_used_at": "====[timestamp]=====",
"deleting_at": null,
"dormant_at": null,
"health": {
"healthy": true,
"failing_agents": []
},
"automatic_updates": "never",
"allow_renames": false,
"favorite": false,
"next_start_at": "====[timestamp]=====",
"is_prebuild": false
}
]