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

# Create a Cross-Border Payment

> Creates a cross-border payment from a platform user's wallet to a saved payee bank.

Send:
- `payer_id` (alias `user_id`) — the user funding the payment
- `payee_id` — the payee
- `to_bank_id` — the saved payee bank
- `amount` — the **source amount in USD**, plus `payout_currency`, `invoice_no` and an optional `description`

**Amount limits** (the source `amount` in USD, both inclusive):
- **Minimum amount: `$10 USD`**
- **Maximum amount: `$5,000 USD`**

A request below the minimum or above the maximum is rejected with `AMOUNT_OUT_OF_RANGE`, and the error
payload echoes `min_amount`, `max_amount` and `currency` (USD).

Also rejects with `COUNTRY_NOT_ALLOWED` if the payee country is not enabled for the platform, or
`MISSING_REQUIRED_FIELDS` when a required payee field is missing. Returns the created payment;
progress is delivered via `payment.*` webhooks.



## OpenAPI

````yaml POST /api/platform/cross-border/create-payment
openapi: 3.1.0
info:
  title: paywint
  version: 0.1.0
servers:
  - url: https://api.paywint.com
  - url: https://api.sandbox.paywint.com
security: []
paths:
  /api/platform/cross-border/create-payment:
    post:
      tags:
        - Platform Cross-Border
      summary: Create a Cross-Border Payment
      description: >-
        Creates a cross-border payment from a platform user's wallet to a saved
        payee bank.


        Send:

        - `payer_id` (alias `user_id`) — the user funding the payment

        - `payee_id` — the payee

        - `to_bank_id` — the saved payee bank

        - `amount` — the **source amount in USD**, plus `payout_currency`,
        `invoice_no` and an optional `description`


        **Amount limits** (the source `amount` in USD, both inclusive):

        - **Minimum amount: `$10 USD`**

        - **Maximum amount: `$5,000 USD`**


        A request below the minimum or above the maximum is rejected with
        `AMOUNT_OUT_OF_RANGE`, and the error

        payload echoes `min_amount`, `max_amount` and `currency` (USD).


        Also rejects with `COUNTRY_NOT_ALLOWED` if the payee country is not
        enabled for the platform, or

        `MISSING_REQUIRED_FIELDS` when a required payee field is missing.
        Returns the created payment;

        progress is delivered via `payment.*` webhooks.
      operationId: create_payment_api_platform_cross_border_create_payment_post
      parameters:
        - name: X-Platform-ID
          in: header
          required: true
          schema:
            type: string
            format: uuid
            description: >-
              Unique platform identifier (UUID). You receive this during
              onboarding. Must be sent with every API request.
            title: X-Platform-Id
          description: >-
            Unique platform identifier (UUID). You receive this during
            onboarding. Must be sent with every API request.
        - name: X-Signature
          in: header
          required: true
          schema:
            type: string
            description: >-
              HMAC-SHA256 request signature for authentication. Use your
              platform secret key to compute it as: `METHOD + PATH + QUERY +
              BODY_HASH`.
            title: X-Signature
          description: >-
            HMAC-SHA256 request signature for authentication. Use your platform
            secret key to compute it as: `METHOD + PATH + QUERY + BODY_HASH`.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PlatformInternationalPayoutRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/CommonResponse_PlatformPayoutCreateResult_
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    PlatformInternationalPayoutRequest:
      properties:
        user_id:
          type: string
          format: uuid
          title: User Id
          description: Unique identifier (UUID) of the user funding the payout (payer).
          example: f47ac10b-****-****-****-0e02b2c3d479
        payee_id:
          type: string
          format: uuid
          title: Payee Id
          description: Unique identifier (UUID) of the payee user.
          example: f47ac10b-****-****-****-0e02b2c3d479
        amount:
          type: number
          exclusiveMinimum: 0
          title: Amount
          description: Source amount debited from the payer's wallet.
        invoice_no:
          anyOf:
            - type: string
              maxLength: 20
            - type: 'null'
          title: Invoice No
          description: >-
            Optional invoice or transaction reference number for tracking and
            record-keeping.
          example: INV-2024-001234
        description:
          anyOf:
            - type: string
              maxLength: 255
            - type: 'null'
          title: Description
          description: Optional short note or description for the payout.
        to_bank_id:
          type: string
          format: uuid
          title: To Bank Id
          description: Saved payee bank id (bank details resolved server-side).
        payout_currency:
          type: string
          maxLength: 8
          title: Payout Currency
          description: Currency paid out.
          example: INR
      type: object
      required:
        - user_id
        - payee_id
        - amount
        - to_bank_id
        - payout_currency
      title: PlatformInternationalPayoutRequest
      description: >-
        Platform-side cross-border payout request.


        A cross-border payout always debits the payer's wallet to an
        international bank, so the payment

        and receiving methods are fixed server-side (WALLET / BANK) and are
        never partner-supplied. This

        is a dedicated schema carrying only the cross-border routing fields plus
        the funding basics

        (`payer_id`/`user_id`, `payee_id`, `amount`) and the extra `description`
        and `invoice_no`.
    CommonResponse_PlatformPayoutCreateResult_:
      properties:
        success:
          type: boolean
          title: Success
          description: Indicates whether the request was processed successfully.
          default: true
          example: true
        message:
          type: string
          title: Message
          description: >-
            A short, human-readable message describing the result of the
            request.
          default: Success
          example: Operation completed.
        data:
          anyOf:
            - $ref: '#/components/schemas/PlatformPayoutCreateResult'
            - type: 'null'
          description: The main response payload, if applicable
        queryGeneratedTime:
          anyOf:
            - type: number
            - type: 'null'
          title: Querygeneratedtime
          description: >-
            The Unix timestamp (in seconds) indicating when the response was
            generated.
          default: 1783409763.80796
          example: 1718006400
      type: object
      title: CommonResponse[PlatformPayoutCreateResult]
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    PlatformPayoutCreateResult:
      properties:
        payment_id:
          type: string
          title: Payment Id
          description: Paywint payment id of the created payout.
          example: f47ac10b-****-****-****-0e02b2c3d479
        status:
          type: string
          title: Status
          description: Payout status (created INITIATED pending approval).
          example: INITIATED
      type: object
      required:
        - payment_id
        - status
      title: PlatformPayoutCreateResult
      description: >-
        Result of creating a cross-border payout (created INITIATED, pending
        admin approval).
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````