Grok
Grok models + GPT Proto
Grok's official API (api.x.ai/v1) speaks the OpenAI Chat protocol. That means no dedicated tool — just reuse any OpenAI-compatible config with the Grok model id (e.g. grok-4.5).
Use Grok in Codex CLI
You already have a chat-protocol provider from the Codex guide — just switch the model:
bash
codex --model gptproto-grok/grok-4.5 "your question"Use Grok in OpenCode
Add a Grok provider (see the OpenCode guide), then launch with the model:
bash
opencode -m grok/grok-4.5 # or pick in /modelsAbout Claude Code + Grok
Claude Code cannot run Grok models directly — it only speaks the Anthropic protocol, and that's expected behavior. Use Grok from Codex or OpenCode instead.
Verify the endpoint
Hit the chat endpoint with a Grok model:
bash
curl -s https://gptproto.com/v1/chat/completions \
-H "Authorization: Bearer $KEY" -H "Content-Type: application/json" \
-d '{"model":"grok-4.5","max_tokens":20,"messages":[{"role":"user","content":"hi"}]}'Other xAI models: if the relay also exposes
grok-4.6, grok-code-fast-1, etc., usage is identical — just change the model id.