
With a sandbox_ key, the API answers in the same format, but calls no model and charges nothing. It is how you check the address, the key and the model name in Aider before you spend credits or points.
1. A test key
In the API Center, create a key in Sandbox mode, with ai:read and ai:write. It starts with sandbox_. Put it in the variable Aider reads, instead of the prod_ key. On Linux and macOS:
export OPENAI_API_KEY="sandbox_..."
On Windows, close the terminal and open a new one after setx:
setx OPENAI_API_KEY "sandbox_..."
2. One request only
With --message, Aider sends one message, shows the answer and exits:
cd my-project
aider --model openai/moonshotai/kimi-k2.7-code --message "hello"
3. The right answer
If everything is right, the answer is always this, whatever you ask:
Resposta de teste (sandbox).
Nothing is spent: the tokens come back as zero and the balance does not change. The "Unknown context window size" warning may still show, because it comes from Aider. With this key Aider cannot change files, because the answer is always the same.
If you see something else
| What you see | What it means |
| 401 unauthorized | The key is wrong or Aider did not read the variable. Open a new terminal. |
| 404 model_not_found | The model id is wrong. After openai/ comes the full id, with the slash. |
| 404 not_found | The address is wrong: it must end in /v1. |
| 403 insufficient_scope | The key does not have ai:write. |
| Once the test answer shows, switch the variable to the prod_ key and open a new terminal. With the sandbox_ key, the model list, the prices and the balance the API shows are the real ones. |
|
Want to try our models in Aider without spending? Visit the Coding with AI page. See Coding with AI |
RECOMMENDED PRODUCT Web hosting with cPanel Domain and SSL included, daily backups and the panel you already know. from $6.60/mo (3-year plan, with coupon) See plans |











