Connect Claude Code to the ClipRelay API gateway
Use the native Anthropic Messages endpoint with a project key. Compare input, output and cache rates before running a coding session.
Manage API keysAll models and pricesIsolate the project
Create a dedicated ClipRelay key with a spending limit. Store it locally outside your repository.
Configure Claude Code
Set the base URL to the site root and use the exact model ID below. Start Claude Code in the same shell.
Verify usage
Run a small request first. Check input, cache reads, cache writes and output in your request log before longer sessions.
Current rates · per 1M tokens
claude-sonnet-5-5 · Input $0.7 · Output $3.5 · Cache read $0.035 · Cache write $0.875
claude-opus-5-5 · Input $1.4 · Output $7 · Cache read $0.07 · Cache write $1.75
claude-fable-5-2 · Input $2.8 · Output $14 · Cache read $0.07 · Cache write $3.5
View API example
Set CLIPRELAY_API_KEY in Bash. Running the example incurs usage charges.
curl https://cliprelayai.com/v1/messages \
-H "x-api-key: $CLIPRELAY_API_KEY" \
-H "anthropic-version: 2023-06-01" \
-H "Content-Type: application/json" \
-d '{
"model": "claude-sonnet-5-5",
"max_tokens": 64,
"messages": [
{
"role": "user",
"content": "Explain git diff"
}
]
}'
export ANTHROPIC_BASE_URL=https://cliprelayai.com
export ANTHROPIC_AUTH_TOKEN="$CLIPRELAY_API_KEY"
export ANTHROPIC_MODEL=claude-sonnet-5-5
claudeAPI documentationGlobal Cards & Alipay Instant Checkout ($5 Minimum)
Self-serve USD top-ups from $5 ($5–$500+) via Visa, Mastercard, Amex, Apple Pay, Google Pay, and Alipay. Credits never expire, and failed video/image tasks automatically refund 100%. Support: support@cliprelayai.com.