# Programmatic SDK & Model Downloads API

This feature allows you to programmatically download SDK version packages and their associated model files using a single REST call. The API returns short-lived download links, making it ideal for integration into CI/CD pipelines, automated testing workflows, or custom deployment scripts.

## Endpoint Configuration

**Host:** `https://api.developers.krisp.ai/`

### `GET /v2/sdk/versions/{id}/download-urls`

Retrieves temporary download URLs for a specific SDK version and its associated model files.

***

## Request Parameters

### Path Parameters

| Parameter | Type    | Required | Description                                                                   |
| :-------- | :------ | :------: | :---------------------------------------------------------------------------- |
| `id`      | Integer |    Yes   | The unique version ID of the SDK. This ID can be found in your SDK Dashboard. |

### Headers

| Header          | Required | Description                                 |
| :-------------- | :------: | :------------------------------------------ |
| `Authorization` |    Yes   | Bearer token format: `api-key YOUR_API_KEY` |

***

## Example Request

```bash
curl --location 'https://api.developers.krisp.ai/v2/sdk/versions/329/download-urls' \
--header 'Authorization: api-key YOUR-API_KEY'
```

***

## Response Structure

The API returns a JSON object containing the short-lived AWS S3 download URLs for both the core SDK package and the corresponding AI model files.

### Example Response

```json
{
  "success": true,
  "data": {
    "expires_in": 300,
    "version": {
      "id": 42,
      "version": "1.3.4",
      "display_name": "VIVA",
      "os": "windows_x64",
      "platform": "server",
      "technologies": [
        "viva"
      ],
      "filename": "release.zip",
      "download_url": "s3.amazonaws.com..."
    },
    "models": [
      {
        "id": 1,
        "technology": "voice_isolation",
        "product": "viva",
        "filename": "model.zip",
        "download_url": "s3.amazonaws.com..."
      }
    ]
  }
}
```

### Response Object Attributes

| Field             | Type    | Description                                                                                 |
| :---------------- | :------ | :------------------------------------------------------------------------------------------ |
| `success`         | Boolean | Indicates whether the API request was successful.                                           |
| `data.expires_in` | Integer | The lifespan of the generated download URLs in seconds (e.g., 300 seconds = 5 minutes).     |
| `data.version`    | Object  | Contains the SDK metadata and its core download URL.                                        |
| `data.models`     | Array   | A list of model objects associated with the SDK, each containing its specific download URL. |

<br />