{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/plaxswap-com/json-schema/plaxswap-com-create-payment-request-schema.json",
  "title": "CreatePaymentRequest",
  "x-generated": "2026-11-18",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/plaxswap-com-openapi.json#/components/schemas/CreatePaymentRequest",
  "type": "object",
  "properties": {
    "amount": {
      "type": "string",
      "description": "The price, for example \"100\" or \"25.50\".",
      "pattern": "^\\d+(\\.\\d+)?$"
    },
    "currency": {
      "type": "string",
      "description": "A fiat code (USD, EUR, INR...) converted when the payment is made, or a coin (USDT, BTC...)."
    },
    "receiveMode": {
      "type": "string",
      "description": "Original keeps the buyer asset in a custody wallet; selected preserves legacy conversion.",
      "enum": [
        "selected",
        "original"
      ]
    },
    "customer": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "maxLength": 120
        },
        "email": {
          "type": "string",
          "maxLength": 254,
          "format": "email"
        },
        "note": {
          "type": "string",
          "maxLength": 500
        }
      },
      "additionalProperties": false
    },
    "receive": {
      "type": "string",
      "description": "The coin and network you receive, for example \"usdt-tron\". Default: the one saved for your account."
    },
    "receiveAddress": {
      "type": "string",
      "description": "Where you receive. Default: your saved address (needed when you name another coin)."
    },
    "receiveMemo": {
      "type": "string",
      "description": "Memo, tag or comment of that address, on networks that use one."
    },
    "orderId": {
      "type": "string",
      "description": "Your own reference, for example your order number. Shown to the payer and searchable.",
      "maxLength": 100
    },
    "description": {
      "type": "string",
      "description": "Shown to the payer.",
      "maxLength": 500
    },
    "returnUrl": {
      "type": "string",
      "description": "Where the payer goes after paying (https).",
      "format": "uri"
    },
    "cancelUrl": {
      "type": "string",
      "description": "Where \"Back to the shop\" goes before paying (https).",
      "format": "uri"
    },
    "expiresInMinutes": {
      "type": "integer",
      "description": "How long the payment stays open.",
      "minimum": 15,
      "maximum": 1440
    },
    "customerPaysFee": {
      "type": "boolean",
      "description": "true: the payer pays the platform fee on top. false: it comes out of what you receive. Default: your account's choice."
    },
    "metadata": {
      "type": "object",
      "additionalProperties": {
        "type": "string",
        "maxLength": 500
      },
      "description": "Up to 20 keys of your own; sent back in every webhook."
    }
  },
  "required": [
    "amount",
    "currency",
    "receiveMode",
    "customer"
  ]
}