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

# Get all OAuth access tokens for a given OAuth app.

> This endpoint returns all OAuth access tokens for a given OAuth app.



## OpenAPI

````yaml get /v1/core/oauth/apps/{clientId}/access-token
openapi: 3.0.0
info:
  version: 1.0.0
  title: Swagger API
servers:
  - url: https://functions.siro.ai/api-externalApi
    description: Siro API external API endpoint
security: []
externalDocs:
  description: View the raw OpenAPI Specification in JSON format
  url: /swagger.json
paths:
  /v1/core/oauth/apps/{clientId}/access-token:
    get:
      summary: Get all OAuth access tokens for a given OAuth app.
      description: This endpoint returns all OAuth access tokens for a given OAuth app.
      parameters:
        - schema:
            type: string
            description: The OAuth app that the tokens are bound to.
          required: true
          description: The OAuth app that the tokens are bound to.
          name: clientId
          in: path
        - schema:
            type: string
            minLength: 1
            description: The id of the user that created one or more OAuth access tokens.
          required: true
          description: The id of the user that created one or more OAuth access tokens.
          name: owner
          in: query
        - schema:
            type: string
            format: date-time
            description: Return OAuth access tokens created after this date.
          required: false
          description: Return OAuth access tokens created after this date.
          name: fromDate
          in: query
        - schema:
            type: string
            format: date-time
            description: Return OAuth access tokens created before this date.
          required: false
          description: Return OAuth access tokens created before this date.
          name: toDate
          in: query
        - schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 100
            description: >-
              The number of results to return. If omitted, 100 results will be
              returned.
          required: false
          description: >-
            The number of results to return. If omitted, 100 results will be
            returned.
          name: limit
          in: query
        - schema:
            type: string
            minLength: 1
            description: >-
              The cursor to paginate the results. Cursor-based pagination will
              always be used unless if left blank and a page number is provided.
          required: false
          description: >-
            The cursor to paginate the results. Cursor-based pagination will
            always be used unless if left blank and a page number is provided.
          name: cursor
          in: query
        - schema:
            type: integer
            minimum: 1
            description: >-
              The page number to return. If omitted, the first page of results
              will be returned.
          required: false
          description: >-
            The page number to return. If omitted, the first page of results
            will be returned.
          name: page
          in: query
        - schema:
            type: string
            enum:
              - dateCreated
              - dateUpdated
            default: dateCreated
            description: >-
              The field to sort the results by. If omitted, the results will be
              sorted by dateCreated in descending order.
          required: false
          description: >-
            The field to sort the results by. If omitted, the results will be
            sorted by dateCreated in descending order.
          name: sortField
          in: query
        - schema:
            type: string
            enum:
              - asc
              - desc
            default: desc
            description: >-
              The direction to sort the results by. If omitted, the results will
              be sorted by dateCreated in descending order.
          required: false
          description: >-
            The direction to sort the results by. If omitted, the results will
            be sorted by dateCreated in descending order.
          name: sortDirection
          in: query
      responses:
        '200':
          description: Get all OAuth access tokens for a given OAuth app.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        accessTokenId:
                          type: string
                          description: The ID of the OAuth access token.
                        oAuthAppId:
                          type: string
                          description: The OAuth app that this token is bound to.
                        userId:
                          type: string
                          description: >-
                            The user that this token is bound to. This is also
                            the subject of the token.
                        audience:
                          type: string
                          description: The intended audience of the token.
                        subject:
                          type: string
                          description: The subject of the token.
                        scope:
                          type: string
                          enum:
                            - read
                            - write
                          description: >-
                            One of ("read", "write"). This will restrict what
                            HTTP verbs the token has access to.
                        expiresAt:
                          type: string
                          format: date-time
                          description: The expiration date of the token.
                        createdAt:
                          type: string
                          format: date-time
                          description: The creation date of the token.
                        updatedAt:
                          type: string
                          format: date-time
                          description: The last update date of the token.
                        revokedAt:
                          type: string
                          nullable: true
                          format: date-time
                          description: The date the token was revoked
                      required:
                        - accessTokenId
                        - oAuthAppId
                        - userId
                        - audience
                        - subject
                        - scope
                        - expiresAt
                        - createdAt
                        - updatedAt
                        - revokedAt
                  cursor:
                    anyOf:
                      - type: string
                      - type: number
                      - nullable: true
                  pageSize:
                    type: number
                  limit:
                    type: number
                  total:
                    type: number
                    nullable: true
                  hasNextPage:
                    type: boolean
                required:
                  - data
        '400':
          description: Bad Request - Invalid parameters
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error message
                required:
                  - error
        '401':
          description: Unauthorized - User not authenticated
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Authentication error message
                required:
                  - error
        '403':
          description: Forbidden - User does not have access
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Authorization error message
                required:
                  - error
        '404':
          description: Not Found - Resource not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Resource not found error message
                required:
                  - error
        '422':
          description: Unprocessable Content - The request failed validation checks
          content:
            application/json:
              schema:
                type: object
                properties:
                  issues:
                    type: array
                    items:
                      type: object
                      properties:
                        code:
                          type: string
                        expected:
                          type: string
                        received:
                          type: string
                        path:
                          type: array
                          items:
                            anyOf:
                              - type: string
                              - type: number
                        message:
                          type: string
                      required:
                        - code
                        - path
                        - message
                  name:
                    type: string
                    enum:
                      - ZodError
                required:
                  - issues
                  - name
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Internal server error message
                required:
                  - error
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: Organization API token
      description: >-
        Organization integration token from Siro admin (Person icon → API
        Tokens). Send Authorization: Bearer <organization-api-token>. This is
        not the OAuth access token used with api.siro.ai user-scoped endpoints.
      x-default: <organization-api-token>

````