xAI Grok API
xAI Grok 接口
Access Grok-2 and Grok-3 models from xAI. Real-time knowledge, long context, and image understanding capabilities.
调用 xAI 的 Grok-2 和 Grok-3 模型。实时知识、长上下文和图像理解能力。
Website
Documentation
Pricing
pay-as-you-go (per token)
Authentication
- API Key (Bearer Token)
Popularity
70/100
Endpoints
https://api.x.ai/v1/chat/completions
SDKs
PythonNode.jscurl
Tags
llmchatreal-timevision
Last updated: 2026-08-02
Similar APIs
OpenAI API
★100Access GPT-4o, GPT-4, GPT-3.5, embeddings, DALL-E, Whisper, and TTS models via REST API.
Anthropic Claude API
★87Access Claude 3.5 Sonnet, Haiku, and Opus models for chat, analysis, and code generation.
Google Gemini API
★85Access Gemini 2.0 Flash, Pro, and Ultra models with native multimodal and tool-use support.
DeepSeek API
★83Access DeepSeek-V3 and DeepSeek-R1 reasoning models with competitive pricing.
Something wrong or missing? Open an issue on GitHub →
Pricing Comparison
| API | Pricing | Auth | Popularity |
|---|---|---|---|
| OpenAI API | pay-as-you-go (per token) | API Key (Bearer Token) | 100 |
| Anthropic Claude API | pay-as-you-go (per token) | API Key (x-api-key header) | 87 |
| Google Gemini API | free tier available, pay-as-you-go | API Key | 85 |
| DeepSeek API | pay-as-you-go (per token, very low cost) | API Key | 83 |
Get Started with xAI Grok API
Click below to visit the official website and start using this API.
Visit xAI Grok API →Discussion
Questions, feedback, or suggestions? Start a discussion.
Discuss on GitHub