---
title: "GET /v1/jobs/{jobId}/download/{artifactType}"
description: "Get a download link for one of a job's files by type"
full: true
---

**Auth:** required. Send an `ivy_` API key (`Authorization: Bearer ivy_…` or `X-Ivy-Api-Key`), a Clerk session JWT (`Authorization: Bearer …`) or the Clerk `__session` cookie (browser sessions). See [Authentication](/docs/api/authentication).

Returns a fresh presigned download link for one file of a job you can read, picked by `artifactType` (for example `pdb`, `zip`, `csv` or `report`). Three types are generated on request rather than stored: `fits` (curve fits), `qc` (a QC summary CSV) and `procurement` (a procurement JSON).

Send `Accept: application/json` to get the link in a JSON body. With `proxy=true` the file is streamed back through the API instead. To list all of a job's files with their links in one call, use `GET /api/v1/jobs/{jobId}/artifacts`.

A job you cannot read, a job outside your API key's project scope and a job that does not exist all return a 404 or 403 without saying which.

## Request

#### Path parameters

- `jobId` (string (uuid)) —
Job UUID.

- `artifactType` (string) —
Which file to link, by type.

#### Query parameters

- `proxy` (enum (&quot;true&quot;)) —
`true` to stream the file through the API instead of returning a link.

#### Headers

- `Accept` (string) —
Send `application/json` to receive the link as JSON.

## Responses

### `200` OK

The download link as JSON, or the file when streamed

Response shape:

- `success` (enum (true)) —

- `presigned_url` (string) —
Short-lived download link.

- `s3_key` (string) —

- `bucket` (string) —

- `expires_in` (integer) —
Seconds the link stays valid.

- `artifact_type` (string) —

- `job_id` (string (uuid)) —

### `400` Bad Request

The job id or artifact type is missing or invalid

Response shape: `object`

### `401` Unauthorized

Authentication required

Response shape: `object`

### `403` Forbidden

You cannot read the job

Response shape: `object`

### `404` Not Found

The job does not exist or is not visible to you (including a job outside your API key's project scope), or it has no file of that type

Response shape: `object`

### `405`

The method is not GET or HEAD

Response shape: `object`

### `429` Too Many Requests

Rate limit exceeded

Response shape: `object`

### `500` Internal Server Error

Preparing the download failed

Response shape: `object`

**curl**

```bash
curl -X GET 'https://ivybiosciences.com/api/v1/jobs/{jobId}/download/{artifactType}' \
  -H "Authorization: Bearer $IVY_API_KEY"
```

**JavaScript**

```js
const res = await fetch('https://ivybiosciences.com/api/v1/jobs/{jobId}/download/{artifactType}', {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${process.env.IVY_API_KEY}`,
  },
});
const data = await res.json();
```

**Python**

```python
import os, requests

res = requests.get(
    "https://ivybiosciences.com/api/v1/jobs/{jobId}/download/{artifactType}",
    headers={"Authorization": f"Bearer {os.environ['IVY_API_KEY']}"},
)
data = res.json()
```
