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

# Create an order

> Places an order for one product, using the API key's business, pricing tier and mode. Live and Test have separate per-holder create limits. New Test requests return 409 test_mode_unavailable while sandbox admission is closed. The supplier's live cost and availability are checked before funds are held. A new USD-wallet order may finish during the synchronous wait and return 201. An NGN-wallet order uses an API key-attributed conversion and always returns 202, as does a permanent order replay after the HTTP response expires. Location identifies the public order in either case. The same key and request replay the first HTTP response for 24 hours. A changed request receives 422. Retry transient or unstored order refusals using the same key after their cause clears. Cancellation while awaiting FX approval releases the NGN hold. Fulfilment captures only delivered cards, releases definitive rejections, and retains the hold for unknown results. Responses carry Cache-Control: private, no-store.



## OpenAPI

````yaml /api-reference/openapi.json post /v1/orders
openapi: 3.1.1
info:
  title: Recadd API
  description: >-
    The Recadd business API for buying gift cards. Authenticate with an API key;
    test keys start with rk_test_. Visitor IP and authenticated key request
    allowances are divided across the configured replicas. Effective allowances
    vary with traffic distribution, and overlapping replicas can temporarily
    raise them during rollouts.
  contact:
    name: Recadd
    url: https://recadd.com
  version: 1.0.0
servers:
  - url: https://api.recadd.com
security: []
tags:
  - name: Webhooks
  - name: Treasury
  - name: Wallet
  - name: Catalog
  - name: Orders
paths:
  /v1/orders:
    post:
      tags:
        - Orders
      summary: Create an order
      description: >-
        Places an order for one product, using the API key's business, pricing
        tier and mode. Live and Test have separate per-holder create limits. New
        Test requests return 409 test_mode_unavailable while sandbox admission
        is closed. The supplier's live cost and availability are checked before
        funds are held. A new USD-wallet order may finish during the synchronous
        wait and return 201. An NGN-wallet order uses an API key-attributed
        conversion and always returns 202, as does a permanent order replay
        after the HTTP response expires. Location identifies the public order in
        either case. The same key and request replay the first HTTP response for
        24 hours. A changed request receives 422. Retry transient or unstored
        order refusals using the same key after their cause clears. Cancellation
        while awaiting FX approval releases the NGN hold. Fulfilment captures
        only delivered cards, releases definitive rejections, and retains the
        hold for unknown results. Responses carry Cache-Control: private,
        no-store.
      operationId: PublicCreateOrder
      parameters:
        - name: Idempotency-Key
          in: header
          description: >-
            A client-chosen key, 1 to 255 printable ASCII characters with no
            spaces, that makes a retry of this request return the first response
            instead of running it again.
          required: true
          schema:
            maxLength: 255
            minLength: 1
            pattern: ^[\x21-\x7E]+$
            type: string
          example: partner-request-1
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateOrderRequest'
            examples:
              live:
                value:
                  pay_from: usd_wallet
                  product_id: prd_01ka5krkayfxg8m6sc7n75ytky
                  quantity: 1
                  client_reference: po-1001
              sandbox_ngn:
                value:
                  pay_from: ngn_wallet
                  product_id: prd_01ka5krkayfxg8m6sc7n75ytky
                  quantity: 1
                  client_reference: sandbox-1
              sandbox_timeout:
                value:
                  pay_from: usd_wallet
                  product_id: prd_01ka5krkayfxg8m6sc7n75ytky
                  quantity: 1
                  client_reference: sandbox-2
                  sandbox_amount_minor: 1002
        required: true
      responses:
        '201':
          description: >-
            A new USD-wallet order in a final state. Location is the public
            order detail. New Test orders return 409 while sandbox admission is
            closed.
          headers:
            Idempotent-Replayed:
              description: >-
                Present when this response is a replay of the first response to
                the same Idempotency-Key and request.
              schema:
                enum:
                  - 'true'
                type: string
            Location:
              description: The relative public order detail path.
              schema:
                type: string
              example: /v1/orders/ord_01ka5krkayfxg8m6sc7n75ytkv
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderResponse'
              example:
                id: ord_01ka5krkayfxg8m6sc7n75ytkv
                status: completed
                failure_reason: null
                channel: api
                pay_from: usd_wallet
                total:
                  amount_minor: 1030
                  currency: USD
                  display: $10.30
                quantity: 1
                display_name: PlayStation 10 USD US
                client_reference: po-1001
                created_at: '2026-11-17T10:00:00+00:00'
                settled_at: '2026-11-17T10:00:02+00:00'
                product_id: prd_01ka5krkayfxg8m6sc7n75ytky
                brand: playstation
                country: US
                face_value: '10.00'
                face_unit: USD
                unit_price:
                  amount_minor: 1030
                  currency: USD
                  display: $10.30
                pricing_tier: default
                supplier: likecard
                supplier_mode: live
                cards:
                  delivered: 1
                  rejected: 0
                  pending: 0
                  unknown: 0
                  refunded: 0
                captured:
                  amount_minor: 1030
                  currency: USD
                  display: $10.30
                conversion: null
                refunded:
                  amount_minor: 0
                  currency: USD
                  display: $0.00
        '202':
          description: >-
            The accepted order or a permanent-row replay. Location is the public
            order detail. New Test orders return 409 while sandbox admission is
            closed.
          headers:
            Idempotent-Replayed:
              description: >-
                Present when this response is a replay of the first response to
                the same Idempotency-Key and request.
              schema:
                enum:
                  - 'true'
                type: string
            Location:
              description: The relative public order detail path.
              schema:
                type: string
              example: /v1/orders/ord_01ka5krkayfxg8m6sc7n75ytkv
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderResponse'
              examples:
                live:
                  value:
                    id: ord_01ka5krkayfxg8m6sc7n75ytkv
                    status: fulfilling
                    failure_reason: null
                    channel: api
                    pay_from: usd_wallet
                    total:
                      amount_minor: 1030
                      currency: USD
                      display: $10.30
                    quantity: 1
                    display_name: PlayStation 10 USD US
                    client_reference: po-1001
                    created_at: '2026-11-17T10:00:00+00:00'
                    settled_at: null
                    product_id: prd_01ka5krkayfxg8m6sc7n75ytky
                    brand: playstation
                    country: US
                    face_value: '10.00'
                    face_unit: USD
                    unit_price:
                      amount_minor: 1030
                      currency: USD
                      display: $10.30
                    pricing_tier: default
                    supplier: likecard
                    supplier_mode: live
                    cards:
                      delivered: 0
                      rejected: 0
                      pending: 1
                      unknown: 0
                      refunded: 0
                    captured: null
                    conversion: null
                    refunded:
                      amount_minor: 0
                      currency: USD
                      display: $0.00
                sandbox_awaiting_approval:
                  value:
                    id: ord_01ka5krkayfxg8m6sc7n75ytkv
                    status: awaiting_fx_approval
                    failure_reason: null
                    channel: api
                    pay_from: ngn_wallet
                    total:
                      amount_minor: 1030
                      currency: USD
                      display: $10.30
                    quantity: 1
                    display_name: PlayStation 10 USD US
                    client_reference: po-1001
                    created_at: '2026-11-17T10:00:00+00:00'
                    settled_at: null
                    product_id: prd_01ka5krkayfxg8m6sc7n75ytky
                    brand: playstation
                    country: US
                    face_value: '10.00'
                    face_unit: USD
                    unit_price:
                      amount_minor: 1030
                      currency: USD
                      display: $10.30
                    pricing_tier: default
                    supplier: fake
                    supplier_mode: sandbox
                    cards:
                      delivered: 0
                      rejected: 0
                      pending: 1
                      unknown: 0
                      refunded: 0
                    captured: null
                    conversion:
                      id: fxc_01ka5krkayfxg8m6sc7n75ytkz
                      ngn:
                        amount_minor: 1545000
                        currency: NGN
                        display: ₦15,450.00
                      sell_rate: '1500.000000000000'
                      approval_mode: sandbox
                    refunded:
                      amount_minor: 0
                      currency: USD
                      display: $0.00
        '400':
          description: >-
            idempotency_key_required, idempotency_key_invalid,
            malformed_request, validation_failed. Validation failures carry
            field errors. An input value that cannot bind carries a plain
            problem.
          headers:
            Idempotent-Replayed:
              description: >-
                Present when this response is a replay of the first response to
                the same Idempotency-Key and request.
              schema:
                enum:
                  - 'true'
                type: string
          content:
            application/problem+json:
              schema:
                anyOf:
                  - $ref: '#/components/schemas/HttpValidationProblemDetails'
                  - $ref: '#/components/schemas/ProblemDetails'
              examples:
                idempotency_key_required:
                  value:
                    status: 400
                    code: idempotency_key_required
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                idempotency_key_invalid:
                  value:
                    status: 400
                    code: idempotency_key_invalid
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                malformed_request:
                  value:
                    status: 400
                    code: malformed_request
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                validation_failed:
                  value:
                    status: 400
                    code: validation_failed
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    errors:
                      quantity:
                        - A whole number from 1 to 100.
        '401':
          description: >-
            invalid_api_key: The Authorization header is missing or malformed,
            or names an API key that is unknown, revoked, expired or of the
            other mode. One answer for every case.
          headers:
            WWW-Authenticate:
              description: The authentication challenge for a missing or invalid API key.
              schema:
                type: string
              example: Bearer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                invalid_api_key:
                  value:
                    status: 401
                    code: invalid_api_key
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
        '403':
          description: >-
            api_key_spend_cap_exceeded, account_frozen, velocity_limit_exceeded.
            ip_not_allowed: The request's address is outside the API key's IP
            allowlist. tier_limit_exceeded: The business's effective live API
            key permission denies the request. The default threshold is B1
            verification, and an override can change the permission. The limit
            is live_api_keys_allowed. The required_tier names the first higher
            tier whose default permits live API keys, or is null if none does.
            Holder overrides still apply. insufficient_scope: The API key lacks
            the scope the endpoint requires, named in required_scope. Checked in
            that order; the first that applies is returned. After
            authentication, order verification can also return
            tier_limit_exceeded. The limit is usd_purchase_allowed when
            USD-priced orders are disabled, max_single_order when this order
            exceeds the per-order cap, or max_daily_spend when this order would
            take the business over its cap for the Lagos calendar day. The
            limit_amount is the cap in USD for spend limits and null for
            permission limits. The current_tier is the business's effective
            tier, and required_tier is the first higher tier that satisfies that
            limit, or null if none does.
          headers:
            Idempotent-Replayed:
              description: >-
                Present when this response is a replay of the first response to
                the same Idempotency-Key and request.
              schema:
                enum:
                  - 'true'
                type: string
            Retry-After:
              description: >-
                Only for rapid_orders. Seconds until the oldest order counted
                leaves the rapid window.
              schema:
                minimum: 1
                type: integer
              example: 60
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                ip_not_allowed:
                  value:
                    status: 403
                    code: ip_not_allowed
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                tier_limit_exceeded:
                  value:
                    status: 403
                    code: tier_limit_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: live_api_keys_allowed
                    limit_amount: null
                    current_tier: b0
                    required_tier: b1
                insufficient_scope:
                  value:
                    status: 403
                    code: insufficient_scope
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    required_scope: orders:write
                api_key_spend_cap_exceeded:
                  value:
                    status: 403
                    code: api_key_spend_cap_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: spend_cap_per_order
                    limit_amount:
                      amount_minor: 10000
                      currency: USD
                      display: $100.00
                account_frozen:
                  value:
                    status: 403
                    code: account_frozen
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                velocity_limit_exceeded:
                  value:
                    status: 403
                    code: velocity_limit_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: rapid_orders
                tier_limit_exceeded_usd_purchase_allowed:
                  value:
                    status: 403
                    code: tier_limit_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: usd_purchase_allowed
                    limit_amount: null
                    current_tier: b2
                    required_tier: null
                tier_limit_exceeded_max_single_order:
                  value:
                    status: 403
                    code: tier_limit_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: max_single_order
                    limit_amount:
                      amount_minor: 10000
                      currency: USD
                      display: $100.00
                    current_tier: b1
                    required_tier: b2
                tier_limit_exceeded_max_daily_spend:
                  value:
                    status: 403
                    code: tier_limit_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: max_daily_spend
                    limit_amount:
                      amount_minor: 50000
                      currency: USD
                      display: $500.00
                    current_tier: b2
                    required_tier: null
                api_key_spend_cap_exceeded_spend_cap_daily:
                  value:
                    status: 403
                    code: api_key_spend_cap_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: spend_cap_daily
                    limit_amount:
                      amount_minor: 50000
                      currency: USD
                      display: $500.00
                velocity_limit_exceeded_new_account_single:
                  value:
                    status: 403
                    code: velocity_limit_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: new_account_single
                    limit_amount:
                      amount_minor: 30000
                      currency: USD
                      display: $300.00
                velocity_limit_exceeded_new_account_daily:
                  value:
                    status: 403
                    code: velocity_limit_exceeded
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    limit: new_account_daily
                    limit_amount:
                      amount_minor: 60000
                      currency: USD
                      display: $600.00
        '409':
          description: >-
            idempotency_key_in_progress, test_mode_unavailable,
            product_unavailable, price_changed, insufficient_funds,
            duplicate_client_reference
          headers:
            Idempotent-Replayed:
              description: >-
                Present when this response is a replay of the first response to
                the same Idempotency-Key and request.
              schema:
                enum:
                  - 'true'
                type: string
            Retry-After:
              description: >-
                Seconds to wait before retrying, when the code is
                idempotency_key_in_progress.
              schema:
                minimum: 0
                type: integer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                idempotency_key_in_progress:
                  value:
                    status: 409
                    code: idempotency_key_in_progress
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                test_mode_unavailable:
                  value:
                    status: 409
                    code: test_mode_unavailable
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                product_unavailable:
                  value:
                    status: 409
                    code: product_unavailable
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                price_changed:
                  value:
                    status: 409
                    code: price_changed
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                insufficient_funds:
                  value:
                    status: 409
                    code: insufficient_funds
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                duplicate_client_reference:
                  value:
                    status: 409
                    code: duplicate_client_reference
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                    order_id: ord_01K8NKRKA9E008000000000000
        '413':
          description: >-
            payload_too_large. The request body exceeds the 24576-byte limit.
            The Idempotency-Key is not claimed.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                payload_too_large:
                  value:
                    status: 413
                    code: payload_too_large
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
        '415':
          description: unsupported_media_type
          headers:
            Idempotent-Replayed:
              description: >-
                Present when this response is a replay of the first response to
                the same Idempotency-Key and request.
              schema:
                enum:
                  - 'true'
                type: string
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                unsupported_media_type:
                  value:
                    status: 415
                    code: unsupported_media_type
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
        '422':
          description: idempotency_key_reused
          headers:
            Idempotent-Replayed:
              description: >-
                Present when this response is a replay of the first response to
                the same Idempotency-Key and request.
              schema:
                enum:
                  - 'true'
                type: string
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                idempotency_key_reused:
                  value:
                    status: 422
                    code: idempotency_key_reused
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
        '429':
          description: >-
            rate_limited: The visitor IP or authenticated API key exceeded its
            request allowance, an endpoint limit was reached, or key guessing
            was throttled. Retry after the whole seconds in Retry-After.
          headers:
            Retry-After:
              description: Seconds to wait before retrying.
              schema:
                minimum: 1
                type: integer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                rate_limited:
                  value:
                    status: 429
                    code: rate_limited
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
        '500':
          description: >-
            internal_error. An unexpected failure prevented the request from
            completing.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                internal_error:
                  value:
                    status: 500
                    code: internal_error
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
        '503':
          description: >-
            database_busy, server_busy. supplier_unavailable: retry in 30
            seconds. fx_unavailable: retry in 60 seconds. treasury_busy: retry
            in 5 seconds. treasury_backing_breached: retry in 60 seconds.
            insufficient_float: retry in 60 seconds. insufficient_sellable_usd:
            retry in 60 seconds. key_requesters_unavailable: new NGN-wallet
            requests are disabled during rollout; retry in 5 seconds. If the
            replica is at its public request concurrency limit, retry after 1
            second. database_busy: every database connection this replica may
            open is in use; retry after Retry-After
          headers:
            Retry-After:
              description: >-
                Seconds to wait before retrying, when the code is
                supplier_unavailable, fx_unavailable, treasury_busy,
                treasury_backing_breached, insufficient_float,
                insufficient_sellable_usd, key_requesters_unavailable,
                server_busy or database_busy.
              schema:
                minimum: 0
                type: integer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                supplier_unavailable:
                  value:
                    status: 503
                    code: supplier_unavailable
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                fx_unavailable:
                  value:
                    status: 503
                    code: fx_unavailable
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                treasury_busy:
                  value:
                    status: 503
                    code: treasury_busy
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                treasury_backing_breached:
                  value:
                    status: 503
                    code: treasury_backing_breached
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                insufficient_float:
                  value:
                    status: 503
                    code: insufficient_float
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                insufficient_sellable_usd:
                  value:
                    status: 503
                    code: insufficient_sellable_usd
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                key_requesters_unavailable:
                  value:
                    status: 503
                    code: key_requesters_unavailable
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                database_busy:
                  value:
                    status: 503
                    code: database_busy
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
                server_busy:
                  value:
                    status: 503
                    code: server_busy
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
        '504':
          description: request_timeout
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
              examples:
                request_timeout:
                  value:
                    status: 504
                    code: request_timeout
                    trace_id: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
      security:
        - ApiKey: []
components:
  schemas:
    CreateOrderRequest:
      required:
        - pay_from
        - product_id
        - quantity
      type: object
      properties:
        pay_from:
          enum:
            - usd_wallet
            - ngn_wallet
          type: string
          description: >-
            The wallet that pays, one of usd_wallet (the USD price from the USD
            wallet) or ngn_wallet (from the NGN wallet, through a conversion an
            admin approves). Any other value is 400 validation_failed.
        product_id:
          type: string
          description: The product to buy, prefixed prd_.
        quantity:
          type: integer
          description: The number of cards, 1 to Orders:MaxQuantity (100 by default).
          format: int32
        client_reference:
          maxLength: 64
          minLength: 1
          pattern: ^[A-Za-z0-9_.:-]{1,64}$
          type:
            - 'null'
            - string
          description: >-
            The business's own reference for the order: 1 to 64 letters, digits,
            _, ., : or -, unique within the business and mode. Set it to retry
            safely with a new Idempotency-Key.
        sandbox_amount_minor:
          type: integer
          description: >-
            Optional Test scenario in minor units. Omit for success. 1001
            rejects all cards, 1002 times out then delivers on lookup, and 1003
            delivers unit zero only for a quantity of at least two.
          format: int32
      additionalProperties: false
    OrderResponse:
      required:
        - id
        - status
        - failure_reason
        - channel
        - pay_from
        - total
        - quantity
        - display_name
        - client_reference
        - created_at
        - settled_at
        - product_id
        - brand
        - country
        - face_value
        - face_unit
        - unit_price
        - pricing_tier
        - supplier
        - supplier_mode
        - cards
        - captured
        - conversion
        - refunded
      type: object
      properties:
        id:
          type: string
          description: The order's id, prefixed ord_.
        status:
          $ref: '#/components/schemas/OrderStatus'
          description: >-
            Where the order is; completed, partially_completed, failed and
            cancelled are final.
        failure_reason:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/OrderFailureReason'
              description: Why the order failed or was cancelled; null otherwise.
        channel:
          $ref: '#/components/schemas/OrderChannel'
          description: Where the order came from.
        pay_from:
          $ref: '#/components/schemas/PayFrom'
          description: The wallet that pays for the order.
        total:
          $ref: '#/components/schemas/MoneyResponse'
          description: >-
            The order's total in USD: the unit price times the quantity, held
            when the order was accepted.
        quantity:
          type: integer
          description: The number of cards ordered.
          format: int32
        display_name:
          type: string
          description: The product's name when the order was created.
        client_reference:
          type:
            - 'null'
            - string
          description: >-
            The business's own reference for the order, unique within the
            business and mode. Null when none was given.
        created_at:
          type: string
          description: When the order was created.
          format: date-time
        settled_at:
          type:
            - 'null'
            - string
          description: When the order reached a final status; null until then.
          format: date-time
        product_id:
          type: string
          description: >-
            The product bought, prefixed prd_. The order keeps its own copy of
            what was bought, so a later change to the product does not change
            it.
        brand:
          type: string
          description: The brand's key, such as playstation, when the order was created.
        country:
          type: string
          description: >-
            The country the card is for: an ISO 3166-1 alpha-2 code, EU or
            GLOBAL.
        face_value:
          type: string
          description: The card's face value, as a decimal string with two places.
        face_unit:
          type: string
          description: The face value's currency or unit, such as USD.
        unit_price:
          $ref: '#/components/schemas/MoneyResponse'
          description: The price of one card in USD, fixed when the order was created.
        pricing_tier:
          type: string
          description: The pricing tier the order was priced at.
        supplier:
          type: string
          description: The supplier the cards are bought from.
        supplier_mode:
          $ref: '#/components/schemas/SupplierModeName'
          description: The supplier environment the cards are bought in.
        cards:
          $ref: '#/components/schemas/OrderCardCounts'
          description: The cards by where each stands.
        captured:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/MoneyResponse'
              description: >-
                The USD charged for the delivered cards; null until the order is
                settled.
        conversion:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/OrderConversionResponse'
              description: >-
                The conversion paying for an order paid from the NGN wallet;
                null for one paid from the USD wallet.
        refunded:
          $ref: '#/components/schemas/MoneyResponse'
          description: The USD returned for refunded cards; zero when none were refunded.
      additionalProperties: false
    HttpValidationProblemDetails:
      required:
        - code
        - trace_id
        - errors
      type: object
      properties:
        type:
          type:
            - 'null'
            - string
          description: >-
            A link describing the HTTP status, absent for some statuses. Switch
            on code, not on this.
        title:
          type:
            - 'null'
            - string
          description: >-
            A short summary of the problem for people to read. It may change;
            switch on code.
        status:
          type:
            - 'null'
            - integer
          description: The HTTP status code of the response.
          format: int32
        detail:
          type:
            - 'null'
            - string
          description: >-
            An explanation of this occurrence for people to read, when there is
            one. It may change; switch on code.
        instance:
          type:
            - 'null'
            - string
          description: A reference to this occurrence. This API does not set it.
        errors:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: >-
            The messages for each invalid field, keyed by the snake_case path
            the client sent.
        code:
          maxLength: 64
          pattern: ^[a-z][a-z0-9_]*$
          enum:
            - validation_failed
          type: string
          description: The stable error code to switch on; titles and details may change.
        trace_id:
          type: string
          description: >-
            The trace id of the request that produced this response (on a
            replay, the first request's), to quote to support.
        required_scope:
          type: string
          description: >-
            The API key scope required by this operation, for
            insufficient_scope.
        limit:
          type: string
          description: The name of the limit that refused the request.
        limit_amount:
          anyOf:
            - $ref: '#/components/schemas/MoneyResponse'
            - type: 'null'
          description: The amount allowed by the limit, or null for a feature gate.
        current_tier:
          type: string
          description: The holder's current verification tier, for tier_limit_exceeded.
        order_id:
          type: string
          description: >-
            The existing order's id, prefixed ord_, for
            duplicate_client_reference.
        required_tier:
          type:
            - 'null'
            - string
          description: >-
            The first higher verification tier that meets the limit, or null if
            none does. For live_api_keys_allowed, this is the first higher tier
            whose default permits live API keys. Holder overrides still apply.
    ProblemDetails:
      required:
        - code
        - trace_id
      type: object
      not:
        required:
          - errors
      properties:
        type:
          type:
            - 'null'
            - string
          description: >-
            A link describing the HTTP status, absent for some statuses. Switch
            on code, not on this.
        title:
          type:
            - 'null'
            - string
          description: >-
            A short summary of the problem for people to read. It may change;
            switch on code.
        status:
          type:
            - 'null'
            - integer
          description: The HTTP status code of the response.
          format: int32
        detail:
          type:
            - 'null'
            - string
          description: >-
            An explanation of this occurrence for people to read, when there is
            one. It may change; switch on code.
        instance:
          type:
            - 'null'
            - string
          description: A reference to this occurrence. This API does not set it.
        code:
          maxLength: 64
          pattern: ^[a-z][a-z0-9_]*$
          type: string
          not:
            enum:
              - validation_failed
          description: The stable error code to switch on; titles and details may change.
        trace_id:
          type: string
          description: >-
            The trace id of the request that produced this response (on a
            replay, the first request's), to quote to support.
        required_scope:
          type: string
          description: >-
            The API key scope required by this operation, for
            insufficient_scope.
        limit:
          type: string
          description: The name of the limit that refused the request.
        limit_amount:
          anyOf:
            - $ref: '#/components/schemas/MoneyResponse'
            - type: 'null'
          description: The amount allowed by the limit, or null for a feature gate.
        current_tier:
          type: string
          description: The holder's current verification tier, for tier_limit_exceeded.
        order_id:
          type: string
          description: >-
            The existing order's id, prefixed ord_, for
            duplicate_client_reference.
        required_tier:
          type:
            - 'null'
            - string
          description: >-
            The first higher verification tier that meets the limit, or null if
            none does. For live_api_keys_allowed, this is the first higher tier
            whose default permits live API keys. Holder overrides still apply.
    OrderStatus:
      enum:
        - pending
        - awaiting_fx_approval
        - converting
        - fulfilling
        - awaiting_supplier
        - completed
        - partially_completed
        - failed
        - cancelled
      type: string
      description: >-
        pending: accepted, nothing has started. awaiting_fx_approval: the naira
        is held and the conversion waits for an admin. converting: the
        conversion is approved and posting. fulfilling: cards are being bought,
        or the order is settling. awaiting_supplier: a card's result is unknown
        and is being looked up. completed: every card was delivered.
        partially_completed: some cards were delivered and the rest released.
        failed: no card was delivered and the hold was released. cancelled: the
        order stopped before any card was bought.
    OrderFailureReason:
      enum:
        - fx_denied
        - customer_cancelled
        - approval_expired
        - price_changed
        - all_rejected
        - hold_expired
        - supplier_unavailable
        - insufficient_float
        - treasury_backing_breached
        - account_frozen
      type: string
      description: >-
        Why an order failed or was cancelled. fx_denied: an admin denied the
        conversion. customer_cancelled: the business cancelled it.
        approval_expired: the conversion's approval expired. price_changed: the
        supplier's price rose beyond tolerance. all_rejected: the supplier
        rejected every card. hold_expired: the hold expired before fulfilment.
        supplier_unavailable: the supplier stayed unavailable too long.
        insufficient_float: Recadd's supplier float could not cover it.
        treasury_backing_breached: Recadd's USD backing could not cover it.
        account_frozen: the account was frozen.
    OrderChannel:
      enum:
        - api
        - dashboard
        - marketplace
      type: string
      description: >-
        Where the order came from. api: an API key. dashboard: a signed-in user
        on the business dashboard. marketplace: the consumer marketplace.
    PayFrom:
      enum:
        - usd_wallet
        - ngn_wallet
      type: string
      description: >-
        The wallet that pays. usd_wallet: the USD wallet at the USD price.
        ngn_wallet: the NGN wallet, through a conversion an admin approves.
    MoneyResponse:
      required:
        - amount_minor
        - currency
        - display
      type: object
      properties:
        amount_minor:
          type: integer
          description: >-
            The amount as a whole number of the currency's minor unit, such as
            kobo for NGN or cents for USD.
          format: int64
        currency:
          type: string
          description: The ISO 4217 code of the currency, such as NGN or USD.
        display:
          type: string
          description: >-
            The amount formatted for people to read, with the currency's symbol
            (or its code) and as many decimals as its minor unit has, such as
            ₦1,500.00. Not for parsing; use amount_minor.
      additionalProperties: false
    SupplierModeName:
      enum:
        - sandbox
        - live
      type: string
      description: >-
        The supplier environment the order is fulfilled against. sandbox: the
        supplier's test mode. live: real cards.
    OrderCardCounts:
      required:
        - delivered
        - rejected
        - pending
        - unknown
        - refunded
      type: object
      properties:
        delivered:
          type: integer
          description: Cards delivered; their codes are on the order's cards list.
          format: int32
        rejected:
          type: integer
          description: >-
            Cards the supplier refused or that were never bought; their price is
            released.
          format: int32
        pending:
          type: integer
          description: Cards not yet bought.
          format: int32
        unknown:
          type: integer
          description: >-
            Cards whose result is not known yet and is being looked up; their
            price stays held.
          format: int32
        refunded:
          type: integer
          description: Delivered cards refunded to the USD wallet; included in delivered.
          format: int32
      additionalProperties: false
    OrderConversionResponse:
      required:
        - id
        - ngn
        - sell_rate
        - approval_mode
      type: object
      properties:
        id:
          type: string
          description: The conversion paying for the order, prefixed fxc_.
        ngn:
          $ref: '#/components/schemas/MoneyResponse'
          description: The naira held, then charged, for the order's dollars.
        sell_rate:
          type: string
          description: >-
            Naira per dollar locked when the order was created, exact, as a
            decimal string with twelve places; never rounded.
        approval_mode:
          $ref: '#/components/schemas/ConversionApprovalMode'
          description: How the conversion is approved.
      additionalProperties: false
    ConversionApprovalMode:
      enum:
        - manual
        - automatic
        - sandbox
      type: string
      description: >-
        How a path C order's conversion is approved. manual: an admin decides.
        automatic: approved within guardrails, else an admin decides. sandbox: a
        test order, approved after a delay.
  securitySchemes:
    ApiKey:
      type: http
      description: >-
        An API key in the Authorization header, for example Authorization:
        Bearer rk_test_<key id>_<secret>. Test keys start with rk_test_; the key
        is shown once, when it is created or rotated.
      scheme: bearer
      x-recadd-problems:
        - $ref: '#/components/responses/InvalidApiKey'
        - $ref: '#/components/responses/IpNotAllowed'
        - $ref: '#/components/responses/TierLimitExceeded'
        - $ref: '#/components/responses/InsufficientScope'
        - $ref: '#/components/responses/RateLimited'

````

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