Create a key
In your profile, API tab. The key starts with sk-slafy- and is shown once, so save it.
Cursor, Claude Code, Codex, Cline and other agents work with a Slafy key: set our API address and your key, and requests are paid from your balance. Step-by-step guides below.
In your profile, API tab. The key starts with sk-slafy- and is shown once, so save it.
For the OpenAI format the address is https://slafy.co/v1, for Anthropic https://slafy.co. Pass the key as Bearer or x-api-key.
Cursor chat and agent with your Slafy key, OpenAI format
https://slafy.co/v1. Click Verify.claude-sonnet-5-5 and gpt-6.1-sol.Tab autocomplete in Cursor runs on Cursor’s own models; your key is used in chat and the agent. Cursor sends requests to our API from its own servers, so no other network setup is needed.
Anthropic’s terminal agent, Messages format
Set the environment variables and run claude. No Anthropic account sign-in needed.
export ANTHROPIC_BASE_URL="https://slafy.co" export ANTHROPIC_AUTH_TOKEN="sk-slafy-your_key" export ANTHROPIC_MODEL="claude-sonnet-5-5" export ANTHROPIC_DEFAULT_HAIKU_MODEL="claude-haiku-5-5" claude
$env:ANTHROPIC_BASE_URL = "https://slafy.co" $env:ANTHROPIC_AUTH_TOKEN = "sk-slafy-your_key" $env:ANTHROPIC_MODEL = "claude-sonnet-5-5" $env:ANTHROPIC_DEFAULT_HAIKU_MODEL = "claude-haiku-5-5" claude
Add the variables to ~/.claude/settings.json:
{
"env": {
"ANTHROPIC_BASE_URL": "https://slafy.co",
"ANTHROPIC_AUTH_TOKEN": "sk-slafy-your_key",
"ANTHROPIC_MODEL": "claude-sonnet-5-5",
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "claude-haiku-5-5"
}
}You can switch models with the /model command right in Claude Code, for example to claude-opus-5-5.
OpenAI’s terminal agent, Responses format
~/.codex/config.toml:model = "gpt-6.1-sol" model_provider = "slafy" [model_providers.slafy] name = "Slafy" base_url = "https://slafy.co/v1" env_key = "SLAFY_API_KEY" wire_api = "responses"
SLAFY_API_KEY variable and run codex.export SLAFY_API_KEY="sk-slafy-your_key" codex
On Windows, set the variable with setx SLAFY_API_KEY "sk-slafy-your_key" and reopen the terminal.
Ask Codex to draw an icon, a mockup or an illustration. GPT models draw with the built-in image_generation tool in the Responses API, and the image generation skill calls the Images API. The skill needs the same address and key:
export OPENAI_BASE_URL="https://slafy.co/v1" export OPENAI_API_KEY="sk-slafy-your_key"
Slafy accepts the names gpt-image-2, gpt-image-1 and sends them to gpt-image-2.5-sunburst. One image costs $0.199, which is 500,000 balance tokens, the text of the answer is billed as usual.
Agent in VS Code, “OpenAI Compatible” provider
https://slafy.co/v1sk-slafy-your_keyclaude-sonnet-5-5For Claude, GPT, Gemini and Grok models turn on Supports Images: they understand screenshots.
Agent in VS Code, “OpenAI Compatible” provider
https://slafy.co/v1sk-slafy-your_keyclaude-sonnet-5-5Assistant for VS Code and JetBrains
Add the model to ~/.continue/config.yaml:
name: Slafy
version: 1.0.0
schema: v1
models:
- name: Claude Sonnet 5.5
provider: openai
model: claude-sonnet-5-5
apiBase: https://slafy.co/v1
apiKey: sk-slafy-your_key
roles: [chat, edit, apply]Open WebUI, LibreChat, LobeChat, Chatbox, Jan and any app that supports the OpenAI API
Choose the OpenAI or OpenAI Compatible connection type and fill in three fields. The client usually loads the model list by itself.
https://slafy.co/v1sk-slafy-your_keyclaude-sonnet-5-5Addresses, endpoints, SDKs and error codes are on the API page.