---
title: "Get kernel status for a notebook in an interactive session"
method: GET
path: "/sessions/{sessionId}/status"
tags: ["Sessions"]
---

# Get kernel status for a notebook in an interactive session

`GET /sessions/{sessionId}/status`

Returns the current kernel state for a notebook in an interactive session, including the currently executing block and queued block executions when available. Each notebook in a session has its own kernel; name the notebook via the `notebookId` query parameter and query each notebook separately.

## Path parameters

- `sessionId` string, uuid, required — Session identifier.

## Query parameters

- `notebookId` string, required — Notebook within the session to read status for. Use the session's source notebook ID (`session.notebookId`), not `sessionNotebookId`.

## Response `200`

Current session and kernel status for the notebook.

- GetSessionNotebookStatusResponse
  - `session` Session, required
    - `id` string, uuid, required — Session identifier. Use this as the sessionId in subsequent operations.
    - `status` 'idle' | 'busy' | 'terminated', required — `busy` while a run is pending or running, `idle` when no runs are active, `terminated` once the session has ended.
    - `projectId` string, uuid, required — ID of the project the session was created in.
    - `notebookId` string, required — ID of the notebook the session was created from.
    - `sessionNotebookId` string, required — ID of the session's own editable copy of the notebook. The session executes this copy, not the source notebook. Use the standard notebook and block endpoints against this ID to read and edit what the session runs; changes never affect the source notebook and are discarded when the session ends. Each run persists as a run snapshot.
    - `currentRunId` string, uuid, nullable, required — ID of the active (pending or running) run in this session, or null when idle.
    - `createdAt` string, date-time, required
    - `lastActivityAt` string, date-time, required — Timestamp of the most recent submission to the session. Refreshed on every new run.
    - `expiresAt` string, date-time, required — When the session will end if no further submissions are made.
  - `kernel` SessionKernelState, required
    - `id` string, required — Kernel identifier for this notebook in the session.
    - `status` 'missing' | 'starting' | 'initializing' | 'kernel_starting' | 'idle' | 'busy' | 'kernel_error' | 'stopping' | 'global_error', required — Current kernel lifecycle status. `missing` means the executor has no kernel state for this notebook yet.
    - `name` string, nullable, required — Kernel name reported by the executor, when available.
    - `executionContextId` string, nullable, required — Executor execution context identifier, when the kernel has reported one.
    - `workingDirectory` string, nullable, required — Working directory the kernel is running in, when reported.
    - `currentlyExecutingItem` object, nullable, required — Block execution the kernel is currently running, or `null` if the kernel is not executing a block.
      - `blockId` string, required — ID of the block this execution is associated with, in the session's notebook copy (see `sessionNotebookId`).
      - `sourceBlockId` string, nullable, required — ID of the source-notebook block this session block was copied from when the session was created, or null for blocks created in the session.
      - `inputRequest` object, nullable, required — When present, the block is paused waiting for stdin input with the given prompt.
        - `prompt` string, required — Prompt the running cell is waiting on stdin for.
    - `blockExecutionQueue` object[], required — Block executions queued behind the currently executing block, in order.
      - `blockId` string, required — ID of the block this execution is associated with, in the session's notebook copy (see `sessionNotebookId`).
      - `sourceBlockId` string, nullable, required — ID of the source-notebook block this session block was copied from when the session was created, or null for blocks created in the session.
      - `inputRequest` object, nullable, required — When present, the block is paused waiting for stdin input with the given prompt.
        - `prompt` string, required — Prompt the running cell is waiting on stdin for.

## Other responses

- `400` — Validation error
- `401` — Unauthorized
- `403` — Insufficient permissions
- `404` — Session or notebook not found
- `409` — Project is suspended
- `429` — Rate limit exceeded

---

[API](https://skmtc.net/deepnote/apis/deepnote-public-api.md) · [All operations](https://skmtc.net/deepnote/apis/deepnote-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/deepnote/deepnote-public-api/revisions/726970fd2992/schema)
