← Back to catalog
x-ai

xAI: Grok 4.6

x-ai/grok-4.6
Get API key
Overview
Context
500K
Input / 1M
$2.00 / 1M tokens
Output / 1M
$6.00 / 1M tokens
Modalities
text, image
Quickstart

Drop the model ID into either endpoint — BitRouter speaks the OpenAI and Anthropic wire formats natively.

OpenAI-compatiblehttps://api.bitrouter.ai/v1/chat/completions
curl https://api.bitrouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $BITROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "x-ai/grok-4.6",
    "messages": [{"role": "user", "content": "Hello"}]
  }'
Anthropic-compatiblehttps://api.bitrouter.ai/v1/messages
curl https://api.bitrouter.ai/v1/messages \
  -H "x-api-key: $BITROUTER_API_KEY" \
  -H "anthropic-version: 2023-06-01" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "x-ai/grok-4.6",
    "max_tokens": 1024,
    "messages": [{"role": "user", "content": "Hello"}]
  }'