Models/x-ai

grok-4.20· Released Mar 31, 2026

x-ai/grok-4.20

Grok 4.20 is a reasoning model from xAI with industry-leading speed and agentic tool calling capabilities. It combines the lowest hallucination rate on the market with strict prompt adherance, delivering...

Input
From$1.04156/M
Output
From$2.08313/M
Context
Up to 2M
Max output
—
Modalities
TextImageFileText

Input and output show the lowest price across upstreams, for reference. Your actual prices are listed per upstream below.

Upstreams & pricing
UpstreamContextMax outputInput $/1MOutput $/1MCached input $/1MData policy
Zenlayer AI Gateway-openai_compat/GlobalFrom price
2M—
$1.04156
$2.08313
$0.16665
—

Routed in real time — you pay the listed price of whichever upstream serves your call. Data policies reflect each upstream's own data terms and its agreement with us. We do not independently audit upstream implementations.

How to call
bashrequest.sh
curl https://api.lune.io/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "x-ai/grok-4.20",
    "messages": [
      {"role": "user", "content": "Say hello in five words."}
    ]
  }'