Jobs
Gets the status and result of a background job.#
/lmkit/v1/jobs/{jobId}Returns the current status of a background job. When the job completes, the 'result' field contains the original endpoint response. On a fleet, any node answers from the job's shared record; a result too large for the record lives on the node that ran the job, and a poll for it elsewhere answers 421 Misdirected Request naming that node's tag (follow the 202's Location on that node).
Parameters
| Name | In | Type | Description |
|---|---|---|---|
jobIdrequired | path | string | The job identifier returned in the 202 Accepted response. |
Responses
| Status | Type | Description |
|---|---|---|
| 200 | OK | |
| 404 | Not Found | |
| 421 | Misdirected Request |
curl -X GET "$LMKIT_ONE_URL/lmkit/v1/jobs/$JOBID" \
-H "Authorization: Bearer $LMKIT_API_KEY"Cancels a running background job.#
/lmkit/v1/jobs/{jobId}Attempts to cancel a job that is still processing. Has no effect on completed jobs. On a fleet, a cancel that reaches a node other than the one running the job is accepted (202) as a request the running node honours within its sync period; the response names that node's tag.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
jobIdrequired | path | string | The job identifier to cancel. |
Responses
| Status | Type | Description |
|---|---|---|
| 200 | application/json | OK |
| 202 | application/json | Accepted |
| 404 | Not Found | |
| 421 | Misdirected Request |
curl -X DELETE "$LMKIT_ONE_URL/lmkit/v1/jobs/$JOBID" \
-H "Authorization: Bearer $LMKIT_API_KEY"