This directory contains specs and usage notes for every public grok-cli command. Use this index for day-to-day command lookup. Deeper output examples and internal design notes live in ../reference/.
grok-cli <login|status|refresh|logout|state|model|usage|update|chat|search|image|image-edit|video|video-edit|video-extend|tts|stt|stt-stream> ...
| Command | Doc | Purpose |
|---|---|---|
login |
login.md |
Open a real browser, complete xAI OAuth login, and save tokens. |
status |
status.md |
Read local OAuth state and report whether login is usable. |
refresh |
refresh.md |
Refresh the saved access token with the refresh token. |
logout |
logout.md |
Delete local OAuth state. |
| Command | Doc | Purpose |
|---|---|---|
state |
state.md |
Inspect a redacted local OAuth state summary. |
model |
model.md |
Manage the shared default text model for chat and search. |
| Command | Doc | Purpose |
|---|---|---|
chat |
chat.md |
Run Grok text chat with web search enabled by default. |
search |
search.md |
Search X through Grok x_search. |
| Command | Doc | Purpose |
|---|---|---|
image |
image.md |
Generate images with Grok Imagine. |
image-edit |
image-edit.md |
Edit one or more reference images. |
video |
video.md |
Generate text-to-video, image-to-video, or reference-image video. |
video-edit |
video-edit.md |
Edit an existing video from a URL or local file. |
video-extend |
video-extend.md |
Extend an existing remote video URL. |
| Command | Doc | Purpose |
|---|---|---|
tts |
tts.md |
Convert text to speech and save audio locally. |
stt |
stt.md |
Transcribe local audio files or remote audio URLs. |
stt-stream |
stt-stream.md |
Experimental WebSocket speech-to-text. |
| Command | Doc | Purpose |
|---|---|---|
usage |
usage.md |
Inspect local session usage and recent rate-limit snapshots. |
update |
update.md |
Check the latest release, update the CLI, and manage passive update notices. |
- Public commands are intentionally flat. There is no public
auth,task,proxy, ordebugcommand group. chatandsearchstream readable text by default for humans.- Use
--jsonfor skills, scripts, and automation. - Use
--raw-streamonly when the caller can consume normalized stream events. - Internal auth recovery entrypoints are not listed here; see
../reference/internal-auth.md.