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

# Voyant Data

> Travel data APIs behind one client: geography, aviation reference data, currency exchange, plus business data.

Voyant Data is the data layer of the platform. It bundles the reference and enrichment data that travel apps constantly need behind a single typed client and a single API token. Instead of integrating a separate vendor for airports, another for exchange rates, and another for reviews, you call them all through `@voyant-travel/data-sdk`.

The Data product is served behind the public gateway at `https://api.voyant.travel/data/{product}/v1/*`. Each one is a top-level namespace on the client.

## The data products

<CardGroup cols={2}>
  <Card title="Geo" icon="earth-americas" href="/docs/data/geo">
    Canonical travel geography: countries, regions, cities, ports, and waterways, plus language and timezone lookups.
  </Card>

  <Card title="Air" icon="plane" href="/docs/data/air">
    Aviation reference data: airports, airlines, and aircraft.
  </Card>

  <Card title="FX" icon="money-bill-transfer" href="/docs/data/fx">
    Currency exchange rates and the ISO 4217 currency catalog.
  </Card>

  <Card title="Business data" icon="star" href="/docs/data/business-data">
    Reviews, hotels, restaurants, and experiences from Google and TripAdvisor.
  </Card>
</CardGroup>

## Install and call

```bash theme={null}
pnpm add @voyant-travel/data-sdk
```

```ts theme={null}
import { createVoyantDataClient } from "@voyant-travel/data-sdk";

const client = createVoyantDataClient({
  apiKey: process.env.VOYANT_API_KEY!,
});

const countries = await client.geo.countries.list();
const lhr = await client.air.airports.get("LHR");
const eurUsd = await client.fx.pair("EUR", "USD", 100);
```

## Response envelopes

The Data SDK preserves the API envelopes so you never lose pagination metadata:

* List and search methods return `ListResponse<T>`, shaped `{ data, totalCount, nextCursor? }`.
* Single-item methods return `SingleResponse<T>`, shaped `{ data }`.

Paginate by passing `nextCursor` back on the next call.

## Authentication and scopes

Authentication is a Voyant API token as a bearer token against `https://api.voyant.travel`. Tokens are scoped per sub-product:

| Namespace              | Scope                   |
| ---------------------- | ----------------------- |
| `client.geo.*`         | `data:geo:read`         |
| `client.air.*`         | `data:air:read`         |
| `client.fx.*`          | `data:fx:read`          |
| `client.reviews.*`     | `data:reviews:read`     |
| `client.hotels.*`      | `data:hotels:read`      |
| `client.restaurants.*` | `data:restaurants:read` |
| `client.experiences.*` | `data:experiences:read` |

See [Authentication](/docs/sdks/authentication) for how tokens and scopes work across the SDKs.

## Errors

Non-2xx responses throw `VoyantApiError` with `status`, `requestId`, and `body`. The Data API also returns a stable `code` on its error bodies, typed as `DataErrorCode`: `NOT_FOUND`, `INVALID_REQUEST`, `INVALID_CURSOR`, `UPSTREAM_FAILED`, `INTERNAL_AUTH_REQUIRED`, and `RATE_LIMITED`. See [Errors and transport](/docs/sdks/errors-and-transport).
