---
title: "Get Sessions Endpoint"
method: GET
path: "/sessions"
tags: ["Sessions"]
---

# Get Sessions Endpoint

`GET /sessions`

## Request

- Base URL: `https://api.raccoonai.tech`
- URL: `https://api.raccoonai.tech/sessions`
- Auth: API key in header `raccoon-secret-key`

## Query parameters

- `start_time` integer, nullable: Filter sessions created after this Unix timestamp (in milliseconds).
- `end_time` integer, nullable: Filter sessions created before this Unix timestamp (in milliseconds).
- `session_id` string, nullable: Filter sessions by a specific session ID.
- `task_id` string, nullable: Filter sessions by a specific task ID.
- `page` integer, nullable: Page number for pagination.
- `limit` integer, nullable: Number of sessions per page (maximum 100).
- `executionType[]` string[], nullable: Filter sessions by execution type (e.g., 'default', 'deepsearch').
- `sort_by` 'timestamp' | 'executionTime' | 'taskId' | 'status' | 'executionType', nullable: Field to sort sessions by (e.g., 'timestamp', 'executionTime').
- `sort_order` 'ascend' | 'descend', nullable: Sort order ('ascend' or 'descend').
- `raccoon_passcode` string, nullable: Filter sessions by Raccoon passcode.

## Response `200`

Successful Response

- SessionListResponse
  - `sessions` Session[], required: List of sessions.
    - `sessionId` string, required: Unique identifier for the session.
    - `executionType` 'default' | 'deepsearch' | 'fleet', required: The type of execution performed (e.g., 'default', 'deepsearch').
    - `status` 'success' | 'failure' | 'running', required: Current status of the session.
    - `inputs` object, required: Input parameters used for the session.
    - `output` object[], required: Output generated by the session.
    - `raccoonPasscode` string, required: Passcode associated with the user.
    - `taskId` string, required: Unique identifier for the associated task.
    - `executionTime` integer, required: Time taken for the session execution (in milliseconds).
    - `timestamp` integer, required: Unix timestamp (in milliseconds) indicating when the session was created.
  - `meta` Meta, required: Metadata about the session list.
    - `totalPages` integer, required: Total number of pages available.
    - `totalRecords` integer, required: Total number of records across all pages.
    - `currentPage` integer, required: The current page number.

## Other responses

- `422`: Validation Error

## Changes

- **2025-03-18** `cc64732da5aa`: 2 breaking, 2 warning, 4 info
  - removed the enum value `extract` from the property `anyOf[subschema #1]/items/` of the `query` request parameter `executionType[]`
  - removed the enum value `run` from the property `anyOf[subschema #1]/items/` of the `query` request parameter `executionType[]`
  - added the new `deepsearch` enum value to the `sessions/items/executionType` response property for the response status `200`
  - added the new `default` enum value to the `sessions/items/executionType` response property for the response status `200`
  - …4 more
- **2025-03-03** `0347d66172e4`: 1 breaking, 7 warning, 8 info
  - removed the request body
  - deleted the `query` request parameter `endTime`
  - deleted the `query` request parameter `raccoonPasscode`
  - deleted the `query` request parameter `sessionId`
  - …12 more
- **2025-03-03** `b0c1c8f44dae`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api/changes/sessions/get.md)

---

[API](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api.md) - [All operations](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api/llms.txt) - [OpenAPI document](https://skmtc.dev/raccoonaihq/apis/raccoon-ai-api/revisions/cc64732da5aa?raw)
