GET
/v1/runs/{runId}/files/{fileId}/contentStream the bytes of a file attached to this run; 404 covers cross-tenant, other-client and unlinked ids.
Streams the bytes of one file attached to this run — an image the run generated, or one that was attached to it. List them first with GET /v1/runs/{runId}, which returns each attachment's fileId.
The file must be attached to *this* run: a file id that belongs to the tenant but not to this run returns 404, as do an unknown run, an unknown file, and another tenant's run.
**Scoped to the calling API-key client:** only a run this client started is reachable — any of its keys, rotations included. Another client's run in the same tenant, a run started before clients were recorded, and another tenant's run are all the same 404 as an unknown id.
Request
Path & query
| Name | In | Type | Required |
|---|---|---|---|
| runId | path | uuid | required |
| fileId | path | uuid | required |
Example
shell
curl https://api.askamy.co.za/v1/runs/{runId}/files/{fileId}/content \
-H "X-Api-Key: $AMY_API_KEY"Responses
| Status | Description | Body |
|---|---|---|
| 200 | OK | — |
| 401 | Unauthorized | ProblemDetails |
| 404 | Not Found | ProblemDetails |
| 502 | Bad Gateway | ProblemDetails |
Schemas
ProblemDetails
| Field | Type | Required |
|---|---|---|
| type | string | null | optional |
| title | string | null | optional |
| status | integer | null | optional |
| detail | string | null | optional |
| instance | string | null | optional |