# Quickstart

> Connect GroundTruthData to Claude, ChatGPT, Cursor or any MCP client.

The MCP endpoint is:

```txt
https://mcp.groundtruthdata.co.za/mcp
```

You need an account and an active plan. [Create an account](/sign-in?mode=signup), [choose a plan](/pricing), then pick your client.

**Connector (OAuth) sign-in is coming at launch; until then, use an API key** (see the Claude Code
and Other MCP clients tabs).

### Claude (desktop & web)

1. Open **Settings → Connectors** and choose **Add custom connector**.
2. Name it `GroundTruthData` and paste the endpoint URL above. Leave the OAuth fields empty: Claude discovers our authorization server automatically.
3. Click **Connect**. You are sent to groundtruthdata.co.za to sign in and approve access.
4. In a new chat, enable the connector from the tools menu and ask, for example: *“Compare residential burglary in Stellenbosch and Drakenstein over the last three financial years, with sources.”*

### Claude Code

Use OAuth (recommended, opens a browser to sign in):

```bash
claude mcp add --transport http groundtruthdata https://mcp.groundtruthdata.co.za/mcp
```

Then run `/mcp` inside Claude Code and choose **Authenticate**.

Or use an API key from [your dashboard](/app/keys) (good for CI and headless agents):

```bash
claude mcp add --transport http groundtruthdata https://mcp.groundtruthdata.co.za/mcp \
  --header "Authorization: Bearer $GTD_API_KEY"
```

### ChatGPT

1. Open **Settings → Apps & Connectors**, enable developer mode if your plan requires it, and choose **Create**.
2. Paste the endpoint URL, choose **OAuth** as the authentication method and save.
3. Sign in at groundtruthdata.co.za when prompted, then enable the connector in a chat.

### Cursor

Add the server to `.cursor/mcp.json` in your project (or `~/.cursor/mcp.json` for all projects).
Keep the key in an environment variable so it never lands in the repository:

```json
{
  "mcpServers": {
    "groundtruthdata": {
      "url": "https://mcp.groundtruthdata.co.za/mcp",
      "headers": { "Authorization": "Bearer ${env:GTD_API_KEY}" }
    }
  }
}
```

Create the key in [your dashboard](/app/keys) and export it as `GTD_API_KEY` before starting
Cursor. Then open **Settings → MCP**, check that `groundtruthdata` shows its five tools, and ask a
question in Agent mode.

### Other MCP clients

Any client that supports the Streamable HTTP transport works. Either let it discover OAuth from
`https://mcp.groundtruthdata.co.za/.well-known/oauth-protected-resource`, or send an API key:

```json
{
  "mcpServers": {
    "groundtruthdata": {
      "type": "http",
      "url": "https://mcp.groundtruthdata.co.za/mcp",
      "headers": { "Authorization": "Bearer gtd_test_example" }
    }
  }
}
```

Replace `gtd_test_example` with your own key.

## Check it works

Ask your assistant to call `describe_catalog` (free, it does not count against your plan). It
lists the metrics, geographies and per-call limits. Then see the [Tool reference](/docs/tools).

> **Keep keys secret**
>
> API keys are shown once. Store them in your secrets manager or environment, never in a repository.
> Revoke a key from the dashboard the moment you suspect it leaked.
