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

# List Transactions

> The List Transactions API endpoint allows you to retrieve a paginated list of transactions within a specified ledger.



## OpenAPI

````yaml ledger-openapi GET /v1/ledger/{ledger_key}/transaction
openapi: 3.0.0
info:
  title: Ledger API
  version: 0.0.0
servers:
  - url: https://api.sandbox.nxos.io
    description: single server endpoint
    variables: {}
security: []
tags: []
paths:
  /v1/ledger/{ledger_key}/transaction:
    get:
      summary: List Transactions
      description: >-
        The List Transactions API endpoint allows you to retrieve a paginated
        list of transactions within a specified ledger.
      operationId: Transactions_listTransactions
      parameters:
        - $ref: '#/components/parameters/BasicAuthHeader'
        - $ref: '#/components/parameters/LedgerKey'
        - $ref: '#/components/parameters/PaginationQuery.cursor'
        - $ref: '#/components/parameters/PaginationQuery.limit'
        - $ref: >-
            #/components/parameters/ListTransactionsQueryParams.source_account_id
        - $ref: >-
            #/components/parameters/ListTransactionsQueryParams.source_account_ref
        - $ref: >-
            #/components/parameters/ListTransactionsQueryParams.destination_account_id
        - $ref: >-
            #/components/parameters/ListTransactionsQueryParams.destination_account_ref
      responses:
        '200':
          description: The request has succeeded.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Transaction'
components:
  parameters:
    BasicAuthHeader:
      name: Authorization
      in: header
      required: true
      description: |-
        The Basic Authentication header.
        Format: "Basic {base64(orgID:apiKey)}"
      schema:
        type: string
    LedgerKey:
      name: ledger_key
      in: path
      required: true
      description: |-
        The key of the ledger. 
        Examples: 
        - "123e4567-e89b-12d3-a456-426614174000"
        - "id:123e4567-e89b-12d3-a456-426614174000"
        - "ref:ledger:customer_a"
      schema:
        type: string
    PaginationQuery.cursor:
      name: cursor
      in: query
      required: false
      description: >-
        The cursor for the next set of results.

        This is an opaque string representing the starting point for the next
        page.

        For the first request, this should be omitted or set to null.
      schema:
        type: string
    PaginationQuery.limit:
      name: limit
      in: query
      required: false
      description: |-
        The number of items to be returned per page.
        Determines the page size for the paginated results.
        Default value: 25
        Maximum value: 100 (to prevent excessive load on the server)
      schema:
        type: integer
        format: int32
        default: 25
    ListTransactionsQueryParams.source_account_id:
      name: source_account_id
      in: query
      required: false
      description: >-
        The id of the source account for the transaction - lists all
        transactions where the account was the source
      schema:
        type: string
    ListTransactionsQueryParams.source_account_ref:
      name: source_account_ref
      in: query
      required: false
      description: >-
        The reference of the source account for the transaction - lists all
        transactions where the account was the source
      schema:
        type: string
    ListTransactionsQueryParams.destination_account_id:
      name: destination_account_id
      in: query
      required: false
      description: >-
        The id of the destination account for the transaction - lists all
        transactions where the account was the destination
      schema:
        type: string
    ListTransactionsQueryParams.destination_account_ref:
      name: destination_account_ref
      in: query
      required: false
      description: >-
        The reference of the destination account for the transaction - lists all
        transactions where the account was the destination
      schema:
        type: string
  schemas:
    Transaction:
      type: object
      required:
        - transaction_id
        - asset_moves
        - created_at
        - updated_at
      properties:
        transaction_id:
          type: string
          format: uuid
          description: The unique internally assigned identifier of the transaction
        transaction_ref:
          type: string
          description: The externally defined reference of the transaction
        asset_moves:
          type: array
          items:
            $ref: '#/components/schemas/AssetMove'
          description: The asset moves for the transaction
        created_at:
          type: string
          format: date-time
          description: The created at timestamp
        updated_at:
          type: string
          format: date-time
          description: The updated at timestamp
    AssetMove:
      type: object
      required:
        - asset_move_ref
        - source_account
        - destination_account
        - asset_code
        - amount
        - status
        - type
        - created_at
        - updated_at
      properties:
        asset_move_ref:
          type: string
          format: uuid
          description: >-
            The unique reference of the asset move, set by you when creating the
            asset move
        source_account:
          allOf:
            - $ref: '#/components/schemas/AssetMoveAccount'
          description: The representation of the source account
        destination_account:
          allOf:
            - $ref: '#/components/schemas/AssetMoveAccount'
          description: The represantation of the destination account
        asset_code:
          type: string
          minLength: 1
          description: The reference of the asset
        amount:
          type: string
          description: The amount of the asset to move
        status:
          allOf:
            - $ref: '#/components/schemas/AssetMoveStatus'
          description: The status of the asset move
        type:
          type: string
          minLength: 1
          description: The type of the asset move
        decline_type:
          type: string
          description: >-
            the specific decline reason for the asset move in case the
            asset-move has been declined. 

            This can be a system-defined reason such as INSUFFICIENT_FUNDS, or
            LIMIT_EXCEEDED, or it can be

            a custom defined type of so set during the transaction creation
        categories:
          type: array
          items:
            type: string
          description: The categories of the asset move
        metadata:
          type: object
          additionalProperties: {}
          description: Additional, optional, metadata for the asset move
        created_at:
          type: string
          format: date-time
          description: The created at timestamp
        updated_at:
          type: string
          format: date-time
          description: The updated at timestamp
    AssetMoveAccount:
      type: object
      properties:
        ref:
          type: string
          description: The user-defined reference of the account.
        id:
          type: string
          description: The system-generated ID of the account.
      description: >-
        Represents an account reference for asset moves.

        Used to specify source or destination accounts in asset movement
        operations.

        Exactly one of 'ref' or 'id' must be provided.
    AssetMoveStatus:
      type: string
      enum:
        - EXPECTED
        - LOCKED
        - COMPLETED
        - DECLINED
        - REFUNDED
      description: >-
        Represents the current status of an asset move.

        Asset moves are transfers of assets between accounts and form the basis
        of transactions.

        Note: LOCKED and COMPLETED statuses affect account balances, while

        EXPECTED, DECLINED, and REFUNDED do not impact or release cap

````