Cursor can call an OpenAI-compatible address, and Guard serves one. Put the key into the editor's own settings and the built-in agent starts working through Guard.
- Cursor → Settings → Models.
- Scroll past the model list and expand API Keys.
- Paste your
gd-…into OpenAI API Key and turn on the switch next to it. - Turn on Override OpenAI Base URL and set the address below.
https://api.guardrelay.ai/v1Type the id you need into Add or search model and add it, then make sure its switch is on.
| id for Cursor | Context | When to use |
|---|---|---|
claude-sonnet-5 | 1M | default: price and quality |
claude-opus-5 | 1M | complex code and long agent runs |
claude-opus-4-8 | 1M | the previous flagship |
claude-haiku-4-5 | 200K | fast and cheap |
claude-fable-5 | 1M | without an applied server prompt |
claude-fable-5-1 | 1M | without an applied server prompt |
Loose spellings such as sonnet-5, opus-5 or Claude-Sonnet-5 are accepted too: the server normalizes them.
| id for Cursor | Context | When to use |
|---|---|---|
k3 | 1M | default: the largest window |
k3-256k | 256K | 262,144-token window; the same base rate as k3 |
kimi-for-coding | 256K | code and tool work |
kimi-for-coding-highspeed | 256K | the same, but faster |
Type the id exactly, with no shortening and no spelling of your own: Cursor will not fill in a short form.
Grok 4.6 effort is part of the ID: low, medium, high, xhigh; each has a -fast variant with a separate rate. Grok 4.5 is removed. Composer has two IDs. Copy the full string from Models.
The full table for every family is on the Models page.
New Chat → pick the added model in the list next to the input → send a request. Restarting Cursor is not needed.
The built-in agent works with supported capabilities: long conversations, reading and searching project files, editing and creating code, running terminal commands and showing the output, images and attachments, replies in a strict format. Responses stream, and you can stop and continue them. Image, attachment and strict-format support depends on the selected family and API; for example, Composer does not accept images.
Web search and opening pages by link are done by Cursor on its own and returned to the model — no separate charge for that.
Cursor sends a large service block with every message — tool descriptions and the agent’s working rules. On a confirmed cache hit, this repeated input is charged at the lower cache-read rate.
A sufficiently large first request may write the cache, and later matching requests may read it at a lower rate. Hits and savings are not guaranteed: check cached tokens, tariff and discount in request history.
Your Cursor subscription pays for the editor. Requests made with your gd-… are charged to the Guard balance and do not count against Cursor limits — see the dashboard.
| What you see | What to do |
|---|---|
The model you chose is not available | That id is not in the Guard catalog. Check the table above or the Models page. |
| An error about a resource that cannot be found | Make sure the address ends with /v1 and has no extra path. |
| An authorization error | The key was not copied in full, or the OpenAI API Key switch is off. |
| A built-in Cursor model answers | In the list next to the input pick the model you added. |
| An old chat behaves as before | Settings apply to new chats — open New Chat. |