Skip to content
Getting startedQuick start

Quick start

A key from the bot, a model family, and the first request.

Model protocol

Guard gives access to the Claude, Kimi, Composer and Grok families through one address and one universal key — no sign-ups, KYC or VPN. Buy a package in @subscribe_ai_bot, get a gd-… key, and pick a client below.

How an application connects to models
API Key
gd-…
Base URL
https://api.guardrelay.ai
Your application
GUARD API
model
ClaudeKimiComposerGrok
Model families
Set the key and address in your application. GUARD API selects the family from the exact model id; the key has one shared balance.

1. Get a key

  1. @subscribe_ai_bot → Categories → API.
  2. Choose a package and an available payment method from the bot's live catalog.
  3. The bot sends a gd-… key — save it.

2. Connect a client

Claude CodeCLI on Windows / Mac / LinuxVS CodeClaude Code extension in a folderCodexOpenAI-compatible CLIKimi APIChat Completions and four modelsClaude CodeCLI on Windows / Mac / LinuxVS CodeClaude Code panel in a folderCline / Roo CodeAn agent in the editor on your keyPython / NodeSDK in your own codeHermes AgentNous Research terminal agentOpenClawLocal gateway assistantKimi CLIMoonshot AI terminal agentGrok CLIxAI console agentZCodeZ.ai desktop agent

3. First Claude request

Check the key with one command. macOS / Linux:

bash
curl https://api.guardrelay.ai/v1/messages \
  -H "x-api-key: gd-your-key" \
  -H "anthropic-version: 2023-06-01" \
  -H "content-type: application/json" \
  -d '{
    "model": "claude-haiku-4-5",
    "max_tokens": 32,
    "messages": [{"role": "user", "content": "Hello!"}]
  }'

Windows PowerShell:

powershell
$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_API_KEY = "gd-your-key"

$body = @{ model = "claude-haiku-4-5"; max_tokens = 32; messages = @(@{ role = "user"; content = "Hello!" }) } | ConvertTo-Json -Depth 5
Invoke-RestMethod -Uri "$env:ANTHROPIC_BASE_URL/v1/messages" -Method POST -Headers @{ "x-api-key" = $env:ANTHROPIC_API_KEY; "anthropic-version" = "2023-06-01"; "content-type" = "application/json" } -Body $body

3. First Kimi request

bash
curl -X POST https://api.guardrelay.ai/v1/chat/completions \
  -H "Authorization: Bearer gd-your-key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "k3",
    "messages": [{"role": "user", "content": "Hello!"}],
    "max_tokens": 128
  }'

3. First Grok request

Check the key with one command. The effort level is part of the model id and does not change the price, so any id works for a check: take cursor-grok-4.6-low.

bash
curl -X POST https://api.guardrelay.ai/v1/chat/completions \
  -H "Authorization: Bearer gd-your-key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "cursor-grok-4.6-low",
    "messages": [{"role": "user", "content": "Hello!"}],
    "max_tokens": 128
  }'

3. First Composer request

Check the key with one command. Composer has two ids: the regular composer-2.5 and composer-2.5-fast, which returns the same answer sooner and costs more.

bash
curl -X POST https://api.guardrelay.ai/v1/chat/completions \
  -H "Authorization: Bearer gd-your-key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "composer-2.5",
    "messages": [{"role": "user", "content": "Hello!"}],
    "max_tokens": 128
  }'

Set up with your own AI

Copy the prompt below into an AI that can work with files and a terminal. Replace only gd-… with your issued key. The prompt already carries the address, the header, the surfaces and the exact model ids of your family, so the AI does not have to configure anything from memory, and it is told to keep the key secret.

text
Help me connect Guard API, the Claude family. My key is: gd-…

Before making any changes:
1. Ask which client, CLI, or SDK I want to connect.
2. Detect my OS yourself: macOS, Windows, or Linux.
3. Open and read the current Guard API documentation at https://docs.guardrelay.ai/ : the page for the selected client and the model list page. Do not configure from memory.
4. Use only a connection method that the selected client or SDK supports officially. You may install missing dependencies and client tools when needed.

What is already known about this family, no need to work it out again:
- Address: https://api.guardrelay.ai , and for OpenAI-compatible clients the Base URL is https://api.guardrelay.ai/v1
- Header: Authorization: Bearer gd-… . Anthropic clients send x-api-key: gd-… instead.
- Surfaces: /v1/messages for Anthropic clients, plus the OpenAI-compatible Chat Completions and Responses surfaces under the base address https://api.guardrelay.ai/v1 . Use the one the selected client expects.
- Models: claude-opus-5, claude-sonnet-5, claude-haiku-4-5, claude-fable-5, claude-fable-5-1. Fable 5 and 5.1 are available without an actually applied server prompt.
- Use claude-haiku-4-5 for the check, it is the cheapest one.
- No anthropic.com login, subscription or VPN is required: the gd-… key is enough on its own.

Security requirements:
- Never print or repeat the full key in messages, logs, or command output.
text
Help me connect Guard API, the Kimi family. My key is: gd-…

Before making any changes:
1. Ask which client, CLI, or SDK I want to connect.
2. Detect my OS yourself: macOS, Windows, or Linux.
3. Open and read the current Guard API documentation at https://docs.guardrelay.ai/ : the page for the selected client and the model list page. Do not configure from memory.
4. Use only a connection method that the selected client or SDK supports officially. You may install missing dependencies and client tools when needed.

What is already known about this family, no need to work it out again:
- Address: https://api.guardrelay.ai , and for OpenAI-compatible clients the Base URL is https://api.guardrelay.ai/v1
- Header: Authorization: Bearer gd-…
- There are three surfaces: POST /v1/chat/completions, plus the Anthropic Messages surface and the OpenAI Responses surface at the same address. Kimi serves all three.
- It follows that Claude Code and Codex do work with Kimi. Their ready-made setups live in the documentation, on the Claude Code, VS Code and Codex pages: open the right page and follow it exactly rather than working from memory.
- Any client that speaks plain Chat Completions will also do: Cline, Roo Code, n8n, the Python SDK, the Node SDK.
- Models: k3 with a 1,048,576-token window, plus k3-256k, kimi-for-coding and kimi-for-coding-highspeed with a 262,144-token window.
- Always set an explicit max_tokens: without it the output half of the reserve is computed at 32,000 tokens.

Security requirements:
text
Help me connect Guard API, the Grok family. My key is: gd-…

Before making any changes:
1. Ask which client, CLI, or SDK I want to connect.
2. Detect my OS yourself: macOS, Windows, or Linux.
3. Open and read the current Guard API documentation at https://docs.guardrelay.ai/ : the page for the selected client and the model list page. Do not configure from memory.
4. Use only a connection method that the selected client or SDK supports officially. You may install missing dependencies and client tools when needed.

What is already known about this family, no need to work it out again:
- Address: https://api.guardrelay.ai , and for OpenAI-compatible clients the Base URL is https://api.guardrelay.ai/v1
- Header: Authorization: Bearer gd-…
- Surfaces: /v1/messages, /v1/chat/completions, /v1/responses. All three work, so Claude Code and Codex are both fine.
- Models: cursor-grok-4.6-low, cursor-grok-4.6-medium, cursor-grok-4.6-high, cursor-grok-4.6-xhigh. Each one has a paired -fast variant, eight ids in total.
- The effort level and the fast mode are part of the id and are not set by separate fields. The level does not change the price; the -fast variant costs more.
- Images are accepted and the context window is 500,000 tokens.
- Use cursor-grok-4.6-low for the check.
- The tools field is accepted. temperature, top_p, metadata and thinking are accepted without effect; tool_choice supports only the automatic form of the selected API. response_format, reasoning_effort and stop are unsupported. Check other fields against the selected API reference.

text
Help me connect Guard API, the Composer family. My key is: gd-…

Before making any changes:
1. Ask which client, CLI, or SDK I want to connect.
2. Detect my OS yourself: macOS, Windows, or Linux.
3. Open and read the current Guard API documentation at https://docs.guardrelay.ai/ : the page for the selected client and the model list page. Do not configure from memory.
4. Use only a connection method that the selected client or SDK supports officially. You may install missing dependencies and client tools when needed.

What is already known about this family, no need to work it out again:
- Address: https://api.guardrelay.ai , and for OpenAI-compatible clients the Base URL is https://api.guardrelay.ai/v1
- Header: Authorization: Bearer gd-…
- Surfaces: /v1/messages, /v1/chat/completions, /v1/responses. All three work, so Claude Code and Codex are both fine.
- There are two models: composer-2.5 and composer-2.5-fast. The second one returns the same answer sooner and costs more.
- Composer has no effort levels, it does not accept images, and its context window is 200,000 tokens.
- On a long input Composer answers from a short summary rather than from my full text. Split a large document into parts.
- Use composer-2.5 for the check.
- The tools field is accepted. temperature, top_p, metadata and thinking are accepted without effect; tool_choice supports only the automatic form of the selected API. response_format, reasoning_effort and stop are unsupported. Check other fields against the selected API reference.

Documentation sections

On this page