# Agent setup

> Point Claude Code, Cursor, Codex, Copilot or any other coding agent at the SightRadar docs so it integrates the API from the source instead of guessing.

Source: https://sightradar.com/docs/agent-setup

Every page on this site has a plain-Markdown twin, and the whole corpus is available in two files an agent can fetch in one request. Give your agent those URLs and it will read the same reference you do.

## The URLs an agent should know

| What                      | URL                                                                            | Use it for                                                                                      |
| ------------------------- | ------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------- |
| Map of everything         | `https://sightradar.com/llms.txt`                                              | Discover what exists, then fetch only the page needed. Small.                                   |
| Full corpus               | `https://sightradar.com/llms-full.txt`                                         | Every page inlined. One fetch, whole picture.                                                   |
| Any docs page as Markdown | append `.md` to the page URL, e.g. `https://sightradar.com/docs/quickstart.md` | Clean text for one topic. Also linked from each page as `rel="alternate" type="text/markdown"`. |
| API reference index       | `https://sightradar.com/docs/api.md`                                           | Every endpoint with its method, path and page link.                                             |
| OpenAPI 3.1 spec          | `https://api.sightradar.com/openapi.json`                                      | Exact request and response schemas, for generating clients or validating calls.                 |

The **Copy as Markdown** button at the bottom of any page puts that page's Markdown on your clipboard for pasting straight into a prompt.

## Project instructions

Drop this into the file your agent reads at the start of a session (`CLAUDE.md`, `AGENTS.md`, `.cursor/rules`, `.github/copilot-instructions.md`):

```markdown title="AGENTS.md"
## SightRadar face recognition API

- Docs index: https://sightradar.com/llms.txt (fetch first, then the specific page).
- Any docs page is available as Markdown by appending `.md` to its URL.
- OpenAPI 3.1 spec: https://api.sightradar.com/openapi.json
- Base URL https://api.sightradar.com, auth `Authorization: Bearer $SIGHTRADAR_API_KEY`.
- Billing is per photo processed, never per face; send an `Idempotency-Key` on retries.
- Official SDKs: `pip install sightradar`, `npm install sightradar`.
- Never put the API key in client-side code.
```

## Per-agent notes

_Claude Code_
Add the block above to `CLAUDE.md` in your repo. Claude Code fetches URLs on demand, so pointing it at `llms.txt` is enough; ask it to "read [https://sightradar.com/docs/quickstart.md](https://sightradar.com/docs/quickstart.md)" for a specific topic.

_Cursor_
Add the block to a rules file such as `.cursor/rules/sightradar.mdc` or use **@Docs → Add new doc** with `https://sightradar.com/llms-full.txt` so the corpus is indexed for the whole workspace.

_Codex_
Add the block to `AGENTS.md`. Codex reads it at the start of every task and can fetch the Markdown URLs when it needs detail.

_Copilot_
Add the block to `.github/copilot-instructions.md`. In chat, paste a page's Markdown (Copy as Markdown) when you want Copilot to work from a specific endpoint's contract.

## Generating a client

The spec is a standard OpenAPI 3.1 document. Any generator works, but the [official SDKs](/docs/sdks/python) already wrap the customer-facing surface in Python and Node, with typed errors, and are the better starting point for those languages.

## Keep the key out of the agent's context

An API key spends your credits. Put it in an environment variable (`SIGHTRADAR_API_KEY`, which both SDKs read) and tell the agent to reference the variable, never the value. See [Authentication](/docs/authentication#keep-keys-off-the-client).
