---
title: "Download every usage record in a range as CSV or JSONL [read]"
method: GET
path: "/billing/usage/export"
---

# Download every usage record in a range as CSV or JSONL \[read\]

`GET /billing/usage/export`

## Request

- Base URL: `https://api.agentsky.dev/v1`
- URL: `https://api.agentsky.dev/v1/billing/usage/export`
- Auth: none declared

One row per session call and one per API key, UTC day and kind, streamed. Columns: source, at, sessionId, sessionName, apiKeyId, apiKeyName, kind, model, provider, tool, calls, inputTokens, outputTokens, cachedInputTokens, cacheCreationTokens, listCostUsd, billedCostUsd, coveredBy (subscription when a connected plan paid), requestId. The same file Billing's export downloads.

## Query parameters

- `from` string, date
- `to` string, date
- `source` 'session' | 'api_key'
- `api_key_id` string
- `format` 'csv' | 'jsonl'

## Response `200`

The records

## Other responses

- `default`: Error — { error: { code, message, request_id } }

## Changes

- **2026-11-02** `e5e8f0229a99`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/agentsky/apis/agentsky-developer-api/changes/billing/usage/export/get.md)

---

[API](https://skmtc.dev/agentsky/apis/agentsky-developer-api.md) - [All operations](https://skmtc.dev/agentsky/apis/agentsky-developer-api/llms.txt) - [OpenAPI document](https://skmtc.dev/agentsky/apis/agentsky-developer-api/revisions/0d435187cd55?raw)
