Skip to main content
GET
/
api
/
v1
/
user-sessions
/
{user_session_id}
Get User Session Detail
curl --request GET \
  --url https://api.example.com/api/v1/user-sessions/{user_session_id} \
  --header 'Authorization: Bearer <token>'
{
  "session": {
    "session_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "status": "ACTIVE",
    "created_at": "2023-11-07T05:31:56Z",
    "kind": "user_session",
    "name": "<string>",
    "metadata": {},
    "settings": {
      "code": {
        "mode": "agent",
        "default_provider": "<string>",
        "providers": {
          "claude_code": {
            "model": "haiku"
          },
          "codex": {
            "model": "gpt-5.1-codex-max",
            "thinking": "low"
          }
        }
      },
      "voice": {
        "language": "<string>"
      }
    },
    "worktree_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "worktree_name": "<string>",
    "worktree_type": "LOCAL"
  },
  "agent_sessions": [
    {
      "session_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "session_type": "CODE",
      "connection_status": "CONNECTED",
      "work_status": "IDLE",
      "kind": "agent_session",
      "user_session_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "parent_session_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "daemon_version": "<string>",
      "metadata": {},
      "settings": {
        "code": {
          "mode": "agent",
          "default_provider": "<string>",
          "providers": {
            "claude_code": {
              "model": "haiku"
            },
            "codex": {
              "model": "gpt-5.1-codex-max",
              "thinking": "low"
            }
          }
        },
        "voice": {
          "language": "<string>"
        }
      }
    }
  ],
  "workspace": {
    "id": "<string>",
    "user_id": "<string>",
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z",
    "git_host": "<string>",
    "git_path": "<string>",
    "workspace_metadata": {},
    "workspace_config": {
      "git": {
        "remote": "origin",
        "base_ref": "main"
      },
      "sync": {
        "enabled": false
      },
      "remote_env": {
        "env": [
          {
            "key": "<string>",
            "value": "<string>"
          }
        ]
      },
      "setup": {
        "script": "<string>"
      }
    },
    "user_machine_paths": [
      {
        "user_machine_id": "<string>",
        "local_path": "<string>"
      }
    ]
  },
  "worktree": {
    "id": "<string>",
    "workspace_id": "<string>",
    "is_main": true,
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z",
    "name": "<string>",
    "path": "<string>",
    "worktree_type": "LOCAL",
    "user_machine_path": {
      "id": "<string>",
      "machine_id": "<string>",
      "local_path": "<string>"
    },
    "managed_machine_id": "<string>",
    "last_heartbeat_at": "2023-11-07T05:31:56Z",
    "last_synced_checkpoint_id": "<string>",
    "checkpoint_restore_pending": false,
    "current_checkpoint_id": "<string>",
    "checkpoint_metadata": {}
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

user_session_id
string
required

Response

Successful Response

Aggregated user session data returned to clients.

session
UserSessionDescriptor · object
required

Core user session descriptor

agent_sessions
AgentSessionDescriptor · object[]

Agent sessions associated with this user session

workspace
WorkspaceDescriptor · object

Workspace linked to this session, if any

worktree
WorktreeDescriptor · object

Worktree linked to this session, if any