> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ticksupply.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Ticksupply API Documentation

> Access cryptocurrency market data with the Ticksupply API. Subscribe to real-time data streams, manage subscriptions, and export historical tick data.

# Welcome to Ticksupply

Ticksupply provides institutional-grade cryptocurrency market data through a simple REST API. Subscribe to real-time data streams from major exchanges and export historical tick-level data for analysis and backtesting.

<CardGroup cols={2}>
  <Card title="Quickstart" icon="rocket" href="/getting-started/quickstart">
    Get your first data export in under 5 minutes
  </Card>

  <Card title="Client SDKs" icon="boxes-stacked" href="/getting-started/sdks">
    Official Python and Rust client libraries
  </Card>

  <Card title="API Reference" icon="code" href="/api-reference/overview">
    Explore the complete API documentation
  </Card>

  <Card title="Guides" icon="book-open" href="/guides/subscription-lifecycle">
    Learn the patterns: subscriptions, exports, pagination, errors
  </Card>
</CardGroup>

## What you can do

### Browse available data

Use the [Catalog API](/api-reference/overview#catalog) to explore available exchanges, instruments, and data stream types:

* **Exchanges**: Binance, Bybit, OKX, and more coming soon
* **Instruments**: Thousands of trading pairs (BTCUSDT, ETHUSDT, etc.)
* **Stream types**: Trades, order book depth, klines

### Subscribe to data streams

Create [subscriptions](/api-reference/subscriptions/create-subscription) to start collecting real-time data. Data is stored securely and available for export at any time.

### Export historical data

Generate [exports](/api-reference/exports/create-export) for any time range within your subscription periods. Download compressed CSV files with tick-level precision, using a built-in or [custom export schema](/guides/export-schemas) to control column layout.

## API features

<AccordionGroup>
  <Accordion title="API key authentication">
    Secure authentication using API keys passed in the `X-Api-Key` header. Generate keys from your dashboard with granular permissions.
  </Accordion>

  <Accordion title="Rate limiting">
    Rate limits of 200 requests/minute and 10,000 requests/hour per account. Response headers report your remaining budget so you can stay within bounds.
  </Accordion>

  <Accordion title="Idempotency">
    Safe retries using the `Idempotency-Key` header. Duplicate requests return the original response without side effects.
  </Accordion>

  <Accordion title="Cursor-based pagination">
    Efficient pagination for large result sets using cursor tokens. Stable ordering even as data changes.
  </Accordion>

  <Accordion title="Structured errors">
    Consistent error responses with machine-readable codes, human-friendly messages, and `X-Request-Id` headers for debugging.
  </Accordion>
</AccordionGroup>

## Quick example

All requests go to `https://api.ticksupply.com/v1` and authenticate with the `X-Api-Key` header. See the [API Reference overview](/api-reference/overview) for request/response conventions.

```bash cURL theme={"system"}
# 1. List available exchanges
curl -H "X-Api-Key: YOUR_API_KEY" \
  https://api.ticksupply.com/v1/exchanges

# 2. Get datastreams for BTCUSDT trades
curl -H "X-Api-Key: YOUR_API_KEY" \
  "https://api.ticksupply.com/v1/datastreams?exchange=binance&instrument=BTCUSDT&stream_type=trades"

# 3. Create a subscription (use datastream_id from step 2)
curl -X POST -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"datastream_id": 123}' \
  https://api.ticksupply.com/v1/subscriptions

# 4. Create an export (replace timestamps with your range)
#    start_time / end_time are nanoseconds since Unix epoch
curl -X POST -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"datastream_id": 123, "start_time": "1703116800000000000", "end_time": "1703203200000000000"}' \
  https://api.ticksupply.com/v1/exports
```

Poll the export until `status` is `succeeded`, then fetch presigned download URLs — see the [Quickstart](/getting-started/quickstart) for the full end-to-end flow.

## Getting help

<CardGroup cols={2}>
  <Card title="Support" icon="envelope" href="mailto:support@ticksupply.com">
    Contact our support team for assistance
  </Card>

  <Card title="Status" icon="signal" href="https://status.ticksupply.com">
    Check API status and incident history
  </Card>
</CardGroup>

<Note>
  Include the `X-Request-Id` header value from error responses when contacting support. This helps us quickly identify and resolve issues.
</Note>
