Skip to content
Auto
English

Relyven API quickstart

This guide verifies the base URL, API key, model permission, and one real request. Use the protocol your client expects.

Sign in to the dashboard, open API Keys, and create a key. Store it in an environment variable and never commit it to source control. See Account and API keys for lifecycle guidance.

Client Base URL Primary endpoint
OpenAI-compatible SDKs, Codex, Cline https://api.relyven.com/v1 /responses or /chat/completions
Claude Code, Anthropic SDK https://api.relyven.com /v1/messages
Terminal window
curl https://api.relyven.com/v1/models \
-H "Authorization: Bearer $RELYVEN_API_KEY"

A 200 response confirms the base URL and key. A 401 means the key or header is wrong. A model missing from the list may be unavailable to that key.

Terminal window
curl https://api.relyven.com/v1/responses \
-H "Authorization: Bearer $RELYVEN_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"YOUR_MODEL_ID","input":"Reply with OK."}'

Copy the exact model ID from the dashboard. Do not guess aliases.

Terminal window
curl https://api.relyven.com/v1/messages \
-H "x-api-key: $RELYVEN_API_KEY" \
-H "anthropic-version: 2023-06-01" \
-H "Content-Type: application/json" \
-d '{
"model":"YOUR_CLAUDE_MODEL_ID",
"max_tokens":256,
"messages":[{"role":"user","content":"Reply with OK."}]
}'

Messages requires max_tokens. Use a Claude model returned for the current key.