> For the complete documentation index, see [llms.txt](https://gitbook-docs.coinmetrics.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gitbook-docs.coinmetrics.io/cm-api-spec/atlas/jobs/get-job-by-id.md).

# Get job by ID

Returns job details by job ID. If job is not found empty result is returned.

```json
{"openapi":"3.0.2","info":{"title":"Coin Metrics API v4","version":"4.0.0"},"tags":[{"name":"Jobs","description":"Jobs API endpoints\n\n**Endpoints on this page:**\n- `GET /jobs` — Get job by ID"}],"servers":[{"url":"https://api.coinmetrics.io/v4"},{"url":"wss://api.coinmetrics.io/v4"},{"url":"https://community-api.coinmetrics.io/v4"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"description":"Coin Metrics API key can be specified as `?api_key=` query parameter.","in":"query","name":"api_key","type":"apiKey"}},"parameters":{"JobIds":{"description":"Job identifier.","in":"query","name":"ids","required":true,"schema":{"type":"string"}},"Pretty":{"description":"Human-readable formatting of JSON responses.","in":"query","name":"pretty","schema":{"type":"boolean","default":false}},"IncludeJobWarnings":{"description":"Flag to include warnings generated by job execution in the response.","in":"query","name":"include_warnings","schema":{"type":"boolean","default":false}}},"responses":{"JobsDetails":{"description":"Jobs details.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobsDetailsResponse"}}}},"Unauthorized":{"description":"Requested resource requires authorization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"BlockchainForbidden":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Requested resource is not available with supplied credentials."}},"schemas":{"JobsDetailsResponse":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/JobsDetails"}},"required":["data"]},"JobsDetails":{"type":"array","items":{"$ref":"#/components/schemas/JobDetails"}},"JobDetails":{"type":"object","properties":{"id":{"description":"Job ID","type":"string"},"status":{"$ref":"#/components/schemas/JobStatus"},"creation_time":{"description":"Job creation time. Returned for all statuses.","type":"string"},"completion_time":{"description":"Job completion time. Returned for the \"completed\", \"failed\" and \"expired\" statuses.","type":"string"},"expiration_time":{"description":"Results expiration time. Returned for the \"completed\" and \"expired\" statuses.","type":"string"},"error":{"description":"Error. Returned only for \"failed\" status.","allOf":[{"$ref":"#/components/schemas/ErrorObject"}]},"results":{"description":"Array with results of the job execution. Returned only for the \"completed\" status.","type":"array","items":{"$ref":"#/components/schemas/JobResult"}},"warnings":{"description":"Warnings generated by the job execution. Returned only for the `completed` status and if `include_warnings` is set to true.","type":"array","items":{"type":"string"}}},"required":["id","status","creation_time"]},"JobStatus":{"type":"string","description":"Job status.","enum":["running","completed","failed","expired"]},"ErrorObject":{"properties":{"type":{"description":"Error type string. Can be used for error identification.","type":"string"},"message":{"description":"Human-friendly error description. Can be amended without prior notification. Do not use for error identification in your code.","type":"string"}},"required":["type","description"],"type":"object"},"JobResult":{"type":"object","properties":{"url":{"description":"Job result URL","type":"string"}},"required":["url"]},"ErrorResponse":{"properties":{"error":{"$ref":"#/components/schemas/ErrorObject"}},"required":["error"],"type":"object"}}},"paths":{"/jobs":{"get":{"summary":"Get job by ID","description":"Returns job details by job ID. If job is not found empty result is returned.","operationId":"getJobById","tags":["Jobs"],"parameters":[{"$ref":"#/components/parameters/JobIds"},{"$ref":"#/components/parameters/Pretty"},{"$ref":"#/components/parameters/IncludeJobWarnings"}],"responses":{"200":{"$ref":"#/components/responses/JobsDetails"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/BlockchainForbidden"}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://gitbook-docs.coinmetrics.io/cm-api-spec/atlas/jobs/get-job-by-id.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
