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

# get session

> Returns a session by ID



## OpenAPI

````yaml https://api.anam.ai/swagger.json get /v1/sessions/{id}
openapi: 3.1.0
info:
  title: Anam AI API
  version: '1.0'
servers:
  - url: https://api.anam.ai
    description: Anam API
security:
  - BearerAuth: []
tags:
  - name: Sessions
  - name: Personas
  - name: Avatars
  - name: Voices
  - name: LLMs
  - name: Knowledge
  - name: Tools
  - name: Share Links
paths:
  /v1/sessions/{id}:
    get:
      tags:
        - Sessions
      summary: get session
      description: Returns a session by ID
      operationId: getSession
      parameters:
        - in: path
          name: id
          schema:
            type: string
            format: uuid
          required: true
          description: Session ID
      responses:
        '200':
          description: Successfully retrieved session
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Session'
              examples:
                default:
                  $ref: '#/components/examples/SessionResponse'
        '400':
          description: Bad request - Invalid session ID
        '401':
          description: Unauthorized - Invalid or missing API key
        '404':
          description: Not Found - Session not found
        '500':
          description: Server error
components:
  schemas:
    Session:
      type: object
      description: >-
        A single connection between a client and a persona. Contains metadata
        but not the transcript or recording — those are fetched separately.
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier for the session.
        personaId:
          type:
            - string
            - 'null'
          format: uuid
          description: >-
            ID of the persona the client connected to, or `null` if the session
            was issued with an ephemeral persona config.
        clientLabel:
          type:
            - string
            - 'null'
          description: Label supplied by the caller when minting the session token.
        startTime:
          type: string
          format: date-time
          description: Timestamp when the session started.
        endTime:
          type:
            - string
            - 'null'
          format: date-time
          description: Timestamp when the session ended, or `null` if still active.
        sessionLengthMs:
          type:
            - integer
            - 'null'
          description: Duration of the session in milliseconds, or `null` if still active.
        exitStatus:
          type:
            - string
            - 'null'
          description: >-
            How the session ended (e.g. `NORMAL_EXIT`, `ERROR`), or `null` if
            still active.
        engineHost:
          type:
            - string
            - 'null'
          description: Hostname of the engine pod that served the session.
        engineProtocol:
          type:
            - string
            - 'null'
          description: Protocol used to stream the session (e.g. `https`).
        engineVersion:
          type:
            - string
            - 'null'
          description: Version of the engine pod that served the session.
        clientMetadata:
          type: object
          description: Arbitrary metadata collected from the client during the session.
        personaConfig:
          type: object
          additionalProperties: true
          description: >-
            Snapshot of the persona configuration taken at the moment the
            session started.
        apiKeyId:
          type:
            - string
            - 'null'
          format: uuid
          description: ID of the API key that minted the session token.
        organizationId:
          type: string
          description: >-
            ID of the organization that owns the session. IDs may be either
            UUIDs or nanoid-style strings depending on when the organization was
            created.
        createdAt:
          type: string
          format: date-time
          description: Timestamp when the session record was created.
        updatedAt:
          type:
            - string
            - 'null'
          format: date-time
          description: Timestamp when the session record was last updated.
  examples:
    SessionResponse:
      summary: A single session record
      value:
        id: 00000000-0000-0000-0000-000000000000
        personaId: null
        clientLabel: anam-lab-chat
        startTime: '2026-04-20T09:00:00.000Z'
        endTime: '2026-04-20T09:12:34.000Z'
        sessionLengthMs: 754000
        exitStatus: CLOSED_BY_ENGINE
        engineHost: connect-eu.anam.ai/v1/webrtc/engines/anam-engine-7dddcb9ccd-db8v9
        engineProtocol: https
        engineVersion: v5.1.0
        clientMetadata:
          userAgent: Mozilla/5.0
        personaConfig:
          type: ephemeral
          name: Cara
          metadata:
            client: js-sdk
          llmConfig:
            id: a7cf662c-2ace-4de1-a21e-ef0fbf144bb7
            modelName: gpt-4o
            format: openai
            urls:
              - url: https://api.openai.com/v1
                region: default
            maxTokens: 4096
            temperature: 0.7
            metadata: {}
            secret_iv: '[REDACTED]'
            encrypted_secret: '[REDACTED]'
            createdByOrganizationId: null
          systemPrompt: You are a helpful assistant.
          personality: ''
          languageCode: en
          skipGreeting: false
          zeroDataRetention: false
          ttsProvider: ELEVENLABS
          ttsProviderVoiceId: lcMyyd2HUfFzxdCaC4Ta
          ttsProviderModelId: eleven_flash_v2_5
          ttsProviderOptions: {}
          avatarEngineKey: cara_home
          avatarVersion: cara-3
          disableBrains: false
          fillerPhrases: []
          useFillerPhrases: false
          enableAudioPassthrough: false
          voiceDetectionOptions: {}
          voiceGenerationOptions: {}
          maxSessionLengthSeconds: 1000000
          fps: 25
        apiKeyId: 00000000-0000-0000-0000-000000000000
        organizationId: 00000000-0000-0000-0000-000000000000
        createdAt: '2026-04-20T09:00:00.000Z'
        updatedAt: '2026-04-20T09:12:34.000Z'
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````