API · Models
Text
Grok 4.1 Fast Reasoning
ReasoningFilesVisionToolsCache
Context 1M·Max out 1M
Quickstart
import { streamText } from 'ai';
import { createOpenAICompatible } from '@ai-sdk/openai-compatible';
const blackbox = createOpenAICompatible({
name: 'blackbox',
apiKey: process.env.BLACKBOX_API_KEY!,
baseURL: 'https://api.blackbox.ai/v1',
});
const result = streamText({
model: blackbox('blackboxai/xai/grok-4.1-fast-reasoning'),
prompt: 'Why is the sky blue?',
});
for await (const chunk of result.textStream) {
process.stdout.write(chunk);
}Specs & pricing
- Input $/M
- 0.2
- Output $/M
- 0.5
- Context window
- 1M
- Max output
- 1M
- Supported parameters
- —
Related models
| Model | Type | Context | Input $/M |
|---|---|---|---|
| Grok 4.3 | Text | 1M | 1.25 |
| Grok 4.1 Fast | Text | 1M | 0.2 |
| Grok Build 0.1 | Text | 256K | 1 |
| Grok 4.1 Fast Non-Reasoning | Text | 1M | 0.2 |
| Grok 4.20 Multi-Agent | Text | — | 1.25 |