# List sessions **GET /api/v1/projects/{id}/sessions** Lists durable conversation sessions across every workspace in the project, with the most recently active first. These sessions contain messages and execution runs. They are separate from runtime sessions, which track reserved sandbox capacity. To get the next page, pass next_cursor from the response as cursor. ## Servers - https://agentengine.mongodb.com: https://agentengine.mongodb.com () ## Authentication methods - Bearer auth ## Parameters ### Path parameters - **id** (string) Project ID ### Query parameters - **limit** (integer) Max results (default 50, max 200) - **workspace_id** (string) Restrict to a single workspace - **status** (string) Filter by the session's latest execution status - **since** (string) Only sessions with activity at or after this RFC3339 time - **until** (string) Only sessions with activity before this RFC3339 time - **cursor** (string) Opaque paging token from a previous response's next_cursor ## Responses ### 406 Unsupported or malformed API version, an operation unavailable in the selected published contract, or an unacceptable representation (including unsupported media-type parameters or excluded SSE). Existing authentication, authorization, and rate-limit failures take precedence. #### Body: application/json (object) - **badRequestDetail** (object) Optional validation details defined by the standard error schema; API negotiation errors do not emit this field. - **detail** (string) Human-readable error details. - **error** (integer) HTTP status code. - **errorCode** (string) Machine-readable error code. - **parameters** (array[string]) Request parameter names associated with the error; omitted when none apply. - **reason** (string) HTTP status reason phrase. ### 200 OK #### Body: application/json (object) - **has_more** (boolean) - **limit** (integer) - **next_cursor** (string) NextCursor is an opaque token to pass back as the `cursor` query param, nil when this page is the last. Opaque so the paging position can change shape without breaking clients, matching the convention the other paged endpoints on this gateway already use. - **sessions** (array[object]) - **total_count** (integer) TotalCount is the number of sessions matching the filter. Present only on the first page: counting it means fetching every match, which is what cursor paging exists to avoid, and it cannot change mid-walk. - **truncated** (boolean) ### 400 Bad Request #### Body: application/json (object) - **code** (string) - **error** (string) - **success** (boolean) ### 401 Unauthorized #### Body: application/json (object) - **code** (string) - **error** (string) - **success** (boolean) ### 500 Internal Server Error #### Body: application/json (object) - **code** (string) - **error** (string) - **success** (boolean) ### 502 Bad Gateway #### Body: application/json (object) - **code** (string) - **error** (string) - **success** (boolean) [Powered by Bump.sh](https://bump.sh)