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

# Add a payment instruction

> Adds a payment instruction to an existing beneficiary.



## OpenAPI

````yaml apis/fx-payment/openapi.yml POST /v1/beneficiaries/{beneficiaryId}/payment-instructions
openapi: 3.1.1
info:
  title: Trace Finance Payments API
  version: 1.0.0
  description: >
    API for deposits, withdrawals, swaps, and beneficiary management on the
    Trace Finance platform.
servers:
  - url: https://api.sandbox.tracefinance.com
    description: Sandbox
security:
  - bearerAuth: []
tags:
  - name: Operations
    description: >-
      Create deposits, withdrawals, and swaps. Query operation status and
      history.
  - name: Reports
    description: Generate aggregated views of operations across a time window.
  - name: Beneficiaries
    description: >-
      Manage external beneficiaries and their payment instructions for
      withdrawals.
  - name: Payment instructions
    description: Add or remove payment instructions on an existing beneficiary.
paths:
  /v1/beneficiaries/{beneficiaryId}/payment-instructions:
    post:
      tags:
        - Payment instructions
      summary: Add a payment instruction
      description: Adds a new payment instruction to an existing beneficiary.
      operationId: addPaymentInstruction
      parameters:
        - $ref: '#/components/parameters/BeneficiaryId'
        - $ref: '#/components/parameters/IdempotencyKey'
        - $ref: '#/components/parameters/TraceVersion'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PaymentInstructionRequest'
            examples:
              pixKey:
                summary: Add a PIX (DICT key)
                value:
                  rail: PIX_KEY
                  asset: BRL
                  dictKeyType: CPF
                  dictKey: '12345678900'
              pixBankInstruction:
                summary: Add a PIX (bank-account routing)
                value:
                  rail: PIX_BANK_INSTRUCTION
                  asset: BRL
                  bankCode: '001'
                  branch: '0001'
                  accountNumber: '123456'
      responses:
        '201':
          description: Payment instruction added. Returns the full beneficiary.
          headers:
            X-Request-Id:
              $ref: '#/components/headers/RequestId'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BeneficiaryResponse'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/BeneficiaryNotFound'
        '422':
          description: Validation error (invalid instruction type, missing details).
          headers:
            X-Request-Id:
              $ref: '#/components/headers/RequestId'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                missingPaymentInstructionDetails:
                  summary: Payment instruction is missing required fields
                  value:
                    code: MISSING_PAYMENT_INSTRUCTION_DETAILS
                    message: Missing required payment instruction details
                    details:
                      rail: PIX_BANK_INSTRUCTION
                      missingKeys:
                        - bankCode
                        - branch
                        - accountNumber
components:
  parameters:
    BeneficiaryId:
      name: beneficiaryId
      in: path
      required: true
      description: UUID of the beneficiary.
      schema:
        type: string
        format: uuid
    IdempotencyKey:
      name: X-Idempotency-Key
      in: header
      required: true
      description: >-
        Unique key to ensure idempotent request processing. Required on all
        `POST`, `PUT`, and `PATCH` requests.
      schema:
        type: string
        format: uuid
    TraceVersion:
      name: X-Trace-Version
      in: header
      required: false
      description: API version. Omit to use the default version.
      schema:
        type: string
        example: '1'
  schemas:
    PaymentInstructionRequest:
      description: Payment instruction for receiving funds. Discriminated by `rail`.
      oneOf:
        - $ref: '#/components/schemas/PixKeyInstructionRequest'
        - $ref: '#/components/schemas/PixBankInstructionRequest'
        - $ref: '#/components/schemas/CryptoWalletInstructionRequest'
      discriminator:
        propertyName: rail
        mapping:
          PIX_KEY: '#/components/schemas/PixKeyInstructionRequest'
          PIX_BANK_INSTRUCTION: '#/components/schemas/PixBankInstructionRequest'
          CRYPTO: '#/components/schemas/CryptoWalletInstructionRequest'
    BeneficiaryResponse:
      description: An external beneficiary registered for withdrawals.
      allOf:
        - $ref: '#/components/schemas/BeneficiaryBase'
        - type: object
          properties:
            paymentInstructions:
              type: array
              items:
                $ref: '#/components/schemas/PaymentInstructionResponse'
          required:
            - paymentInstructions
    ErrorResponse:
      type: object
      properties:
        code:
          type: string
          description: Machine-readable error code.
        message:
          type: string
          description: Human-readable description.
        details:
          type: object
          additionalProperties: true
      required:
        - code
        - message
    PixKeyInstructionRequest:
      title: PIX key
      description: PIX payment routed by a DICT key.
      allOf:
        - $ref: '#/components/schemas/PixKeyAddress'
        - $ref: '#/components/schemas/InstructionAsset'
    PixBankInstructionRequest:
      title: PIX bank instruction
      description: >-
        PIX payment routed by bank-account details (agency + account) instead of
        a DICT key.
      allOf:
        - type: object
          properties:
            rail:
              type: string
              enum:
                - PIX_BANK_INSTRUCTION
            bankCode:
              type: string
              description: >-
                COMPE code of the receiving bank. The server resolves it to the
                full `Bank` (name, ISPB) on the response side.
              example: '001'
            branch:
              type: string
              description: Branch number.
              example: '0001'
            accountNumber:
              type: string
              description: Account number.
              example: '123456'
          required:
            - rail
            - bankCode
            - branch
            - accountNumber
        - $ref: '#/components/schemas/InstructionAsset'
    CryptoWalletInstructionRequest:
      title: Crypto wallet
      description: Crypto-wallet payment routed by an on-chain address.
      allOf:
        - $ref: '#/components/schemas/CryptoWalletAddress'
        - $ref: '#/components/schemas/InstructionAsset'
        - type: object
          properties:
            custodyDetail:
              $ref: '#/components/schemas/CustodyDetail'
    BeneficiaryBase:
      type: object
      description: The fields shared by the full beneficiary and its list-endpoint summary.
      properties:
        id:
          type: string
          format: uuid
          example: ben-a1b2c3d4-5e6f-7890-abcd-ef1234567890
          readOnly: true
        customerId:
          type: string
          format: uuid
          description: Customer that owns this beneficiary.
        entity:
          $ref: '#/components/schemas/Entity'
        relationshipType:
          $ref: '#/components/schemas/RelationshipType'
        createdAt:
          type: string
          format: date-time
          example: '2026-04-14T10:30:00Z'
          readOnly: true
        updatedAt:
          type: string
          format: date-time
          example: '2026-04-14T10:30:00Z'
          readOnly: true
      required:
        - id
        - customerId
        - entity
        - relationshipType
        - createdAt
        - updatedAt
    PaymentInstructionResponse:
      type: object
      description: >-
        A payment instruction on a beneficiary. Use `address.rail` to
        discriminate routing details — for beneficiary payment instructions it
        is one of `PIX_KEY`, `PIX_BANK_INSTRUCTION`, or `CRYPTO`.
      properties:
        id:
          type: string
          format: uuid
          example: pi-a1b2c3d4-5e6f-7890-abcd-ef1234567890
          readOnly: true
        asset:
          $ref: '#/components/schemas/Asset'
        currentState:
          $ref: '#/components/schemas/InstructionState'
        address:
          $ref: '#/components/schemas/FinancialAddress'
        custodyDetail:
          oneOf:
            - $ref: '#/components/schemas/CustodyDetail'
            - type: 'null'
          description: >-
            Custody arrangement for the instruction. Present only for the
            `CRYPTO` rail; `null` for all other rails.
        createdAt:
          type: string
          format: date-time
          example: '2026-04-14T10:30:00Z'
          readOnly: true
        documents:
          type: array
          description: >-
            Compliance documents you have uploaded for the instruction. Empty
            until you upload one. This is what you sent — to know what is still
            **wanted**, read `requirements`.
          items:
            $ref: '#/components/schemas/BeneficiaryDocumentResponse'
          readOnly: true
        requirements:
          allOf:
            - $ref: '#/components/schemas/Requirements'
          description: >-
            What compliance is waiting on for this instruction, read live at
            request time. All four groups are empty for an instruction whose
            review has not started or has already been decided.
          readOnly: true
      required:
        - id
        - asset
        - currentState
        - address
        - createdAt
        - documents
        - requirements
    PixKeyAddress:
      title: PIX key
      type: object
      description: PIX route via DICT key.
      properties:
        rail:
          type: string
          enum:
            - PIX_KEY
        dictKeyType:
          $ref: '#/components/schemas/PixKeyType'
        dictKey:
          type: string
          description: DICT key value.
          example: john@example.com
      required:
        - rail
        - dictKeyType
        - dictKey
    InstructionAsset:
      type: object
      description: The asset a payment instruction settles in.
      properties:
        asset:
          $ref: '#/components/schemas/Asset'
      required:
        - asset
    CryptoWalletAddress:
      title: Crypto wallet
      type: object
      description: Crypto-wallet route.
      properties:
        rail:
          type: string
          enum:
            - CRYPTO
        network:
          type: string
          description: Blockchain network (e.g., `ETHEREUM`, `TRON`, `SOLANA`).
          example: ETHEREUM
        address:
          type: string
          description: Wallet address on `network`.
          example: '0x742d35Cc6634C0532925a3b844Bc9e7595f2bD18'
      required:
        - rail
        - network
        - address
    CustodyDetail:
      type: object
      description: >-
        Custody arrangement for a crypto payment instruction. Optional; when
        present, all three fields are required. Applies to the `CRYPTO` rail
        only. Required (together with the custody attestation document) only
        when the wallet is not custodied by Trace.
      properties:
        purpose:
          type: string
          description: Purpose of the wallet or its transfers.
          example: Treasury settlement
        custody:
          type: string
          description: Who custodies the wallet.
          example: Coinbase Custody
        counterparty:
          type: string
          description: Counterparty on the other side of the arrangement.
          example: Acme VASP Ltd
      required:
        - purpose
        - custody
        - counterparty
    Entity:
      description: The person or company that receives funds. Discriminated by `type`.
      oneOf:
        - $ref: '#/components/schemas/IndividualEntity'
        - $ref: '#/components/schemas/CompanyEntity'
      discriminator:
        propertyName: type
        mapping:
          INDIVIDUAL: '#/components/schemas/IndividualEntity'
          COMPANY: '#/components/schemas/CompanyEntity'
    RelationshipType:
      type: string
      enum:
        - SELF_OWNED
        - THIRD_PARTY
      description: >-
        Whether the beneficiary is the customer themselves (`SELF_OWNED`) or a
        separate party (`THIRD_PARTY`).
      example: THIRD_PARTY
    Asset:
      type: string
      enum:
        - BRL
        - USDT
        - USDC
      description: >
        ISO 4217 currency code or stablecoin ticker. The maximum decimal scale
        of an `AmountValue` paired with this asset depends on the asset:


        | Asset | Decimals |

        |---|---|

        | BRL | 2 |

        | USDT | 6 |

        | USDC | 6 |
      example: BRL
    InstructionState:
      type: object
      description: >-
        A single entry in a payment instruction's state history. Carries a
        status, optional reason (present only for `REJECTED`), and the time the
        state was entered.
      properties:
        status:
          $ref: '#/components/schemas/InstructionStatus'
        reason:
          $ref: '#/components/schemas/Reason'
          description: >-
            Justification for entering this status (e.g., why an instruction was
            `REJECTED`, or which document is being asked for on
            `ACTION_REQUIRED`). Present for `REJECTED` and `ACTION_REQUIRED`;
            omitted for `PENDING_REVIEW` and `APPROVED`.
        createdAt:
          type: string
          format: date-time
          description: Time the instruction entered this status.
      required:
        - status
        - createdAt
    FinancialAddress:
      description: >-
        A payment route, discriminated by `rail`. Beneficiary payment
        instructions emit one of `PIX_KEY`, `PIX_BANK_INSTRUCTION`, or `CRYPTO`;
        other rails appear in operation responses.
      oneOf:
        - $ref: '#/components/schemas/PixKeyAddress'
        - $ref: '#/components/schemas/PixBankInstructionAddress'
        - $ref: '#/components/schemas/PixStaticQrCodeAddress'
        - $ref: '#/components/schemas/BoletoAddress'
        - $ref: '#/components/schemas/CryptoWalletAddress'
      discriminator:
        propertyName: rail
        mapping:
          PIX_KEY: '#/components/schemas/PixKeyAddress'
          PIX_BANK_INSTRUCTION: '#/components/schemas/PixBankInstructionAddress'
          PIX_STATIC_QR_CODE: '#/components/schemas/PixStaticQrCodeAddress'
          BOLETO: '#/components/schemas/BoletoAddress'
          CRYPTO: '#/components/schemas/CryptoWalletAddress'
    BeneficiaryDocumentResponse:
      title: Document
      type: object
      description: >-
        A compliance document attached to a payment instruction. One document
        per type: re-uploading the same type replaces the file under review,
        keeping `referenceId` and increasing `version`.
      properties:
        referenceId:
          type: string
          description: >-
            Identifier of the document. Stable across re-uploads of the same
            document type, so it always points at the same reviewable document.
          example: doc-a1b2c3d4-5e6f-7890-abcd-ef1234567890
          readOnly: true
        type:
          $ref: '#/components/schemas/DocumentType'
        version:
          type: integer
          minimum: 1
          description: >-
            Which file of this document is currently under compliance review.
            Starts at `1` and increases by one on every re-upload of the same
            type. Previous versions are retained by compliance.
          example: 1
          readOnly: true
        currentState:
          allOf:
            - $ref: '#/components/schemas/DocumentState'
          description: >-
            Whether compliance is waiting on you for **this** document. Read
            this, not the instruction status, to know which file to replace.
          readOnly: true
      required:
        - referenceId
        - type
        - version
        - currentState
    Requirements:
      type: object
      description: >-
        What compliance is waiting on, grouped by what you have to do about it.
        The same shape is used for beneficiary payment instructions and for
        operations. Every group is always present; an empty one means there is
        nothing in that state.
      properties:
        currentlyDue:
          type: array
          description: Compliance is waiting on you to send these.
          items:
            $ref: '#/components/schemas/DocumentRequirement'
        pendingVerification:
          type: array
          description: You sent these and compliance is reviewing them. Nothing to do.
          items:
            $ref: '#/components/schemas/DocumentRequirement'
        errors:
          type: array
          description: >-
            These came back — sent, then refused or asked for again. `reason`
            says why. Send a new file for the same requirement.
          items:
            $ref: '#/components/schemas/DocumentRequirement'
        satisfied:
          type: array
          description: These are settled. Nothing to do.
          items:
            $ref: '#/components/schemas/DocumentRequirement'
      required:
        - currentlyDue
        - pendingVerification
        - errors
        - satisfied
      example:
        currentlyDue:
          - type: BENEFICIARY_DOCUMENT
            documentType: CUSTODY_ATTESTATION
            anyOf:
              - CUSTODY_ATTESTATION
        pendingVerification: []
        errors: []
        satisfied: []
    PixKeyType:
      type: string
      enum:
        - CPF
        - CNPJ
        - EMAIL
        - PHONE
        - RANDOM
      description: PIX key category. `RANDOM` is a random key issued by the central bank.
      example: CPF
    IndividualEntity:
      title: Individual
      type: object
      properties:
        type:
          type: string
          enum:
            - INDIVIDUAL
        firstName:
          type: string
          description: Given name.
          example: João
        lastName:
          type: string
          description: Family name.
          example: Silva
        identificationDocument:
          $ref: '#/components/schemas/IdentificationDocument'
        birthDate:
          type: string
          format: date
          description: Date of birth in ISO 8601 (`yyyy-MM-dd`).
          example: '1985-03-15'
        address:
          $ref: '#/components/schemas/Address'
      required:
        - type
        - firstName
        - lastName
        - identificationDocument
        - birthDate
        - address
    CompanyEntity:
      title: Company
      type: object
      properties:
        type:
          type: string
          enum:
            - COMPANY
        legalName:
          type: string
          description: Registered legal name.
          example: Acme Importação Ltda
        tradeName:
          type:
            - string
            - 'null'
          description: Trade name (DBA). `null` if the company doesn't use one.
          example: Acme
        identificationDocument:
          $ref: '#/components/schemas/IdentificationDocument'
        address:
          $ref: '#/components/schemas/Address'
      required:
        - type
        - legalName
        - identificationDocument
        - address
    InstructionStatus:
      type: string
      enum:
        - PENDING_REVIEW
        - ACTION_REQUIRED
        - APPROVED
        - REJECTED
      description: >
        Compliance review status of a payment instruction. New instructions
        start in `PENDING_REVIEW` and transition asynchronously to `APPROVED` or
        `REJECTED`.


        `ACTION_REQUIRED` means the review is waiting on **you**: compliance
        asked for another document, and `currentState.reason` says what for.
        Upload it with the instruction as the document `holder` and the
        instruction returns to `PENDING_REVIEW` on its own. Unlike `REJECTED`,
        this is not final — the same instruction can still be approved.


        Compliance can ask for more than one document, and it can ask for one
        you have never sent. `requirements` is the complete answer to *what is
        missing*: everything in `currentlyDue` and `errors` is still owed.
        `documents[].currentState` only covers files you already uploaded, so it
        can be empty while the instruction is `ACTION_REQUIRED`.


        The instruction returns to `PENDING_REVIEW` on its own once nothing is
        owed, so replacing one file does not necessarily end the wait.
      example: APPROVED
    Reason:
      type: object
      description: >-
        Machine- and human-readable explanation. Returned inside an
        `OperationState` entry when a status transition requires justification
        (e.g., `FAILED`).
      properties:
        code:
          type: string
          description: Machine-readable code.
          example: INSUFFICIENT_BALANCE
        message:
          type: string
          description: Human-readable description.
          example: Insufficient balance for the requested operation
        details:
          type: object
          additionalProperties: true
          description: Free-form context relevant to the reason.
      required:
        - code
        - message
        - details
    PixBankInstructionAddress:
      title: PIX bank instruction
      type: object
      description: PIX route via bank-account details (no DICT key).
      properties:
        rail:
          type: string
          enum:
            - PIX_BANK_INSTRUCTION
        bank:
          $ref: '#/components/schemas/Bank'
        branch:
          type: string
          description: Branch number.
          example: '0001'
        accountNumber:
          type: string
          description: Account number with check digit.
          example: '123456'
      required:
        - rail
        - bank
        - branch
        - accountNumber
    PixStaticQrCodeAddress:
      title: PIX static QR code
      type: object
      description: PIX route via static QR code payload.
      properties:
        rail:
          type: string
          enum:
            - PIX_STATIC_QR_CODE
        qrCode:
          type: string
          description: PIX QR code payload (EMV-encoded BR Code).
          example: 00020126580014br.gov.bcb.pix...
      required:
        - rail
        - qrCode
    BoletoAddress:
      title: Boleto
      type: object
      description: Boleto route.
      properties:
        rail:
          type: string
          enum:
            - BOLETO
        barcode:
          type: string
          description: Boleto barcode (digitable line).
          example: 23793.38128 60800.000003 00000.000400 1 84340000012345
        dueDate:
          type: string
          format: date-time
          description: Last day on which the boleto can be paid.
          example: '2026-05-15T23:59:59Z'
      required:
        - rail
        - barcode
        - dueDate
    DocumentType:
      type: string
      description: >-
        Type of compliance document. Beneficiary document upload supports only
        `CUSTODY_ATTESTATION`, which proves a crypto wallet's custody
        arrangement.
      enum:
        - CUSTODY_ATTESTATION
      example: CUSTODY_ATTESTATION
    DocumentState:
      type: object
      description: >-
        Review state of a single document. An instruction is `ACTION_REQUIRED`
        while any of its documents is — so with two documents asked for,
        replacing one leaves the instruction waiting on the other.
      properties:
        status:
          $ref: '#/components/schemas/DocumentStatus'
        reason:
          allOf:
            - $ref: '#/components/schemas/DocumentReason'
          description: >-
            Says the document is being asked for again. Present only for
            `ACTION_REQUIRED`. It does not carry the reviewer's own words — for
            what compliance actually said, read `requirements.errors[].reason`
            on the instruction.
        createdAt:
          type: string
          format: date-time
          example: '2026-04-14T10:30:00Z'
      required:
        - status
        - createdAt
    DocumentRequirement:
      type: object
      description: >-
        One thing compliance wants. The group it sits in says what state it is
        in, so the item does not repeat it.
      properties:
        type:
          type: string
          description: >-
            What the requirement is attached to: `BENEFICIARY_DOCUMENT` for a
            payment instruction, `OPERATION_DOCUMENT` for an operation.
          enum:
            - BENEFICIARY_DOCUMENT
            - OPERATION_DOCUMENT
          example: BENEFICIARY_DOCUMENT
        documentType:
          type: string
          description: >-
            What compliance asked for. Usually a single document type, but it
            can name a **family** of documents — `IDENTITY_VERIFICATION`, for
            example — in which case `anyOf` lists the ones that satisfy it.
          example: IDENTITY_VERIFICATION
        anyOf:
          type: array
          description: >-
            The document types that answer this requirement. **Any one of them
            settles it** — you do not send all of them. For a requirement naming
            a single document this holds exactly that one, so you can always
            read `anyOf` and ignore whether a family was asked for.
          items:
            type: string
          example:
            - PASSPORT
            - ID_CARD
            - DRIVER_LICENSE
            - RESIDENCE_PERMIT
        reason:
          allOf:
            - $ref: '#/components/schemas/DocumentReason'
          description: >-
            Why this requirement is open. Present when compliance explained
            itself, typically on `errors`.
      required:
        - type
        - documentType
        - anyOf
    IdentificationDocument:
      type: object
      description: >
        Identification document of a beneficiary entity. For tax-id types the
        `value` must match the format expected for the supplied `type` (e.g. a
        `CPF` must be 11 digits with valid check digits), and `country` is
        implied by the type, so it is omitted. Non-tax types (`PASSPORT`) carry
        an explicit `country`.
      properties:
        type:
          $ref: '#/components/schemas/IdentificationDocumentType'
        value:
          type: string
          description: >-
            Document value. Tax ids are digits only (no dots, dashes, or
            slashes).
          example: '52998224725'
        country:
          $ref: '#/components/schemas/Country'
      required:
        - type
        - value
    Address:
      type: object
      description: Postal address of an entity or beneficiary.
      properties:
        addressLine1:
          type: string
          description: Primary street line (number + street).
        addressLine2:
          type:
            - string
            - 'null'
          description: >-
            Secondary line (apartment, suite, building). `null` if not
            applicable.
        city:
          type:
            - string
            - 'null'
        state:
          type:
            - string
            - 'null'
          description: >-
            State, province, or region. `null` for countries without
            subdivisions in the address.
        country:
          $ref: '#/components/schemas/Country'
        postalCode:
          type: string
          description: Postal or ZIP code, formatted per the country's convention.
      required:
        - addressLine1
        - addressLine2
        - city
        - state
        - country
        - postalCode
    Bank:
      type: object
      description: >-
        Bank reference. Resolved server-side from the COMPE code provided in the
        request.
      properties:
        code:
          type: string
          description: COMPE code (3-digit Brazilian bank code, may be sent unpadded).
          example: '001'
        name:
          type: string
          description: Registered bank name.
          example: BANCO DO BRASIL S.A.
        ispbCode:
          type:
            - string
            - 'null'
          description: >-
            ISPB code (8-digit Brazilian payment-system identifier). `null` when
            the bank is not registered with an ISPB.
          example: '00000000'
      required:
        - code
        - name
        - ispbCode
    DocumentStatus:
      type: string
      enum:
        - PENDING_REVIEW
        - ACTION_REQUIRED
      description: >
        Review state of one document. `PENDING_REVIEW` means it is with
        compliance; `ACTION_REQUIRED` means they asked you to replace it and
        `reason` says why. Uploading a new version of that document returns it
        to `PENDING_REVIEW`.
      example: ACTION_REQUIRED
    DocumentReason:
      type:
        - object
        - 'null'
      description: >-
        Machine- and human-readable explanation attached to a compliance
        document ask.
      properties:
        code:
          type: string
          example: DOCUMENT_REQUESTED
        message:
          type: string
          example: The file is not legible
    IdentificationDocumentType:
      type: string
      description: >
        Identification document type. Tax-id types imply their country
        (`CPF`/`CNPJ` are Brazilian, `CUIT`/`CUIL` are Argentine, `RUT_CL` is
        Chilean, etc.); `PASSPORT` is a non-fiscal document and requires an
        explicit `country`.
      enum:
        - CPF
        - CNPJ
        - CUIT
        - CUIL
        - RUT_CL
        - RUT_UY
        - CI_UY
        - RUC
        - DNI_PE
        - NIT
        - CC
        - RFC
        - RUC_PY
        - CI_PY
        - NIPC
        - NIF_PT
        - CIF
        - NIF_ES
        - NIE
        - SIREN
        - SIRET
        - NIF_FR
        - PARTITA_IVA
        - CODICE_FISCALE
        - UST_IDNR
        - STEUER_ID
        - KVK
        - BSN
        - BCE
        - NN_BE
        - ORGANISATIONSNUMMER
        - PERSONNUMMER
        - ORGANISASJONSNUMMER
        - FODSELSNUMMER
        - UID_CH
        - AHV
        - VAT_GB
        - NIN
        - EIN
        - SSN
        - ITIN
        - BN_CA
        - SIN
        - ABN
        - TFN
        - USCC
        - CORPORATE_NUMBER_JP
        - MY_NUMBER
        - BRN_KR
        - RRN
        - GSTIN
        - PAN
        - INN_RU
        - COMPANY_NUMBER_IL
        - TEUDAT_ZEHUT
        - TRADE_LICENSE
        - EMIRATES_ID
        - CIPC
        - SA_ID
        - PASSPORT
      example: CPF
    Country:
      type: string
      description: ISO 3166-1 alpha-2 country code.
      example: BR
      enum:
        - AF
        - AL
        - DZ
        - AS
        - AD
        - AO
        - AI
        - AQ
        - AG
        - AR
        - AM
        - AW
        - AU
        - AT
        - AZ
        - BS
        - BH
        - BD
        - BB
        - BY
        - BE
        - BZ
        - BJ
        - BM
        - BT
        - BO
        - BQ
        - BA
        - BW
        - BV
        - BR
        - IO
        - BN
        - BG
        - BF
        - BI
        - CV
        - KH
        - CM
        - CA
        - KY
        - CF
        - TD
        - CL
        - CN
        - CX
        - CC
        - CO
        - KM
        - CD
        - CG
        - CK
        - CR
        - HR
        - CU
        - CW
        - CY
        - CZ
        - CI
        - DK
        - DJ
        - DM
        - DO
        - EC
        - EG
        - SV
        - GQ
        - ER
        - EE
        - SZ
        - ET
        - FK
        - FO
        - FJ
        - FI
        - FR
        - GF
        - PF
        - TF
        - GA
        - GM
        - GE
        - DE
        - GH
        - GI
        - GR
        - GL
        - GD
        - GP
        - GU
        - GT
        - GG
        - GN
        - GW
        - GY
        - HT
        - HM
        - VA
        - HN
        - HK
        - HU
        - IS
        - IN
        - ID
        - IR
        - IQ
        - IE
        - IM
        - IL
        - IT
        - JM
        - JP
        - JE
        - JO
        - KZ
        - KE
        - KI
        - KP
        - KR
        - KW
        - KG
        - LA
        - LV
        - LB
        - LS
        - LR
        - LY
        - LI
        - LT
        - LU
        - MO
        - MG
        - MW
        - MY
        - MV
        - ML
        - MT
        - MH
        - MQ
        - MR
        - MU
        - YT
        - MX
        - FM
        - MD
        - MC
        - MN
        - ME
        - MS
        - MA
        - MZ
        - MM
        - NA
        - NR
        - NP
        - NL
        - NC
        - NZ
        - NI
        - NE
        - NG
        - NU
        - NF
        - MP
        - 'NO'
        - OM
        - PK
        - PW
        - PS
        - PA
        - PG
        - PY
        - PE
        - PH
        - PN
        - PL
        - PT
        - PR
        - QA
        - MK
        - RO
        - RU
        - RW
        - RE
        - BL
        - SH
        - KN
        - LC
        - MF
        - PM
        - VC
        - WS
        - SM
        - ST
        - SA
        - SN
        - RS
        - SC
        - SL
        - SG
        - SX
        - SK
        - SI
        - SB
        - SO
        - ZA
        - GS
        - SS
        - ES
        - LK
        - SD
        - SR
        - SJ
        - SE
        - CH
        - SY
        - TW
        - TJ
        - TZ
        - TH
        - TL
        - TG
        - TK
        - TO
        - TT
        - TN
        - TR
        - TM
        - TC
        - TV
        - UG
        - UA
        - AE
        - GB
        - UM
        - US
        - UY
        - UZ
        - VU
        - VE
        - VN
        - VG
        - VI
        - WF
        - EH
        - YE
        - ZM
        - ZW
        - AX
  headers:
    RequestId:
      description: >-
        Unique request identifier emitted on every response. Reference it when
        contacting Trace Finance support so we can trace the request end-to-end.
        See [Errors](/guides/principles/errors).
      schema:
        type: string
        format: uuid
  responses:
    UnauthorizedError:
      description: Missing or invalid authentication token.
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            invalidToken:
              $ref: '#/components/examples/InvalidToken'
            expiredToken:
              $ref: '#/components/examples/ExpiredToken'
    BeneficiaryNotFound:
      description: Beneficiary not found.
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            beneficiaryNotFound:
              $ref: '#/components/examples/BeneficiaryNotFound'
  examples:
    InvalidToken:
      summary: Bearer token is invalid or malformed
      value:
        code: INVALID_ACCESS_TOKEN
        message: Invalid access token
        details: {}
    ExpiredToken:
      summary: Bearer token has expired
      value:
        code: EXPIRED_ACCESS_TOKEN
        message: Expired access token
        details: {}
    BeneficiaryNotFound:
      summary: Beneficiary does not exist for the authenticated customer
      value:
        code: RESOURCE_NOT_FOUND
        message: >-
          Beneficiary with given parameters
          [id:b2c3d4e5-f6a7-8901-bcde-f12345678901] not found
        details:
          resource: Beneficiary
          parameters:
            id: b2c3d4e5-f6a7-8901-bcde-f12345678901
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        JWT bearer token. Include as `Authorization: Bearer <token>`. See the
        [Authentication](/guides/authentication) guide for how to obtain one.

````

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