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

# Get a transaction

> Fetch one account transaction with its reconciliation details.

Returns one transaction recorded on the account, with its reconciliation details. See [Reconciliation](/payments/reconciliation).


## OpenAPI

````yaml openapi.json GET /v2/accounts/{accountId}/transactions/{transactionId}
openapi: 3.1.0
info:
  title: Stableyard Partner API
  version: 2.0.0-staging
  x-stableyard-api-version: '2026-09-09'
  x-stableyard-supported-api-versions:
    - '2026-09-09'
  summary: Backend API for UPAs, Payments, activity, and optional financial products.
  description: >

    Use this API from a trusted partner backend with an app ID and app secret.


    ## Recommended integration


    1. Call `GET /v2/partners/config` to verify credentials and discover enabled
    capabilities.

    2. Create a UPA only when your product needs a persistent Stableyard
    account.

    3. Create a receive or send Payment with `POST /v2/payments`.

    4. Redirect a payer to the returned `paymentUrl` or pass the Payment
    credentials to an official Stableyard interface SDK.

    5. Process signed webhooks and fetch the Payment by ID for reconciliation.


    Checkout execution and account-bound browser endpoints are intentionally
    documented in the separate Interfaces & SDKs reference. Console endpoints
    are dashboard implementation details and are not part of the partner
    integration contract.
  x-stableyard-documentation-surface: partner
servers:
  - url: https://prod-api.stableyard.fi
    description: Production
  - url: https://staging-api-v2.stableyard.fi
    description: Staging
  - url: http://localhost:3001
    description: Local
security: []
tags:
  - name: Authentication
    x-displayName: API authentication
    description: Verify your app ID and app secret before calling UPA APIs.
  - name: Accounts
    x-displayName: UPA Accounts
    description: Create Universal Payment Accounts and manage account settings.
  - name: Deposit Addresses
    description: Create reusable receive addresses and verify inbound deposits.
  - name: Identity & KYC
    description: >-
      Verify the UPA email and run provider-neutral identity verification.
      Managed vaults and fiat payment rails use this same verified UPA identity.
  - name: Vaults
    description: >-
      Create Safe/Zodiac controlled stablecoin vaults and manage policy updates
      for accounts.
  - name: Payments
    description: >-
      Create escrow-first payments, issue partner-authenticated send
      instructions or executions, power public checkout, and reconcile
      collection through final account settlement.
  - name: Balances & Transactions
    description: >-
      Read Stableyard-posted financial activity. Balances are ledger projections
      of activity Stableyard processed; they are not live balances of externally
      controlled wallets.
paths:
  /v2/accounts/{accountId}/transactions/{transactionId}:
    get:
      tags:
        - Balances & Transactions
      summary: Get transaction detail
      description: Fetch one transaction with reconciliation details.
      operationId: getAccountTransactionByAccountId
      parameters:
        - name: accountId
          in: path
          required: true
          schema:
            type: string
            example: acct_123
          description: Canonical account id returned by the Accounts API.
        - name: transactionId
          in: path
          required: true
          schema:
            type: string
            example: txn_123
        - name: Stableyard-Version
          in: header
          required: false
          schema:
            type: string
            enum:
              - '2026-09-09'
          description: >-
            Optional contract-version assertion. Omit it to use the app
            environment's pinned version. A different supported version is
            accepted only after that environment is explicitly migrated.
      responses:
        '200':
          description: Transaction detail
          headers:
            Stableyard-Version:
              description: >-
                Effective date-based Stableyard API contract version for this
                response.
              schema:
                type: string
                enum:
                  - '2026-09-09'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransactionDetailResponse'
              examples:
                example:
                  summary: Get transaction detail 200 response
                  value:
                    accountId: acct_123
                    transaction:
                      id: txn_123
                      accountId: acct_123
                      senderAccountId: acct_sender123
                      receiverAccountId: acct_receiver123
                      direction: sent
                      status: pending
                      amount:
                        asset:
                          chainId: 42161
                          tokenAddress: '0xaf88d065e77c8cC2239327C5EDb3A432268e5831'
                          symbol: USDC
                          decimals: 6
                          kind: token
                        amount: '1250000'
                      description: USDC payment
                      sourceType: payment
                      sourceId: payment_123
                      paymentId: payment_123
                      financialLegKind: collection
                    ledgerEntries:
                      - id: ledger_123
                        direction: debit
                        amount:
                          asset:
                            chainId: 42161
                            tokenAddress: '0xaf88d065e77c8cC2239327C5EDb3A432268e5831'
                            symbol: USDC
                            decimals: 6
                            kind: token
                          amount: '1250000'
                        createdAt: '2026-08-28T10:00:00.000Z'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '409':
          $ref: '#/components/responses/Conflict'
        '424':
          $ref: '#/components/responses/FailedDependency'
        '429':
          $ref: '#/components/responses/TooManyRequests'
      security:
        - partnerBasicAuth: []
components:
  schemas:
    TransactionDetailResponse:
      type: object
      required:
        - accountId
        - transaction
      properties:
        accountId:
          type: string
          example: acct_123
        transaction:
          $ref: '#/components/schemas/Transaction'
        ledgerEntries:
          type: array
          description: >-
            Redacted balanced ledger rows attached to this transaction for the
            requested account only.
          items:
            $ref: '#/components/schemas/LedgerEntry'
    Transaction:
      type: object
      required:
        - id
        - accountId
        - status
        - amount
        - description
        - sourceType
        - sourceId
      properties:
        offrampDetails:
          $ref: '#/components/schemas/OfframpTransactionDetails'
        id:
          type: string
          example: txn_123
        accountId:
          type: string
          example: acct_123
          description: Account whose perspective this response is for.
        senderAccountId:
          type: string
          example: acct_sender123
          description: Present when the perspective account is the sender.
        receiverAccountId:
          type: string
          example: acct_receiver123
          description: Present when the perspective account is the receiver.
        direction:
          type: string
          enum:
            - sent
            - received
            - self
            - related
        perspective:
          $ref: '#/components/schemas/TransactionPerspective'
        status:
          type: string
          enum:
            - pending
            - completed
            - posted
            - failed
            - reversed
        amount:
          allOf:
            - $ref: '#/components/schemas/Money'
          description: >-
            Amount for the requested account's perspective. For a Send, the
            sender sees the gross source debit and the recipient sees the net
            destination amount actually settled.
        description:
          type: string
          example: USDC payment
        sourceType:
          type: string
          enum:
            - payment
            - deposit
            - vault_funding
            - fee
            - refund
            - adjustment
        sourceId:
          type: string
          example: payment_123
        paymentId:
          type: string
          pattern: ^payment_[A-Za-z0-9_-]+$
          description: Canonical Payment associated with this financial leg.
        financialLegKind:
          type: string
          enum:
            - collection
            - send_execution
            - settlement
            - fee_payout
            - refund
            - adjustment
        sourceTransfer:
          type: object
          additionalProperties: false
          required:
            - amount
          properties:
            amount:
              $ref: '#/components/schemas/Money'
            txHash:
              type: string
              description: >-
                Source-chain transaction hash when the financial leg originated
                from an on-chain transfer.
            logIndex:
              type: integer
              minimum: 0
              description: >-
                Source-chain event index when the transfer was detected from an
                indexed token event.
            fromAddress:
              type: string
              description: >-
                On-chain sender address that funded this financial leg, when
                captured from the source chain.
        settlement:
          type: object
          additionalProperties: false
          required:
            - amount
            - txHash
          properties:
            amount:
              $ref: '#/components/schemas/Money'
            txHash:
              type:
                - string
                - 'null'
    LedgerEntry:
      type: object
      required:
        - id
        - direction
        - amount
        - createdAt
      properties:
        id:
          type: string
          example: ledger_123
        direction:
          type: string
          enum:
            - debit
            - credit
        amount:
          $ref: '#/components/schemas/Money'
        createdAt:
          type: string
          format: date-time
    ErrorResponse:
      type: object
      additionalProperties: false
      required:
        - error
      properties:
        error:
          type: object
          additionalProperties: false
          required:
            - code
            - message
          properties:
            code:
              type: string
              minLength: 1
              maxLength: 128
              example: bad_request
            message:
              type: string
              minLength: 1
              maxLength: 1000
              example: The request is invalid
            details: {}
    OfframpTransactionDetails:
      type: object
      additionalProperties: false
      description: >-
        Frozen off-ramp quote and recipient details. Bank account numbers are
        represented by their last four characters; unavailable recipient fields
        are null. Amounts are exact atomic strings and the exchange rate retains
        its direction.
      required:
        - version
        - country
        - destinationType
        - fiatAmount
        - fundingAmount
        - providerPrincipal
        - fees
        - exchangeRate
        - receiver
      properties:
        version:
          type: integer
          const: 1
        country:
          type: string
        destinationType:
          type: string
          enum:
            - external_qr
            - external_bank
            - bank_account
        fiatAmount:
          type: object
          additionalProperties: false
          required:
            - amountAtomic
            - assetCode
            - decimals
          properties:
            amountAtomic:
              type:
                - string
                - 'null'
              pattern: ^[0-9]+$
              description: >-
                Exact fiat amount scaled by the accompanying decimals
                (exact-input payout receipts can use six decimals), or null when
                unknown when this transaction snapshot was recorded (for
                example, an exact-input payout before provider completion). Null
                is not zero or proof of payout failure. Read the associated
                Payment for its current payout result.
            assetCode:
              type: string
            decimals:
              type: integer
        fundingAmount:
          oneOf:
            - $ref: '#/components/schemas/OfframpTransactionAmount'
            - type: 'null'
        providerPrincipal:
          oneOf:
            - $ref: '#/components/schemas/OfframpTransactionAmount'
            - type: 'null'
        fees:
          type: object
          additionalProperties: false
          required:
            - provider
            - platform
            - partner
          properties:
            provider:
              oneOf:
                - $ref: '#/components/schemas/OfframpTransactionAmount'
                - type: 'null'
            platform:
              oneOf:
                - $ref: '#/components/schemas/OfframpTransactionAmount'
                - type: 'null'
            partner:
              oneOf:
                - $ref: '#/components/schemas/OfframpTransactionAmount'
                - type: 'null'
        exchangeRate:
          oneOf:
            - type: object
              additionalProperties: false
              required:
                - rate
                - baseAssetCode
                - quoteAssetCode
              properties:
                rate:
                  type: string
                baseAssetCode:
                  type: string
                quoteAssetCode:
                  type: string
            - type: 'null'
        receiver:
          type: object
          additionalProperties: false
          required:
            - name
            - bankName
            - bankCode
            - accountNumberLast4
          properties:
            name:
              type:
                - string
                - 'null'
            bankName:
              type:
                - string
                - 'null'
            bankCode:
              type:
                - string
                - 'null'
            accountNumberLast4:
              type:
                - string
                - 'null'
    TransactionPerspective:
      type: object
      additionalProperties: false
      required:
        - accountId
        - direction
      properties:
        accountId:
          type: string
          example: acct_sender123
        direction:
          type: string
          enum:
            - sent
            - received
            - self
            - related
          description: >-
            Direction from the perspective of the account that requested or
            matched this transaction.
        counterpartyAccountId:
          type: string
          example: acct_receiver123
          description: Other Stableyard account on the transaction when known.
    Money:
      type: object
      required:
        - asset
        - amount
      properties:
        asset:
          $ref: '#/components/schemas/Asset'
        amount:
          type: string
          description: Atomic units for the token asset.
          example: '1250000'
    OfframpTransactionAmount:
      type: object
      additionalProperties: false
      required:
        - amountAtomic
        - assetCode
        - decimals
        - chainId
        - tokenAddress
      properties:
        amountAtomic:
          type: string
          pattern: ^[0-9]+$
        assetCode:
          type: string
        decimals:
          type: integer
        chainId:
          type: integer
        tokenAddress:
          type: string
    Asset:
      type: object
      required:
        - chainId
        - tokenAddress
        - symbol
        - decimals
      properties:
        chainId:
          type: integer
          enum:
            - 42161
            - 1
            - 8453
            - 137
            - 56
            - 43114
            - 4663
            - 4217
            - 10103
            - 10002
            - 728126428
            - 10001
          description: >-
            Supported deposit chain IDs: Arbitrum=42161, Ethereum=1, Base=8453,
            Polygon=137, BNB Smart Chain=56, Avalanche=43114, Robinhood
            Chain=4663, Tempo=4217, Solana=10103, Movement=10002,
            Tron=728126428, Bitcoin=10001.
        tokenAddress:
          type: string
          description: >-
            Contract/mint address for tokens, the EVM zero address for native
            EVM assets, native for BTC, or the Solana System Program address for
            SOL.
          example: '0xaf88d065e77c8cC2239327C5EDb3A432268e5831'
        symbol:
          type: string
          enum:
            - USDC
            - USDT
            - THBT
            - JPYC
            - USDG
            - BTC
            - ETH
            - POL
            - BNB
            - SOL
        decimals:
          type: integer
          enum:
            - 6
            - 8
            - 9
            - 18
        kind:
          type: string
          enum:
            - token
            - native
          description: >-
            Present on deposit-address supportedAssets entries to distinguish
            contract tokens from native gas assets.
  responses:
    BadRequest:
      description: Bad request
      headers:
        Stableyard-Version:
          description: >-
            Effective date-based Stableyard API contract version for this
            response.
          schema:
            type: string
            enum:
              - '2026-09-09'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            example:
              summary: BadRequest response
              value:
                error:
                  code: bad_request
                  message: The request is invalid
                  details: example
    Unauthorized:
      description: Unauthorized
      headers:
        Stableyard-Version:
          description: >-
            Effective date-based Stableyard API contract version for this
            response.
          schema:
            type: string
            enum:
              - '2026-09-09'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            example:
              summary: Unauthorized response
              value:
                error:
                  code: bad_request
                  message: The request is invalid
                  details: example
    Forbidden:
      description: The app secret does not include the required scope
      headers:
        Stableyard-Version:
          description: >-
            Effective date-based Stableyard API contract version for this
            response.
          schema:
            type: string
            enum:
              - '2026-09-09'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            example:
              summary: Forbidden response
              value:
                error:
                  code: bad_request
                  message: The request is invalid
                  details: example
    NotFound:
      description: Not found
      headers:
        Stableyard-Version:
          description: >-
            Effective date-based Stableyard API contract version for this
            response.
          schema:
            type: string
            enum:
              - '2026-09-09'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            example:
              summary: NotFound response
              value:
                error:
                  code: bad_request
                  message: The request is invalid
                  details: example
    Conflict:
      description: Conflict
      headers:
        Stableyard-Version:
          description: >-
            Effective date-based Stableyard API contract version for this
            response.
          schema:
            type: string
            enum:
              - '2026-09-09'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            example:
              summary: Conflict response
              value:
                error:
                  code: bad_request
                  message: The request is invalid
                  details: example
    FailedDependency:
      description: Required chain, network, or provider configuration is missing
      headers:
        Stableyard-Version:
          description: >-
            Effective date-based Stableyard API contract version for this
            response.
          schema:
            type: string
            enum:
              - '2026-09-09'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            example:
              summary: FailedDependency response
              value:
                error:
                  code: bad_request
                  message: The request is invalid
                  details: example
    TooManyRequests:
      description: >-
        Rate limit, payment-option limit, selection cooldown, or temporary abuse
        block
      headers:
        Stableyard-Version:
          description: >-
            Effective date-based Stableyard API contract version for this
            response.
          schema:
            type: string
            enum:
              - '2026-09-09'
        Retry-After:
          description: Seconds until the caller should retry.
          schema:
            type: integer
            minimum: 1
        RateLimit-Limit:
          description: Quota for the most constrained policy.
          schema:
            type: integer
            minimum: 1
        RateLimit-Remaining:
          description: Requests remaining in that policy window.
          schema:
            type: integer
            minimum: 0
        RateLimit-Reset:
          description: Seconds until that policy window resets.
          schema:
            type: integer
            minimum: 0
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            example:
              summary: TooManyRequests response
              value:
                error:
                  code: bad_request
                  message: The request is invalid
                  details: example
  securitySchemes:
    partnerBasicAuth:
      type: http
      scheme: basic
      description: >-
        HTTP Basic auth. Username is the Stableyard app ID. Password is the app
        secret. The optional Stableyard-Version request header must match the
        environment pin.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.