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

# Get customer transactions

> Get a paginated list of transactions for a customer by external ID (e.g. the customer ID in your system).



## OpenAPI

````yaml https://platform.runonatlas.com/external/schema get /external/customers/external-id/{externalId}/transactions
openapi: 3.0.0
info:
  title: Atlas API
  version: 1.0.0
servers:
  - url: https://platform.runonatlas.com
security: []
paths:
  /external/customers/external-id/{externalId}/transactions:
    get:
      tags:
        - Customers
      summary: Get customer transactions
      description: >-
        Get a paginated list of transactions for a customer by external ID (e.g.
        the customer ID in your system).
      parameters:
        - schema:
            type: string
            minLength: 1
            description: >-
              The external ID of the customer (e.g. the customer ID in your
              system)
            example: external-customer-id-123
          required: true
          description: >-
            The external ID of the customer (e.g. the customer ID in your
            system)
          name: externalId
          in: path
        - schema:
            type: string
            enum:
              - asc
              - desc
            default: asc
            description: The order of the results.
            example: asc
          required: false
          description: The order of the results.
          name: order
          in: query
        - schema:
            type: integer
            minimum: 1
            default: 1
            description: The page number of the results.
            example: 1
          required: false
          description: The page number of the results.
          name: page
          in: query
        - schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 10
            description: The number of results per page.
            example: 10
          required: false
          description: The number of results per page.
          name: pageSize
          in: query
      responses:
        '200':
          description: The transactions that have been retrieved.
          content:
            application/json:
              schema:
                type: object
                properties:
                  results:
                    type: array
                    items:
                      type: object
                      properties:
                        allocationBlockId:
                          type: string
                          minLength: 1
                          description: >-
                            The Atlas allocation block ID associated with the
                            transaction
                          example: atlas-internal-allocation-block-id-123
                        billableId:
                          type: string
                          nullable: true
                          minLength: 1
                          description: >-
                            The Atlas billable ID associated with the
                            transaction. Only present for usage transactions.
                          example: atlas-internal-billable-id-123
                        createdAt:
                          type: string
                          format: date
                          description: The date and time the transaction was created
                          example: '2021-01-01T00:00:00.000Z'
                        eventId:
                          type: string
                          nullable: true
                          minLength: 1
                          description: >-
                            The Atlas event ID associated with the transaction.
                            Only present for usage transactions.
                          example: atlas-internal-event-id-123
                        id:
                          type: string
                          minLength: 1
                          description: The Atlas transaction ID
                          example: atlas-internal-transaction-id-123
                        merchantId:
                          type: string
                          minLength: 1
                          description: >-
                            The Atlas merchant ID associated with the
                            transaction
                          example: atlas-internal-merchant-id-123
                        operationId:
                          type: string
                          nullable: true
                          minLength: 1
                          description: >-
                            The Atlas operation ID. Used to link two
                            transactions together, like an overageTransfer which
                            consists of two transactions: 1. A positive
                            transaction to the overage block 2. A negative
                            transaction to the new allocation block
                          example: atlas-internal-operation-id-123
                        type:
                          type: string
                          enum:
                            - autoReload
                            - expiration
                            - manualAddition
                            - manualDeduction
                            - overageTransfer
                            - planAllocation
                            - usage
                          description: The type of transaction
                          example: planAllocation
                        updatedAt:
                          type: string
                          format: date
                          description: The date and time the transaction was last updated
                          example: '2021-01-01T00:00:00.000Z'
                        amount:
                          type: number
                          description: >-
                            The amount of the transaction in specified custom
                            pricing units
                          example: 100
                        billable:
                          type: object
                          nullable: true
                          properties:
                            id:
                              type: string
                              minLength: 1
                              description: >-
                                The Atlas billable ID associated with the
                                transaction
                              example: atlas-internal-billable-id-123
                            name:
                              type: string
                              minLength: 1
                              description: >-
                                The name of the billable associated with the
                                transaction
                              example: AI Generation
                          required:
                            - id
                            - name
                          description: The billable associated with the transaction
                        allocationBlock:
                          type: object
                          nullable: true
                          properties:
                            id:
                              type: string
                              minLength: 1
                              description: >-
                                The Atlas allocation block ID associated with
                                the transaction
                              example: atlas-internal-allocation-block-id-123
                            amount:
                              type: number
                              description: >-
                                The amount of the allocation block in specified
                                custom pricing units
                              example: 100
                            customPricingUnitId:
                              type: string
                              minLength: 1
                              description: >-
                                The Atlas custom pricing unit ID associated with
                                the allocation block
                              example: atlas-internal-custom-pricing-unit-id-123
                            customPricingUnit:
                              type: object
                              properties:
                                displayName:
                                  type: string
                                  minLength: 1
                                  description: >-
                                    The display name of the custom pricing unit
                                    associated with the allocation block
                                  example: API Credits
                              required:
                                - displayName
                              description: >-
                                The custom pricing unit associated with the
                                allocation block
                            invoice:
                              type: object
                              nullable: true
                              properties:
                                id:
                                  type: string
                                  minLength: 1
                                  description: >-
                                    The Atlas invoice ID associated with the
                                    allocation block
                                  example: atlas-internal-invoice-id-123
                                vanityId:
                                  type: number
                                  description: The vanity ID of the invoice
                                  example: 123456
                              required:
                                - id
                                - vanityId
                              description: The invoice associated with the allocation block
                            subscription:
                              type: object
                              nullable: true
                              properties:
                                billingCadence:
                                  type: string
                                  nullable: true
                                  enum:
                                    - oneTime
                                    - monthly
                                    - quarterly
                                    - annually
                                  description: The billing cadence of the subscription
                                  example: monthly
                                plan:
                                  type: object
                                  nullable: true
                                  properties:
                                    name:
                                      type: string
                                      minLength: 1
                                      description: >-
                                        The name of the plan associated with the
                                        subscription
                                      example: Basic Plan
                                  required:
                                    - name
                                  description: The plan associated with the subscription
                              required:
                                - billingCadence
                                - plan
                              description: >-
                                The subscription associated with the allocation
                                block
                          required:
                            - id
                            - amount
                            - customPricingUnitId
                            - customPricingUnit
                            - invoice
                            - subscription
                          description: The allocation block associated with the transaction
                      required:
                        - allocationBlockId
                        - createdAt
                        - id
                        - merchantId
                        - type
                        - updatedAt
                        - amount
                        - billable
                        - allocationBlock
                  count:
                    type: number
                    description: The total number of results.
                    example: 100
                  pages:
                    type: number
                    description: The total number of pages.
                    example: 10
                  currentPage:
                    type: number
                    description: The current page number.
                    example: 1
                required:
                  - results
                  - count
                  - pages
                  - currentPage
        '400':
          description: >-
            There is an issue with the request data. See the response for more
            details.
        '401':
          description: Invalid API key provided.
      security:
        - apiKeyAuth: []
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      name: x-api-key
      in: header
      description: >-
        You can obtain this key from the Atlas dashboard. It must be of type
        `secret`

````