grok-4.20-0309-reasoning API
Use xAI’s Grok reasoning model on APISea for text conversations and extended reasoning tasks.
grok-4.20-0309-reasoningتسعير API لنموذج grok-4.20-0309-reasoning
جميع الأسعار بالدولار الأمريكي (USD). مقارنة أسعار APISea بالسعر الرسمي المعلن للوحدة نفسها.
| نوع الـ token | APISea | رسمي | وفّر |
|---|---|---|---|
| الإدخال لكل 1M رمز | $1.10 | $1.25 | −12% |
| الإدخال المخزّن مؤقتًا لكل 1M رمز | $0.176 | $0.20 | −12% |
| الإخراج لكل 1M رمز | $2.20 | $2.50 | −12% |
التسعير حسب طول المطالبة
| نوع الـ token | حتى 200,000 token | أكثر من الشريحة السابقة |
|---|---|---|
| الإدخال | $1.10$1.25 | $2.20$2.50 |
| الإدخال المخزّن مؤقتًا | $0.176$0.20 | $0.352$0.40 |
| الإخراج | $2.20$2.50 | $4.40$5.00 |
ما هو grok-4.20-0309-reasoning؟
grok-4.20-0309-reasoning is an xAI Grok model for chat and reasoning, positioned for tasks that benefit from extended reasoning. Developers can use it for text conversations, document analysis, and multi-step problem solving. It accepts message arrays with role and content fields and generates text responses through APISea’s OpenAI-compatible Chat Completions interface. The listed limits are 1,000,000 input tokens and 1,000,000 output tokens, with support for prompt-cache reads.
Call the model using one APISea key and the base URL https://api.apisea.ai/v1. Request controls include temperature, top_p, max_tokens, and stream. APISea bills pay-as-you-go, only for successful requests. Up to 200,000 input tokens, input costs $1.10 per 1M tokens and output costs $2.20 per 1M tokens; above that tier, rates are $2.20 and $4.40 per 1M tokens, respectively. Cached input costs $0.176 per 1M tokens. The default configuration is about 12% below provider list price.
أبرز مزايا grok-4.20-0309-reasoning
Large Token Limits
Supports a maximum of 1,000,000 input tokens and 1,000,000 output tokens. These are separate input and output limits.
Prompt-Cache Reads
Supports cached prompt reads at $0.176 per 1M tokens on APISea.
Configurable Text Generation
Set temperature or top_p to control generation randomness and use max_tokens to cap the response length.
Streaming Response Control
Use stream=true for SSE output or stream=false to receive the complete response at once through the Chat Completions interface.
كيفية استدعاء API الخاص بـ grok-4.20-0309-reasoning في 4 خطوات
- 01
احصل على API key
سجّل الدخول إلى APISea، واشحن رصيدك بدءًا من $50، وأنشئ مفتاح sk-sea من وحدة التحكم.
- 02
اضبط عنوان URL الأساسي
استخدم https://api.apisea.ai/v1 عنوانًا أساسيًا في SDK أو عميل HTTP.
- 03
أرسل الطلب
استدعِ POST /v1/chat/completions مع "model": "grok-4.20-0309-reasoning" والمعلمات أدناه.
- 04
تعامل مع الاستجابة
اقرأ الاستجابة (أو استقبل الـ tokens بالتدفق باستخدام stream: true). يظهر الاستخدام والتكلفة في وحدة التحكم.
أمثلة على الطلبات
الوثائق: General Chat API (Default Streaming)curl https://api.apisea.ai/v1/chat/completions \
-H "Authorization: Bearer $APISEA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "grok-4.20-0309-reasoning",
"messages": [
{"role": "system", "content": "You are a concise assistant."},
{"role": "user", "content": "Explain what an AI API gateway does in two sentences."}
],
"stream": false
}'المعلمات
| المعلمة | النوع | مطلوب | افتراضي | الوصف |
|---|---|---|---|---|
model | string | مطلوب | gpt-5 | Model name |
messages | array | مطلوب | — | List of conversation messages |
role | string | مطلوب | user | Role type |
content | string | مطلوب | — | Message content |
temperature | number | اختياري | — | Controls output randomness, range 0-2 |
max_tokens | integer | اختياري | — | Maximum number of tokens to generate |
stream | boolean | اختياري | — | Whether to use streaming output |
top_p | number | اختياري | — | Nucleus sampling parameter, range 0-1 |
frequency_penalty | number | اختياري | — | Frequency penalty, range -2.0 to 2.0 |
presence_penalty | number | اختياري | — | Presence penalty, range -2.0 to 2.0 |
stop | string or array | اختياري | — | Stop sequences |
n | integer | اختياري | — | Number of completions to generate |
ما الذي يمكنك إنشاؤه باستخدام grok-4.20-0309-reasoning
Document Analysis
Build workflows that submit long text documents and ask for summaries, comparisons, or answers grounded in the supplied material.
Multi-Step Problem Solving
Use this reasoning-positioned model for applications that ask users to define a problem, supply constraints, and receive a proposed solution.
Conversational Assistants
Build multi-turn text assistants by including prior user and assistant messages in each request.
Decision Support
Ask the model to compare options against explicit criteria and explain trade-offs for a team to review.
نصائح للحصول على نتائج أفضل
- 01
Set an Output Budget
Use max_tokens to cap generated text according to your application’s needs rather than relying on the maximum output allowance.
- 02
Watch the Input Tier
Budget for the tier change above 200,000 input tokens: input costs $2.20 per 1M tokens and output costs $4.40 per 1M tokens.
- 03
Control Sampling Deliberately
For less random responses, try a lower temperature such as 0.2. The documentation recommends using either temperature or top_p to tune sampling.
- 04
Check Cache Usage
Account for supported prompt-cache reads at $0.176 per 1M tokens, and distinguish cached input from regular input when estimating costs.
القيود ومعلومات مهمة
Maximum input is 1,000,000 tokens; maximum output is 1,000,000 tokens.
Requests above 200,000 input tokens use the higher input and output pricing tier.
Generation can end at the configured max_tokens limit rather than completing the requested response.
الأسئلة الشائعة حول API الخاص بـ grok-4.20-0309-reasoning
How much does grok-4.20-0309-reasoning cost on APISea?
Up to 200,000 input tokens, input is $1.10 per 1M tokens and output is $2.20 per 1M tokens. Above that tier, input is $2.20 per 1M tokens and output is $4.40 per 1M tokens; cached input is $0.176 per 1M tokens. The default configuration is about 12% below provider list price, and APISea bills only successful requests.
How do I call grok-4.20-0309-reasoning through the API?
Send a POST request to https://api.apisea.ai/v1/chat/completions with Bearer Token authentication using your APISea key. Set the model field to grok-4.20-0309-reasoning and include a messages array containing role and content fields.
What generation parameters can I use?
The documented Chat Completions interface includes temperature, top_p, max_tokens, stream, frequency_penalty, presence_penalty, stop, and n. Set stream=true for SSE output or stream=false for a complete response.
What are the input and output token limits?
The listed maximum input is 1,000,000 tokens, and the listed maximum output is 1,000,000 tokens. Use max_tokens to set a lower generation cap for your request.
Can I use this model commercially?
Commercial use is subject to the provider’s terms. Review the applicable xAI terms and APISea service terms before deploying your application.
How does this differ from other Grok models?
The reasoning suffix positions grok-4.20-0309-reasoning for extended reasoning. The supplied facts do not establish performance or speed differences from other Grok models, so compare their documented limits and pricing for your workload.
نماذج ذات صلة
grok-4.20-0309-non-reasoning
grok-4.20-multi-agent-0309
grok-4.3
grok-4.5
grok-4.6
grok-4.7
qwen-turbo
qwen3.6-flash
ابدأ التطوير باستخدام grok-4.20-0309-reasoning
مفتاح واحد، وادفع حسب الاستخدام بدءًا من $50؛ ولا تُحتسب الرسوم إلا على الطلبات الناجحة.