Jobs API
GET /api/v1/jobs
Section titled “GET /api/v1/jobs”List Jobs
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
status | query | string | null | no | |
kind | query | string | null | no | |
target | query | string | null | no | |
page | query | integer | no | |
per_page | query | integer | no |
Responses
| Status | Description | Schema |
|---|---|---|
| 200 | Successful Response | any |
| 422 | Validation Error | HTTPValidationError |
GET /api/v1/jobs/{job_id}
Section titled “GET /api/v1/jobs/{job_id}”Job Detail
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
job_id | path | integer | yes |
Responses
| Status | Description | Schema |
|---|---|---|
| 200 | Successful Response | any |
| 422 | Validation Error | HTTPValidationError |
POST /api/v1/jobs/{job_id}/cancel
Section titled “POST /api/v1/jobs/{job_id}/cancel”Cancel Job
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
job_id | path | integer | yes |
Responses
| Status | Description | Schema |
|---|---|---|
| 200 | Successful Response | any |
| 422 | Validation Error | HTTPValidationError |
GET /api/v1/jobs/{job_id}/events
Section titled “GET /api/v1/jobs/{job_id}/events”Job Events
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
job_id | path | integer | yes | |
after | query | integer | no | |
limit | query | integer | no |
Responses
| Status | Description | Schema |
|---|---|---|
| 200 | Successful Response | any |
| 422 | Validation Error | HTTPValidationError |
GET /api/v1/jobs/{job_id}/events/stream
Section titled “GET /api/v1/jobs/{job_id}/events/stream”Job Stream
Doc 05 §Streaming 1. line frames carry id: (the resume cursor);
progress and status do not. A terminal status closes the stream.
Auth is resolved once via a short-lived session in a thread, never a
Depends(get_db) seam, which for a StreamingResponse would stay open for
the life of the connection. authorize/require_entitlement are
still the ones enforcing it (called directly, not through FastAPI’s DI)
so this route stays on the same auth -> RBAC -> entitlement seam as its
siblings, in that order.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
job_id | path | integer | yes | |
last_event_id | query | integer | null | no |
Responses
| Status | Description | Schema |
|---|---|---|
| 200 | Successful Response | any |
| 422 | Validation Error | HTTPValidationError |