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

# API v1 authentication

> Authenticate requests to API v1.

API v1 requests use an API key.

Send the key as a bearer token:

```bash theme={null}
curl \
  -H "Authorization: Bearer <API_KEY>" \
  "https://spaportal.cz/api/v1/destinations"
```

API v1 also accepts the `access_token` query parameter:

```bash theme={null}
curl "https://spaportal.cz/api/v1/destinations?access_token=<API_KEY>"
```

Prefer the `Authorization` header for integrations that can set request headers.

## Authentication errors

| Status | Cause                                                                              |
| -----: | ---------------------------------------------------------------------------------- |
|  `400` | The key is missing, or the `Authorization` header does not use `Bearer <API_KEY>`. |
|  `401` | The key is invalid.                                                                |
