---
title: "Download an export file"
method: POST
path: "/v1/ai-cost-management/exports/{exportId}/downloads"
tags: ["exports"]
---

# Download an export file

`POST /v1/ai-cost-management/exports/{exportId}/downloads`

## Request

- Base URL: `https://global.api.konghq.com`
- URL: `https://global.api.konghq.com/v1/ai-cost-management/exports/{exportId}/downloads`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer
  - HTTP bearer
  - HTTP bearer

Returns a URL that serves one file of a `succeeded` export, either a data file or `manifest.json`, to a plain `GET` for 5 minutes. The service doesn't store the URL, and no operation returns it again.

- If `file` names no file of the export, the request fails with `400`.
- If the organization has no export with this identifier, or the identifier isn't a valid UUID, the request fails with `404`.
- If the export hasn't succeeded, or it has expired, the request fails with `409`.

## Path parameters

- `exportId` string, uuid, required

## Request body

- object
  - `file` string, required: The `name` of one of the export's `files`, or `manifest.json` for the manifest. The manifest describes the export and lists each data file with its size and SHA-256 digest.

## Response `200`

A short-lived URL for the file.

- object
  - `file` string, required: The name of the file that the URL serves.
  - `url` string, uri, required: The absolute URL that serves the file to a plain `GET`, without an `Authorization` header, until `expires_at`. A browser that opens it saves the file instead of displaying it. **The URL is a bearer credential: anyone who holds it can read the file until it expires.**
  - `expires_at` string, date-time, required: When the URL stops serving the file, 5 minutes after the request, as an RFC 3339 timestamp in UTC.

## Other responses

- `400`: The request body is invalid. `invalid_parameters` names each invalid field. A `file` that names no file of the export counts as invalid.
- `401`: The request has no valid access token. The token is missing, malformed, or expired, or it fails another check, and the response doesn't say which.
- `403`: The access token is valid, but its principal lacks the permission this operation requires. For an operation on one resource, the response doesn't reveal whether that resource exists.
- `404`: The organization has no export with this identifier.
- `409`: The export hasn't succeeded, or it has expired, so its files can't be downloaded.

## Changes

- **2026-11-19** `3b071797f6e4`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/kong/apis/konnect-api-go-sdk/changes/v1/ai-cost-management/exports/:exportId/downloads/post.md)

---

[API](https://skmtc.dev/kong/apis/konnect-api-go-sdk.md) - [All operations](https://skmtc.dev/kong/apis/konnect-api-go-sdk/llms.txt) - [OpenAPI document](https://skmtc.dev/kong/apis/konnect-api-go-sdk/revisions/3b071797f6e4?raw)
