> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getpg.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# [BETA] List workspace agent sessions

> List agent sessions for the workspace (user-scoped server-side).



## OpenAPI

````yaml https://api.getpg.ai/docs/v1/openapi.json get /agent/sessions
openapi: 3.0.0
info:
  title: PG:AI Public API
  version: 1.0.0
  description: >-
    Public API for accessing PG:AI account intelligence, contacts, territories,
    and more. All endpoints require API key authentication via the x-api-key
    header.
  contact:
    name: PG:AI Support
    url: https://www.getpg.ai
servers:
  - url: https://api.getpg.ai/public-api/v1
    description: Production
security:
  - ApiKeyAuth: []
paths:
  /agent/sessions:
    get:
      tags:
        - agent
      summary: '[BETA] List workspace agent sessions'
      description: List agent sessions for the workspace (user-scoped server-side).
      parameters:
        - name: page
          in: query
          required: false
          schema:
            type: integer
            default: 1
          description: Page number
        - name: per_page
          in: query
          required: false
          schema:
            type: integer
            default: 25
          description: >-
            Page size. Default 25, maximum 50 on all list endpoints. Omit to use
            the default; increase up to 50 only if you need larger pages.
        - name: status
          in: query
          required: false
          schema:
            type: string
          description: Filter by status
        - name: type
          in: query
          required: false
          schema:
            type: string
          description: Filter by session type
        - name: company_id
          in: query
          required: false
          schema:
            type: string
          description: Filter by company UUID
        - name: search
          in: query
          required: false
          schema:
            type: string
          description: Search
        - name: sort_by
          in: query
          required: false
          schema:
            type: string
          description: Sort field
        - name: sort_order
          in: query
          required: false
          schema:
            type: string
          description: Sort order
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                description: Response data
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                type: object
                description: Response data
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                type: object
                description: Response data
        '500':
          description: Unexpected error
          content:
            application/json:
              schema:
                type: object
                description: Response data
      deprecated: false
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        Your API key for authentication. Get your API key from the PG:AI
        dashboard under Settings > API Keys.

````