Grok 4.7

xAIMCP Tool CallReasoning
xai/grok-4.7Closed API

xAI's frontier model for long-running agents, coding, knowledge work, and visual projects

Benchmark Pricing$2.00 / 1M in$6.00 / 1M out$0.50 cache read
Context: 500,000 tokens•Max Output: 500,000 tokens•Knowledge: 2026-05•Released: 2026-09-21

TECHNICAL SPECIFICATIONS

Context Window500,000500K tokens
Max Output500,000500K tokens
LicenseProprietaryCloud API only
Input Modalities
TextVisionPDF
Function / Tool CallingSupported (MCP Ready)
Structured OutputsGuaranteed Schema

MODEL CONTEXT PROTOCOL (MCP) READINESS

✓ Grok 4.7 natively supports OpenAI / Anthropic format tool calling and is fully compatible with MCP servers and agent loops.

MCP Context Window Recommendations

With a context capacity of 500,000 tokens, this model can handle extremely large MCP resource manifests, complete database schemas, and multiple active server tool definitions simultaneously without degradation.

STANDARDIZED BENCHMARKS & EVALS

CursorBenchscore
46.3
DeepSWEscore
71
EEBenchscore
64
AA-BriefcaseElo
1657
Terminal-Benchscore
37.6
Harvey Legal Agent Benchmarkscore
19.6
HealthBenchscore
56.7
GDPvalElo
1695

API CALL INVOCATION EXAMPLE

// Example: Calling Grok 4.7 via OpenAI SDK
import OpenAI from "openai";

const client = new OpenAI({
  apiKey: process.env.XAI_API_KEY,
});

const response = await client.chat.completions.create({
  model: "xai/grok-4.7",
  messages: [{ role: "user", content: "Hello! Can you inspect MCP tools?" }],
});

console.log(response.choices[0].message.content);

PRICING BY PROVIDER

15 providers
xAIgrok-4.7
$2.00 / $6.00$0.50 cache
NanoGPTx-ai/grok-4.7
$2.00 / $6.00$0.50 cache
OpenCode Gogrok-4.7
$2.00 / $6.00$0.50 cache
GitHub Copilotgrok-4.7
$2.00 / $6.00$0.50 cache
CrossModelx-ai/grok-4.7
$2.00 / $6.00$0.50 cache
302.AIgrok-4.7
$2.00 / $6.00$0.50 cache
Tempr Gatewayxai/grok-4.7
$2.00 / $6.00$0.50 cache
Cloudflare AI Gatewayxai/grok-4.7
$2.00 / $6.00$0.50 cache
Venice AIgrok-4-7
$2.27 / $6.80$0.57 cache
AIHubMixgrok-4.7
$2.00 / $6.00$0.50 cache
Vercel AI Gatewayspacexai/grok-4.7
$2.00 / $6.00$0.50 cache
OpenCodegrok-4.7
$2.00 / $6.00$0.50 cache
Eden AIxai/grok-4.7
$2.00 / $6.00$0.50 cache
NEAR AI Cloudx-ai/grok-4.7
$2.00 / $6.00$0.50 cache
Ofoxx-ai/grok-4.7
$2.00 / $6.00$0.50 cache

Rates in USD per 1M tokens. Rates synchronized from models.dev public catalog.

Prompt Caching Active

This model supports prompt caching at $0.50 / 1M tokens, saving up to 75% on repetitive MCP tool definitions and system instructions.

MODEL RESOURCES