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

# List sessions

> Lists sessions in your team.



## OpenAPI

````yaml get /v1/team/sessions
openapi: 3.0.1
info:
  title: Team Open API
  description: ''
  version: 1.0.0
servers:
  - url: https://ai.data.cloud/api
    description: 体验环境
security: []
tags:
  - name: Session
  - name: Dataset
  - name: Data source
  - name: File
  - name: Job
paths:
  /v1/team/sessions:
    get:
      tags:
        - Session
      summary: List sessions
      description: Lists sessions in your team.
      parameters:
        - name: pageNumber
          in: query
          description: >-
            The number of pages to display. If not specified, the default value
            `1` will be used.
          required: false
          schema:
            type: integer
            default: 1
        - name: pageSize
          in: query
          description: >-
            The number of items on a single page. If not specified, the default
            value `10` will be used.
          required: false
          schema:
            type: integer
            default: 10
        - name: userId
          in: query
          description: >-
            Your user ID. 


            How to obtain your user ID: Sign in to Powerdrill Enterprise, click
            **Users** in the top navigation bar, and find your user ID in the
            list of users.
          required: true
          schema:
            type: string
        - name: title
          in: query
          description: >-
            The search keyword. Sessions with names containing this keyword will
            be listed. If omitted, all sessions created by you will be listed.
          required: false
          schema:
            type: string
        - name: x-pd-external-trace-id
          in: header
          description: The external trace ID. The length ranges from 0 to 128 characters.
          required: false
          example: ''
          schema:
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: >-
                      Status code. **0** indicates that the operation is
                      successful. Otherwise, the operation fails. Possible error
                      codes include: 

                      - 100: Bad request. 

                      - 201: Request frequency limit.

                      - 9999: Internal error. 

                      - 100001: Invalid operation. 
                  data:
                    type: object
                    properties:
                      total:
                        type: integer
                        description: The total number of pages.
                      pageNumber:
                        type: integer
                        description: The number of pages returned.
                      pageSize:
                        type: integer
                        description: The number of items displayed per page.
                      records:
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                              description: The session ID.
                            title:
                              type: string
                              description: The session name.
                            languageType:
                              type: string
                              description: >-
                                The language in which the output is generated.
                                Possible values are:

                                - `AUTO`: adaptive recognition

                                - `EN`: English

                                - `ES`: Spanish

                                - `AR`: Arabic

                                - `PT`: Portuguese

                                - `ID`: Indonesian

                                - `JA`: Japanese

                                - `RU`: Russian

                                - `HI`: Hindi

                                - `FR`: French

                                - `DE`: German

                                - `VI`: Vietnamese

                                - `TR`: Turkish

                                - `PL`: Polish

                                - `IT`: Italian

                                - `KO`: Korean

                                - `ZH-CN`: Simplified Chinese

                                - `ZH-TW`: Traditional Chinese
                              enum:
                                - AUTO
                                - EN
                                - ES
                                - AR
                                - PT
                                - ID
                                - JA
                                - RU
                                - HI
                                - FR
                                - DE
                                - VI
                                - TR
                                - PL
                                - IT
                                - KO
                                - ZH-CN
                                - ZH-TW
                            jobMode:
                              type: string
                              description: >-
                                Job mode. Possible values are:

                                - `AUTO`: Powerdrill automatically detects your
                                intent and selects the appropriate job mode from
                                data analysis and information retrieval.

                                - `DATA_ANALYTICS`: Powerdrill focuses
                                specifically on data analysis.
                              enum:
                                - AUTO
                                - DATA_ANALYTICS
                            maxMessagesInContext:
                              type: integer
                              description: >-
                                The maximum number of messages retained per
                                session, with a value range of 0 to 10. The
                                default is 10.
                              minimum: 0
                              maximum: 10
                            agentId:
                              type: string
                              description: >-
                                The ID of the agent to use. You can leave it
                                blank or set it to **DATA_ANALYSIS_AGENT**.
                          description: The information about each record.
                          required:
                            - title
                            - languageType
                            - maxMessagesInContext
                            - jobMode
                            - id
                            - agentId
                        description: The list of records contained in the session.
                    required:
                      - total
                      - pageNumber
                      - pageSize
                      - records
                    description: The returned data object.
                required:
                  - data
                  - code
              examples:
                '1':
                  summary: Success example
                  value:
                    code: 0
                    data:
                      total: 8
                      pageSize: 10
                      pageNumber: 1
                      records:
                        - id: 04b69928-532d-408a-8716-8f5e70fcacc6
                          title: Finding Your Inner Spark
                          languageType: AUTO
                          jobMode: AUTO
                          maxMessagesInContext: 10
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
                        - id: 7e9941af-ad1b-4834-a421-4b37b54aae19
                          title: session_trade_analyze_001
                          languageType: EN
                          jobMode: AUTO
                          maxMessagesInContext: 1
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
                        - id: a137ecc8-9554-42c3-b042-2458dd2aeb36
                          title: My first session
                          languageType: AUTO
                          jobMode: AUTO
                          maxMessagesInContext: 10
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
                        - id: 4440ab38-3df0-465b-a66c-bf6acb0f1bc2
                          title: New Title
                          languageType: EN
                          jobMode: AUTO
                          maxMessagesInContext: 10
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
                        - id: 3eb5e294-11eb-4bf0-8854-7177c415d15c
                          title: trade_analyze_001
                          languageType: ZH-CN
                          jobMode: AUTO
                          maxMessagesInContext: 10
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
                        - id: ccca6d34-894f-4f6f-a8b5-c9df93126309
                          title: lhtest-old
                          languageType: ZH-CN
                          jobMode: AUTO
                          maxMessagesInContext: 5
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
                        - id: c28a1f47-da68-4456-bb0b-e85bf5a0e98e
                          title: lhtest-newest
                          languageType: ZH-TW
                          jobMode: AUTO
                          maxMessagesInContext: 6
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
                        - id: fbde9b45-69cd-408e-97d1-f874236aadac
                          title: General-session
                          languageType: ZH-CN
                          jobMode: AUTO
                          maxMessagesInContext: 10
                          agentId: DATA_ANALYSIS_AGENT
                          userId: tmm-cm5m7khoz52zh07n4m7x1ut60
          headers:
            x-pd-trace-id:
              example: ''
              required: true
              description: The trace ID of Powerdrill.
              schema:
                type: string
      deprecated: false
      security:
        - apikey-header-x-pd-api-key: []
components:
  securitySchemes:
    apikey-header-x-pd-api-key:
      type: apiKey
      in: header
      name: x-pd-api-key

````