v1

latestOpenAPI 3.1.02026-07-17325265.6 KB
Sessions

Continue or fork a session

Create a new session that continues from an existing session, inheriting its conversation history.

post/sessions/{id}/continue

Path parameters

idstring required

Session ID

Request body

querystring required

New query to continue with

system_promptstring

Override system prompt

append_system_promptstring

Append to system prompt

permission_prompt_toolstring

MCP tool for permissions

allowed_toolsstring[]

Allowed tools list

disallowed_toolsstring[]

Disallowed tools list

custom_instructionsstring

Custom instructions

max_turnsinteger

Max conversation turns

Example request

{
  "query": "Now add error handling to the script",
  "mcp_config": {
    "mcpServers": {
      "filesystem": {
        "command": "mcp-server-filesystem",
        "args": [
          "--read-only"
        ]
      }
    }
  }
}

Response

New session created

Example response

{
  "data": {
    "session_id": "sess_child123",
    "run_id": "run_child456",
    "claude_session_id": "claude_sess_child",
    "parent_session_id": "sess_parent123"
  }
}