slash commands / reference

COMMAND REFERENCE

Slash commands for every AI coding tool — Claude Code, Cursor, Codex CLI, Gemini CLI, and OpenCode. Find the right command for your workflow. 15 commands indexed.

commands
15
tools
5

/compact

context-management

OpenCode

Summarize the current session to save tokens. Alias: /summarize.

contextsummarizetokens
view command →

/connect

configuration

OpenCode

Add a provider and API key to connect a new AI model provider.

providerscredentialsconfigurationapi-key
view command →

/details

configuration

OpenCode

Toggle tool execution details in the conversation output.

detailstoolsdebugging
view command →

/editor

context-management

OpenCode

Open the external $EDITOR for composing messages — useful for long or structured prompts. Keybind: Ctrl+x e.

editorinputcompose
view command →

/exit

session-management

OpenCode

Exit OpenCode. Aliases: /quit, /q. Keybind: Ctrl+x q.

exitquit
view command →

/export

session-management

OpenCode

Export the current conversation to Markdown and open in $EDITOR. Keybind: Ctrl+x x.

exportmarkdowndocumentation
view command →

/init

setup

OpenCode

Guided AGENTS.md setup for the current project.

setupagents.mdmemoryproject-init
view command →

/models

configuration

OpenCode

List available models across all configured providers. Keybind: Ctrl+x m.

modelsprovidersconfiguration
view command →

/new

session-management

OpenCode

Start a new session. Aliases: /clear. Keybind: Ctrl+x n.

newsessionclearcontext-reset
view command →

/redo

session-management

OpenCode

Restore a previously undone message and file changes. Git-backed. Keybind: Ctrl+x r.

redorestoregit
view command →

/sessions

session-management

OpenCode

List and switch sessions. Aliases: /resume, /continue. Keybind: Ctrl+x l.

sessionsresumehistory
view command →

/share

session-management

OpenCode

Share the current session publicly.

sharecollaborationpublic
view command →

/themes

configuration

OpenCode

List available themes and switch the visual theme. Keybind: Ctrl+x t.

themesuivisual
view command →

/thinking

configuration

OpenCode

Toggle visibility of reasoning blocks in the response.

thinkingreasoningvisibility
view command →

/undo

session-management

OpenCode

Remove the last message and its responses, and revert any file changes made. Git-backed — requires a git repository. Keybind: Ctrl+x u.

undorevertgitrollback
view command →