Manage a session
oc_sessionPerform session actions such as diff, fork, rename, archive, set model or agent, run shell commands, load skills, revert changes, inspect context, or export. Use session_id plus action to manage a coding sub-agent session.
Instructions
Actions on a session: info, diff (files changed), fork, compact, rename, archive, delete, set_model, set_agent, shell (run a shell command in the session), load_skill, revert (undo changes from a message on), context (context/tokens), export.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"session_id": "<session_id>",
"action": "<action>"
},
"name": "oc_session"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| value | No | Title (rename), model (set_model), agent (set_agent), command (shell), skill id (load_skill), message id (revert / fork before that message). | |
| action | Yes | ||
| session_id | Yes |