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

# Get transaction

> Fetch one transaction by Tanda ID or your reference.



## OpenAPI

````yaml GET /api/b2b/transactions/{transactionId}
openapi: 3.1.0
info:
  title: Tanda API
  version: 1.0.0
  description: >-
    Collect and send KES payments in Kenya through M-PESA, Airtel Money and bank
    transfer.
servers:
  - url: https://api.tandapay.io
    description: Sandbox and production (your keys decide which)
security:
  - bearerAuth: []
tags:
  - name: Authentication
  - name: Account
  - name: Checkout
  - name: Collections
  - name: Payouts
  - name: Beneficiaries
  - name: Transactions
  - name: Reference data
  - name: Webhooks
paths:
  /api/b2b/transactions/{transactionId}:
    get:
      tags:
        - Transactions
      summary: Get transaction
      description: >-
        Returns one transaction. You can pass the Tanda `transactionId` or your
        own `externalReference`. Use this to confirm the outcome before
        releasing value.
      operationId: get-transaction
      parameters:
        - name: transactionId
          in: path
          required: true
          description: The Tanda `transactionId` or your `externalReference`.
          schema:
            type: string
          example: aB3dE5fG7hJ9kL1mN2pQ
      responses:
        '200':
          description: Transaction.
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                  data:
                    $ref: '#/components/schemas/Transaction'
              example:
                success: true
                data:
                  transactionId: aB3dE5fG7hJ9kL1mN2pQ
                  externalReference: order_10045
                  type: deposit
                  method: mpesa
                  amount: 1500
                  currency: KES
                  senderAmount: 1500
                  senderCurrency: KES
                  receiverAmount: 1500
                  receiverCurrency: KES
                  status: SUCCESSFUL
                  chargeStatus: successful
                  thirdPartyReference: TJS4K2LM9P
                  phoneNumber: '254712345678'
                  note: Payment received
                  fullTimestamp: '2026-10-28T09:14:22.000Z'
        '401':
          description: Missing, invalid or expired bearer token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                success: false
                message: Unauthorized
components:
  schemas:
    Transaction:
      type: object
      properties:
        transactionId:
          type: string
        externalReference:
          type: string
        type:
          type: string
          description: '`deposit` (collection), `withdrew` (payout) or `refund`.'
          enum:
            - deposit
            - withdrew
            - refund
        method:
          type: string
          description: >-
            Rail used. Webhooks report `momo` or `bank`; transaction records may
            name the network instead, e.g. `mpesa`.
        amount:
          type: number
        currency:
          type: string
        chargeCurrency:
          type: string
          description: 'Checkout payments: currency the customer paid in.'
        walletCurrency:
          type: string
          description: 'Checkout payments: wallet credited.'
        customerId:
          type: string
          description: 'Checkout payments: the `customerId` you sent.'
        senderAmount:
          type: number
        senderCurrency:
          type: string
        receiverAmount:
          type: number
        receiverCurrency:
          type: string
        status:
          type: string
          description: Uppercase status.
          enum:
            - PENDING
            - SUCCESSFUL
            - FAILED
        chargeStatus:
          type: string
          description: Lowercase status. Fulfil only on `successful`.
          enum:
            - pending
            - successful
            - failed
        stepRequired:
          type: string
          description: Customer action needed, if any.
          enum:
            - otp
            - redirect
        redirectUrl:
          type: string
          description: Present when `stepRequired` is `redirect`.
        thirdPartyReference:
          type: string
          description: Network or bank reference, e.g. the M-PESA receipt.
        note:
          type: string
          description: Detail, often the failure reason. Don't parse it for logic.
        phoneNumber:
          type: string
        fullTimestamp:
          type: string
          format: date-time
    Error:
      type: object
      properties:
        success:
          type: boolean
          example: false
        message:
          type: string
          description: Human-readable; may change.
        errorCode:
          type: string
          description: Stable code to branch on.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Token from Generate bearer token.

````

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