Grok 4.7
Grok 4.7 is SpaceXAI's flagship model for coding, agentic tasks, and knowledge work, succeeding Grok 4.6
Input tokens−30% off
$1.40per 1M tokens
Official: $2.00
Output tokens−30% off
$4.20per 1M tokens
Official: $6.00
30-day price trend
Quickstart
from openai import OpenAI
import os
client = OpenAI(
base_url="https://api.cheapllm.app/v1",
api_key=os.environ["CHEAPLLM_API_KEY"],
)
response = client.chat.completions.create(
model="x-ai/grok-4.7",
messages=[{"role": "user", "content": "Hello!"}],
)import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://api.cheapllm.app/v1",
apiKey: process.env.CHEAPLLM_API_KEY,
});
const response = await client.chat.completions.create({
model: "x-ai/grok-4.7",
messages: [{ role: "user", content: "Hello!" }],
});curl https://api.cheapllm.app/v1/chat/completions \
-H "Authorization: Bearer $CHEAPLLM_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "x-ai/grok-4.7",
"messages": [{"role": "user", "content": "Hello!"}]
}'Specifications
- Context window
- 500K
- Max output
- —
- Tool calling
- Supported
- Vision / images
- Supported
- Reasoning
- —
- Base URL
https://api.cheapllm.app/v1
Grok 4.7 price comparison: CheapLLM vs Official API
Prices verified 2026-11-28| Metric | Official xAI API | CheapLLM (Pay as you go) | Savings |
|---|---|---|---|
| Input tokens (per 1M) | $2.00 | $1.40 | −30% |
| Output tokens (per 1M) | $6.00 | $4.20 | −30% |
| Context window | 500K | 500K | 100% |
| With Pro / Max plan (100× pool) | — | Up to 70% lower bill | −70% |