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

# List all Deposit Addresses

> List all Deposit Addresses across the organization. Spans every customer
in the caller's organization; optionally filter by status and/or customer.



## OpenAPI

````yaml /api-reference/openapi.yaml get /deposit-addresses
openapi: 3.0.3
info:
  title: Polygon OMS Public API
  version: v26.05.28-0001
  description: >-
    Unified API for moving money between crypto and fiat. Three ways to move
    money: Transactions (instant, wallet or card funded, including Cash-In for
    in-person cash deposits), Deposit Addresses (reusable crypto deposit
    configurations), and Virtual Accounts (dedicated bank accounts that
    auto-convert fiat to crypto). Standard transactions follow a two-step flow:
    create a Quote (pricing), then create a Transaction (execution). Cash-in
    codes generate a one-time deposit code for in-person cash deposits at retail
    locations.
  contact:
    name: Polygon OMS
    url: https://oms.polygon.technology
servers:
  - url: https://sandbox-api.polygon.technology/v0.13
    description: Sandbox
  - url: https://api.polygon.technology/v0.13
    description: Production
security:
  - BearerAuth: []
tags:
  - name: Auth
    description: Authentication via FrontEgg
  - name: Customers
    description: Customer management and KYC
  - name: Customer
  - name: Wallet
  - name: Quote
  - name: Transaction
  - name: CashIns
  - name: CashLocation
  - name: Sandbox
  - name: VirtualAccount
  - name: Counterparty
  - name: ExternalAccount
  - name: Reference
  - name: DepositAddress
paths:
  /deposit-addresses:
    get:
      tags:
        - DepositAddress
      summary: List all Deposit Addresses
      description: >-
        List all Deposit Addresses across the organization. Spans every customer

        in the caller's organization; optionally filter by status and/or
        customer.
      operationId: listDepositAddresses
      parameters:
        - $ref: '#/components/parameters/PaginationParams.limit'
        - $ref: '#/components/parameters/PaginationParams.startingAfter'
        - $ref: '#/components/parameters/PaginationParams.endingBefore'
        - name: status
          in: query
          required: false
          description: Filter by status.
          schema:
            $ref: '#/components/schemas/DepositAddressStatus'
        - name: customerId
          in: query
          required: false
          description: Filter to a single customer (`cst_` prefix).
          schema:
            type: string
      responses:
        '200':
          description: The request has succeeded.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DepositAddressList'
components:
  parameters:
    PaginationParams.limit:
      name: limit
      in: query
      required: false
      description: >-
        Page size, supported range 1-100. The default and maximum are
        per-resource

        (see each endpoint's description; most endpoints default to

        50) and are resolved at runtime from configuration. Values outside the
        range

        are clamped to the nearest bound rather than rejected. The range is
        published

        machine-readably via the `x-minimum`/`x-maximum` OpenAPI extensions
        below —

        deliberately NOT via `@minValue`/`@maxValue`, which emit JSON-Schema

        `minimum`/`maximum` and make the generated SDK (Zod) reject values the
        server

        accepts and clamps. See `PaginatedList.limit` for the effective value
        applied.
      schema:
        type: integer
        format: int32
      x-maximum: 100
      x-minimum: 1
    PaginationParams.startingAfter:
      name: startingAfter
      in: query
      required: false
      schema:
        type: string
    PaginationParams.endingBefore:
      name: endingBefore
      in: query
      required: false
      schema:
        type: string
  schemas:
    DepositAddressStatus:
      type: string
      enum:
        - pending
        - active
        - frozen
        - closed
        - failed
        - inactiveActionRequired
      description: >-
        Lifecycle of a Deposit Address. pending: awaiting on-chain address

        assignment. active: accepting deposits. frozen: deposits held by
        compliance.

        inactiveActionRequired: destination unusable, re-point `destination` to

        recover. closed: permanently disabled. failed: provisioning failed.
    DepositAddressList:
      type: object
      properties:
        object:
          type: string
          description: Resource type discriminator.
        limit:
          type: integer
          format: int32
          description: |-
            The effective page size applied to this response, after clamping an
            out-of-range or unset requested `limit` into the supported bound.
        hasMore:
          type: boolean
          description: >-
            True when more rows exist beyond this page in the direction of
            travel (forward by default, backward when `endingBefore` was
            supplied).
        nextCursor:
          type: string
          description: |-
            Opaque cursor pointing at the last item in this page. Present when
            `data` is non-empty. Pass as `startingAfter` to fetch the next page;
            `hasMore=false` signals no more pages forward.
        previousCursor:
          type: string
          description: >-
            Opaque cursor pointing at the first item in this page. Present when

            `data` is non-empty. Pass as `endingBefore` to page backward; when

            this yields an empty response the client is at the start of the
            list.
        data:
          type: array
          items:
            $ref: '#/components/schemas/DepositAddress'
          description: The page of results.
      description: Paginated list of DepositAddress resources.
    DepositAddress:
      type: object
      properties:
        id:
          allOf:
            - $ref: '#/components/schemas/typeId'
          description: Deposit Address ID (`da_` prefix).
        object:
          type: string
          enum:
            - depositAddress
          description: Resource type discriminator. Always "depositAddress".
        customerId:
          allOf:
            - $ref: '#/components/schemas/typeId'
          description: >-
            Public customer id (cst_...). Named customerId to match VA's naming
            convention.
        customer:
          allOf:
            - $ref: '#/components/schemas/CustomerSummary'
          description: |-
            Resolved id + display name of the owning customer, so list/detail
            rendering needs no follow-up customer fetch (v0.12, #2665).
        status:
          allOf:
            - $ref: '#/components/schemas/DepositAddressStatus'
          description: Current lifecycle status of the deposit address.
        statusReason:
          type: string
          description: Human-readable explanation of the current status.
        expectedSourceAsset:
          type: string
          description: Asset of the inbound crypto the DA expects.
        expectedSourceNetwork:
          allOf:
            - $ref: '#/components/schemas/CryptoNetwork'
          description: Network of the inbound crypto the DA expects.
        depositInstructions:
          allOf:
            - $ref: '#/components/schemas/DepositAddressDepositInstructions'
          description: >-
            Null in the 201 until DEPOSIT_ACCOUNT.OPEN populates the
            Erebor-owned inlet

            address.
        destination:
          allOf:
            - $ref: '#/components/schemas/TransactionDestination'
          description: >-
            V0.10: unified destination shape (payoutOrigin now lives inside
            TransactionDestination).
        returnDestination:
          allOf:
            - $ref: '#/components/schemas/CryptoReturnDestination'
          description: Registered crypto return destination (v0.11-8), echoed when set.
        failureReason:
          allOf:
            - $ref: '#/components/schemas/DepositAddressFailureReason'
          description: >-
            Set when status = `failed`; closed enum identifying the failure
            category.
        sourceToDestination:
          allOf:
            - $ref: '#/components/schemas/SourceToDestination'
          description: |-
            Derived from the destination type: `cryptoToFiatAccount` for a bank
            destination, or `cryptoToCrypto` for a crypto-wallet destination.
        sponsorGas:
          type: boolean
          description: >-
            Whether OMS absorbs the on-chain gas cost for the destination
            delivery.

            Persisted from the create/update request (currently only `true` is

            accepted).
        label:
          type: string
          description: Partner display label.
        metadata:
          type: object
          additionalProperties:
            type: string
          description: Free-form key-value pairs supplied at creation or update.
        createdAt:
          type: string
          format: date-time
          description: When the deposit address was created.
        updatedAt:
          type: string
          format: date-time
          description: When the deposit address was last updated.
      description: >-
        A reusable crypto deposit configuration. Senders deposit the expected

        asset/network to the assigned on-chain address; OMS converts and
        delivers the

        funds to the configured bank destination automatically, creating a

        transaction per inbound deposit.
    typeId:
      type: string
      pattern: >-
        ^[a-z]+_([0-9a-hjkmnp-tv-z]{26}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})$
      description: >-
        Public TypeID, e.g. `txn_01h455vb4pex5vsknk084sn02q`; legacy UUID
        suffixes are accepted until non-v7 rows are retired.
      x-go-type: string
    CustomerSummary:
      type: object
      required:
        - id
        - name
      properties:
        id:
          allOf:
            - $ref: '#/components/schemas/typeId'
          description: The OMS customer id (`cst_` prefix).
        name:
          type: string
          description: Customer display name.
      description: >-
        A minimal, resolved reference to the owning OMS customer — id plus
        display

        name, for list/detail rendering without a follow-up customer fetch

        (v0.12 list enrichment, #2665). Distinct from `Party`: this is always
        the

        record's OWNING customer (Transaction.customerId /
        VirtualAccount.customerId

        / DepositAddress.customerId), not whichever side a party sits on.
    CryptoNetwork:
      type: string
      enum:
        - ethereum
        - polygon
        - base
        - solana
        - tron
      description: >-
        Wire vocabulary for a crypto `network` request field. This is
        vocabulary, not availability: which values a given destination type
        actually accepts is enforced at runtime per destination type, so a value
        legal on the wire may still be refused. Numeric EVM chain ids (for
        example "1", "137", "8453") are not accepted. Values are lowercase on
        the wire; the server additionally normalizes case and surrounding
        whitespace on input, so this schema is stricter than the server in that
        one dimension: send lowercase, untrimmed-safe values to stay strictly
        schema-valid.
    DepositAddressDepositInstructions:
      type: object
      required:
        - asset
        - network
        - address
      properties:
        asset:
          type: string
          description: Same value as expectedSourceAsset.
        network:
          allOf:
            - $ref: '#/components/schemas/CryptoNetwork'
          description: Same value as expectedSourceNetwork.
        address:
          type: string
          description: Erebor-owned on-chain inlet address for this DA.
        expiresAt:
          type: string
          format: date-time
          description: >-
            Placeholder for a future provider-imposed inlet expiry. Null for
            Erebor

            DDAs today; surfaced now so adding it later is not a breaking
            change.
      description: The on-chain address senders deposit to, with its asset and network.
    TransactionDestination:
      type: object
      oneOf:
        - $ref: '#/components/schemas/WalletCryptoDestination'
        - $ref: '#/components/schemas/WalletExternalDestination'
        - $ref: '#/components/schemas/WalletFiatDestination'
        - $ref: '#/components/schemas/BankUsDestination'
        - $ref: '#/components/schemas/BankIbanDestination'
        - $ref: '#/components/schemas/BankCanadaDestination'
        - $ref: '#/components/schemas/CardDestination'
        - $ref: '#/components/schemas/CashDestination'
      discriminator:
        propertyName: type
        mapping:
          walletCrypto:
            $ref: '#/components/schemas/WalletCryptoDestination'
          walletExternal:
            $ref: '#/components/schemas/WalletExternalDestination'
          walletFiat:
            $ref: '#/components/schemas/WalletFiatDestination'
          bankUs:
            $ref: '#/components/schemas/BankUsDestination'
          bankIban:
            $ref: '#/components/schemas/BankIbanDestination'
          bankCanada:
            $ref: '#/components/schemas/BankCanadaDestination'
          card:
            $ref: '#/components/schemas/CardDestination'
          cash:
            $ref: '#/components/schemas/CashDestination'
      description: >-
        The destination side of a transaction/quote (v0.10): a typed instrument
        plus

        `payoutOrigin`. Amounts live only in `pricing`.
    CryptoReturnDestination:
      type: object
      required:
        - type
        - network
        - id
      properties:
        type:
          type: string
          enum:
            - walletCrypto
            - walletExternal
        network:
          allOf:
            - $ref: '#/components/schemas/CryptoNetwork'
          description: >-
            Return network. Must equal the DA's expectedSourceNetwork for the
            return to be usable.
        id:
          type: string
          description: >-
            walletCrypto: OMS wallet id (acc_…). walletExternal: registered
            ExternalAccount id (ext_…).
      description: >-
        Registered crypto return destination for a Deposit Address (v0.11-8):
        where an

        operations-triggered return of a stranded inbound deposit is sent.
        `network` must be one of

        ethereum | base | solana; a custodial (non-multi-asset) walletCrypto
        target is rejected with

        422 returnDestinationMustBeMultiAsset. `network` is a closed
        `CryptoNetwork` enum even

        though this model also appears on response paths
        (`DepositAddress.returnDestination`,

        `RedrivableTransaction.returnDestination`); that is safe only because
        the sole writer is

        gated by `eanetworks.AllServedNetworks()`, a subset of `CryptoNetwork`,
        and that containment

        is enforced by `TestCryptoNetwork_SupersetOfServedNetworks`

        (services/externalaccount/networks/networks_test.go).
    DepositAddressFailureReason:
      type: string
      enum:
        - provisioningTimeout
        - systemError
        - ereborRejected
        - intlBankAccountCreateRejected
        - noMatchingNetwork
        - blockchainAddressInUse
        - bankAccountInUse
      description: >-
        Closed enum carried on DA when status = "failed". camelCase per partner
        channel naming convention.
    SourceToDestination:
      type: string
      enum:
        - cryptoToCrypto
        - cryptoToCash
        - cryptoToFiatAccount
        - cashToCrypto
        - fiatAccountToCrypto
        - fiatAccountToFiatAccount
      description: >-
        Composite of source and destination instrument categories, inferred

        from each side. The cash corridors

        (`cryptoToCash`, `cashToCrypto`) are derived from a cash-pickup
        destination /

        cash-in source respectively; the rest map straight from the internal
        corridor type.
    WalletCryptoDestination:
      type: object
      required:
        - type
        - category
        - id
        - asset
        - network
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - walletCrypto
          description: Type discriminator.
        category:
          type: string
          enum:
            - crypto
          description: >-
            High-level grouping: `fiatAccount` for bank or card accounts,
            `crypto` for wallets.
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
          description: >-
            OMS wallet ID (`wlt_` prefix).


            DEVIATION from the ratified OMS v0.12 contract
            (docs/specs/2026-08-05-oms-v0.12-openapi.yaml,

            WalletCryptoInstrument): the ratified shape has `id` required and
            non-nullable. A row

            can classify as this arm (destination_type=walletCrypto/legacy
            walletOms, per #2528)

            before the wallet FK has actually resolved — the "in-flight deposit"
            window

            destInstrumentKind's own doc comment describes — so `id` is nullable
            rather than

            emitting an empty string that fails the `typeId` scalar's pattern.
            Not recorded in

            the upstream snapshot's §4 errata (that section is for defects IN
            the ratified

            snapshot, not BPN's own accepted deviations from it) — flagged here
            and in the PR

            description instead, same class as the
            CardInstrument.id/WalletFiatInstrument.id/

            BankUsInstrument.network deviations elsewhere in this same change.
        asset:
          type: string
          description: Canonical asset identifier.
        network:
          type: string
          description: Network identifier.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      title: OMS wallet
    WalletExternalDestination:
      type: object
      required:
        - type
        - category
        - id
        - asset
        - network
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - walletExternal
          description: Type discriminator.
        category:
          type: string
          enum:
            - crypto
          description: >-
            High-level grouping: `fiatAccount` for bank or card accounts,
            `crypto` for wallets.
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
          description: External Account ID (`ext_` prefix). Null when externalUnregistered.
        asset:
          type: string
          description: Canonical asset identifier.
        network:
          type: string
          description: Network identifier.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        details:
          type: object
          properties:
            blockchainAddress:
              type: string
              description: On-chain sender address.
          required:
            - blockchainAddress
          nullable: true
          description: >-
            Populated only when `id` is null (unregistered external sender);
            null for registered instruments.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      title: External wallet
    WalletFiatDestination:
      type: object
      required:
        - type
        - category
        - id
        - asset
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - walletFiat
          description: Type discriminator.
        category:
          type: string
          enum:
            - fiatAccount
          description: >-
            High-level grouping: `fiatAccount` for bank or card accounts,
            `crypto` for wallets.
        id:
          type: string
          nullable: true
          description: >-
            OMS fiat wallet ID (`wlt_fiat_` prefix). Look up via `GET /wallets`.

            Plain string, not the `typeId` scalar: `wlt_fiat_` is a two-token

            prefix, which the single-underscore `typeId` pattern cannot
            validate.

            Null on a #2504 book-transfer destination leg's pre-outbound window:

            the wallet FK isn't committed until the outbound leg stamps its

            routing snapshot (a repoint can still change which wallet is
            credited

            until then), so there is genuinely no id to dereference yet — a

            deliberate BPN deviation from the ratified OMS v0.12 contract, which

            types this field required and non-nullable.
        asset:
          type: string
          enum:
            - usd
          description: Fiat currency of the balance. Only `usd` today.
        network:
          type: string
          enum:
            - bookTransfer
          description: |-
            `bookTransfer` when this walletFiat is the destination of a Virtual
            Account / Deposit Address book-transfer credit — an internal ledger
            movement at the partner bank, no external rail. Absent when the
            walletFiat is a funding source.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      description: >-
        Fiat balance wallet destination — the wallet-as-destination projection
        used to

        render an inbound fiat-wallet deposit (design §4.2/§16, #2363).
        RENDERING

        OUTPUT ONLY: this arm exists so a settled deposit into a customer's USD
        fiat

        wallet renders `destination.walletFiat`. It does NOT re-open walletFiat
        as a

        user-SPECIFIABLE input destination — that input deferral (crediting
        VA/DA

        deposits into a wallet, design §16) still holds; only the output shape
        is

        restored here. Over-cut from Task 1 (#2340); returned for Task 10.
      title: Fiat wallet
    BankUsDestination:
      type: object
      required:
        - type
        - category
        - id
        - asset
        - network
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - bankUs
          description: Type discriminator.
        category:
          type: string
          enum:
            - fiatAccount
          description: >-
            High-level grouping: `fiatAccount` for bank or card accounts,
            `crypto` for wallets.
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
          description: >-
            External Account ID (`ext_` prefix). Null when externalUnregistered
            (e.g. an incoming wire from an unregistered sender).
        asset:
          type: string
          enum:
            - usd
          description: Canonical asset identifier.
        network:
          type: string
          enum:
            - ach
            - achSameDay
            - wire
          nullable: true
          description: >-
            Network identifier.


            DEVIATION from the ratified OMS v0.12 contract
            (docs/specs/2026-08-05-oms-v0.12-openapi.yaml,

            BankUsInstrument): the ratified shape has `network` required and
            non-nullable

            (no `null` option, unlike `id` on this same schema). Real
            legacy/#2528-era

            contamination means a bankUs row can carry a stored rail (`swift`,

            `international_wire`, `rtp`) that is not one of this enum's three
            members —

            rendering that as the Go zero value (`""`) reverses what #2528/#2666
            were

            built to fix: a real generated client (this repo's own npm/zod
            package

            included) fails `z.enum([...]).parse()` on an empty string just as
            hard as

            on the raw invalid token, rejecting the whole response instead of
            one

            field. Making the field nullable lets a degraded row render
            `network: null`

            — schema-valid for a nullable field, same posture as the
            dropped/absent

            field a pre-#2660 client would have seen. Not recorded in the
            upstream

            snapshot's §4 errata (that section is for defects IN the ratified
            snapshot,

            not BPN's own accepted deviations from it) — flagged here and in the
            PR

            description instead.
        secCode:
          allOf:
            - $ref: '#/components/schemas/SecCode'
          description: >-
            ACH SEC code (populated only on ach/achSameDay). Server-derived from
            the

            destination owner's and the source customer's entityType, read
            directly

            from the DB/Customer record — not from this wire-facing instrument.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        details:
          type: object
          properties:
            accountNumberLast4:
              type: string
              description: Last four digits of the account number.
            bankName:
              type: string
              nullable: true
              description: Bank display name.
          required:
            - accountNumberLast4
            - bankName
          nullable: true
          description: >-
            Populated only when `id` is null (unregistered external sender);
            null for registered instruments.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      title: US bank account
    BankIbanDestination:
      type: object
      required:
        - type
        - category
        - id
        - asset
        - network
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - bankIban
          description: Type discriminator.
        category:
          type: string
          enum:
            - fiatAccount
          description: >-
            High-level grouping: `fiatAccount` for bank or card accounts,
            `crypto` for wallets.
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
          description: External Account ID (`ext_` prefix). Null when externalUnregistered.
        asset:
          type: string
          description: Canonical asset identifier.
        network:
          type: string
          enum:
            - swift
          description: Network identifier.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        details:
          type: object
          properties:
            accountNumberLast4:
              type: string
              description: Last four characters of the IBAN.
            bankName:
              type: string
              nullable: true
              description: Bank display name.
          required:
            - accountNumberLast4
            - bankName
          nullable: true
          description: >-
            Populated only when `id` is null (unregistered external sender);
            null for registered instruments.

            `accountNumberLast4` carries the last 4 of the IBAN — no separate
            `ibanLast4` key on this slim shape.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      title: IBAN bank account
    BankCanadaDestination:
      type: object
      required:
        - type
        - category
        - id
        - asset
        - network
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - bankCanada
          description: Type discriminator.
        category:
          type: string
          enum:
            - fiatAccount
          description: >-
            High-level grouping: `fiatAccount` for bank or card accounts,
            `crypto` for wallets.
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
          description: External Account ID (`ext_` prefix). Null when externalUnregistered.
        asset:
          type: string
          enum:
            - usd
            - cad
          description: Canonical asset identifier.
        network:
          type: string
          enum:
            - swift
            - local
          description: USD uses `swift`; CAD uses `local`.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        details:
          type: object
          properties:
            accountNumberLast4:
              type: string
              description: Last four digits of the account number.
            bankName:
              type: string
              nullable: true
              description: Bank display name.
          required:
            - accountNumberLast4
            - bankName
          nullable: true
          description: >-
            Populated only when `id` is null (unregistered external sender);
            null for registered instruments.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      title: Canadian bank account
    CardDestination:
      type: object
      required:
        - type
        - category
        - id
        - asset
        - network
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - card
          description: Type discriminator.
        category:
          type: string
          enum:
            - fiatAccount
          description: >-
            High-level grouping: `fiatAccount` for bank or card accounts,
            `crypto` for wallets.
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
          description: >-
            Card External Account ID (`ext_` prefix). Null for a
            pre-#1917-migration

            card-sell row, whose external account id column was added nullable

            without a backfill.


            DEVIATION from the ratified OMS v0.12 contract
            (docs/specs/2026-08-05-oms-v0.12-openapi.yaml,

            CardInstrument): the ratified shape has `id` required and
            non-nullable,

            documented as "Always registered". BPN's own historical data
            contradicts

            that — the pre-#1917 legacy rows genuinely have no id — so this
            field is

            deliberately nullable rather than emitting an empty string that
            fails the

            `typeId` scalar's pattern. Not recorded in the upstream snapshot's
            §4

            errata (that section is for defects IN the ratified snapshot, not
            BPN's

            own accepted deviations from it) — flagged here and in the PR
            description

            instead. Follow-up: either backfill the pre-#1917 quote rows so `id`
            is

            always resolvable, or get this nullability formally signed off with
            OMS

            product as a permanent BPN deviation.
        asset:
          type: string
          enum:
            - usd
          description: Canonical asset identifier.
        network:
          type: string
          enum:
            - card
          description: Network identifier.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      title: Card
    CashDestination:
      type: object
      required:
        - type
        - category
        - asset
        - displayName
      properties:
        party:
          allOf:
            - $ref: '#/components/schemas/Party'
          description: Structured identity of who is on this side.
        memo:
          type: string
          description: Free-text message travelling with the transfer on this side's rail.
        type:
          type: string
          enum:
            - cash
          description: Type discriminator.
        category:
          type: string
          enum:
            - cash
          description: 'High-level grouping: always `cash` for cash pickups and drops.'
        asset:
          type: string
          description: Canonical asset identifier.
        cashLocationId:
          type: string
          description: Cash location ID from `GET /cash-locations`.
        displayName:
          type: string
          description: >-
            Opaque, render-only summary for list/detail display. Never a full
            account number/IBAN/PAN.
        payoutOrigin:
          $ref: '#/components/schemas/PayoutOrigin'
        pickupCode:
          type: string
          description: >-
            Retail pickup code for a cash payout. Populated only on cash-out
            (pickup) destinations.
        companyDiscretionaryData:
          type: string
          description: >-
            Echo of the ACH companyDiscretionaryData supplied on the originating
            request.

            Null/absent on non-ACH destinations or when not supplied.
      title: Cash
    Party:
      type: object
      required:
        - relationship
        - id
        - name
      properties:
        relationship:
          type: string
          enum:
            - customer
            - otherCustomer
            - externalRegistered
            - externalUnregistered
          description: Which kind of party this is.
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
          description: >-
            `cst_` for customer/otherCustomer; `ctp_` for externalRegistered;
            null for externalUnregistered.
        name:
          type: string
          nullable: true
          description: >-
            Display name. Null only when genuinely unknown (an unattributed
            external sender).
      description: >-
        Response-only identity of who is on one side of a transaction — a
        uniform

        `{relationship, id, name}` reference. `id` is the Customer (`cst_`) for

        `customer`/`otherCustomer`, the Counterparty (`ctp_`) for

        `externalRegistered`, and null for `externalUnregistered`. Entity type
        and

        address live on the dereferenced Customer/Counterparty resource, not
        here.

        `name` is populated for every relationship except a genuinely-unknown

        external sender.
    PayoutOrigin:
      type: object
      required:
        - type
        - id
      properties:
        type:
          type: string
          enum:
            - bank
            - blockchain
        id:
          type: string
          allOf:
            - $ref: '#/components/schemas/typeId'
          nullable: true
      description: |-
        Where last-mile delivery is sent *from*, as a uniform `{type, id}`
        reference — response-only. `id` is the Virtual Account (`va_`) or OMS
        wallet (`wlt_`) funding the leg; null before execution (Quote / Deposit
        Address echo the choice only) or when the origin has no partner-visible
        resource. Rail identifiers for the last-mile transfer live in the
        top-level `tracking` array with `leg: destination` — not here.
    SecCode:
      type: string
      enum:
        - ccd
        - ppd
        - web
      description: >-
        ACH SEC code. Populated only when the destination bank network is

        `ach`/`achSameDay`; null otherwise. Server-derived from the destination
        owner's

        and the source customer's `entityType`.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Token from POST /auth/token

````