Grok

Grok

Use Grok models through LivRouter's OpenAI-compatible endpoint with the same key and request format as other compatible catalog models. Choose the exact current ID from the Grok catalog.

Send a request

cURL
curl https://api.livrouter.com/v1/chat/completions \  -H "Authorization: Bearer $OPENAI_API_KEY" \  -H "Content-Type: application/json" \  -d '{    "model": "YOUR_GROK_MODEL_ID",    "messages": [{"role": "user", "content": "Explain this project in one sentence."}]  }'

Connect a coding client

Use the existing Cursor, Cline, or OpenCode guide, set https://api.livrouter.com/v1 as the OpenAI-compatible base URL, and select your Grok model ID. Confirm tool support before using an agent workflow.

Claude Code compatibility

Claude Code sends Anthropic Messages requests. A Grok model available through Chat Completions is not enough to establish compatibility. Only map Grok into a Claude Code configuration if your account route explicitly supports Messages, the required tool blocks, and the selected model mapping. Otherwise use an OpenAI-compatible client.

Verify the result

Check the reply and the matching entry in Usage logs. If the model is unavailable, review the exact ID and key group. See Errors & troubleshooting for authentication or routing failures.