{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/plaxswap-com/json-schema/plaxswap-com-meta-response-schema.json",
  "title": "MetaResponse",
  "x-generated": "2026-11-18",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/plaxswap-com-openapi.json#/components/schemas/MetaResponse",
  "type": "object",
  "properties": {
    "exchangeReceiverRequired": {
      "type": "boolean",
      "description": "The exchange requires the actual recipient's name and country for withdrawals."
    },
    "fixedRate": {
      "type": "boolean",
      "description": "Fixed (locked) rates are offered. When false, quotes and fixed orders are refused with fixed_unavailable."
    },
    "brand": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string"
        },
        "tagline": {
          "type": "string"
        },
        "supportEmail": {
          "type": "string",
          "format": "email"
        }
      },
      "required": [
        "name",
        "tagline",
        "supportEmail"
      ]
    },
    "mode": {
      "$ref": "#/$defs/ChainMode"
    },
    "country": {
      "type": [
        "string",
        "null"
      ],
      "description": "ISO 3166-1 alpha-2 country resolved for this request, \"ZZ\" when unknown."
    },
    "countryName": {
      "type": [
        "string",
        "null"
      ]
    },
    "permissions": {
      "$ref": "#/$defs/Permissions"
    },
    "gatewayPermissions": {
      "$ref": "#/$defs/Permissions"
    },
    "devTools": {
      "type": "boolean",
      "description": "Developer tools (simulated deposits, country override) are available. Never on mainnet."
    },
    "quoteTtlSeconds": {
      "type": "integer",
      "description": "How long a fixed-rate quote holds."
    },
    "fixedOrderTtlSeconds": {
      "type": "integer",
      "description": "How long a fixed-rate order waits for its deposit."
    },
    "variableOrderTtlSeconds": {
      "type": "integer",
      "description": "How long a variable-rate order waits for deposits."
    },
    "incident": {
      "type": "object",
      "properties": {
        "pausedNewOrders": {
          "type": "boolean",
          "description": "Quotes and new orders are refused for now; open orders still complete."
        },
        "message": {
          "type": [
            "string",
            "null"
          ]
        },
        "announcement": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "required": [
        "pausedNewOrders",
        "message",
        "announcement"
      ]
    },
    "pilot": {
      "type": "object",
      "description": "Private real-money test. While active, quotes and orders from anyone else get HTTP 403 private_pilot.",
      "properties": {
        "active": {
          "type": "boolean",
          "description": "Private real-money pilot: only the signed-in operator may quote or order."
        },
        "operator": {
          "type": "boolean",
          "description": "This request comes from the pilot operator."
        },
        "maxSwapUsd": {
          "type": [
            "number",
            "null"
          ],
          "description": "The most one pilot swap may be worth right now, in US dollars."
        }
      },
      "required": [
        "active",
        "operator",
        "maxSwapUsd"
      ]
    },
    "fees": {
      "$ref": "#/$defs/FeeRules"
    },
    "fx": {
      "anyOf": [
        {
          "$ref": "#/$defs/FxSnapshot"
        },
        {
          "type": "null"
        }
      ]
    },
    "botCheckSiteKey": {
      "type": [
        "string",
        "null"
      ],
      "description": "Cloudflare Turnstile site key. When set, web orders send botCheckToken; API-key orders do not need it."
    }
  },
  "required": [
    "brand",
    "mode",
    "country",
    "countryName",
    "permissions",
    "gatewayPermissions",
    "devTools",
    "quoteTtlSeconds",
    "fixedOrderTtlSeconds",
    "variableOrderTtlSeconds",
    "incident",
    "pilot",
    "fees",
    "fx",
    "botCheckSiteKey"
  ],
  "$defs": {
    "ChainMode": {
      "type": "string",
      "description": "sim: simulated chains (the sandbox). testnet: public test networks. mainnet: real money.",
      "enum": [
        "sim",
        "testnet",
        "mainnet"
      ]
    },
    "FeeRules": {
      "type": "object",
      "properties": {
        "sameAssetBps": {
          "type": "integer",
          "description": "Our fee for moving the same coin to another network, in basis points (100 = 1%)."
        },
        "stableBps": {
          "type": "integer",
          "description": "Our fee between two stablecoins."
        },
        "majorBps": {
          "type": "integer",
          "description": "Our fee between major coins."
        },
        "otherBps": {
          "type": "integer",
          "description": "Our fee for other coins."
        },
        "fixedPremiumBps": {
          "type": "integer",
          "description": "Extra for locking the rate."
        },
        "volatilityMaxBps": {
          "type": "integer",
          "description": "The most added while prices move fast."
        },
        "gasMarginPct": {
          "type": "number",
          "description": "Network fees charged are the live estimate plus this safety margin, in percent."
        },
        "minEarningsUsd": {
          "type": "number",
          "description": "Our fee on one swap is at least this, in US dollars..."
        },
        "minEarningsMaxBps": {
          "type": "integer",
          "description": "...but the minimum never raises it above this share of the swap."
        },
        "surgeMaxUsd": {
          "type": "number",
          "description": "The busy-network extra never costs more than this on one swap, in US dollars."
        },
        "refundHandlingPct": {
          "type": "number",
          "description": "Refunds you caused (too little, too much, too late, a wrong fixed amount, or you asked): handling fee as a share of the deposit, in percent."
        },
        "refundHandlingMinUsd": {
          "type": "number",
          "description": "Smallest handling fee, in US dollars."
        },
        "refundHandlingMaxUsd": {
          "type": "number",
          "description": "Largest handling fee, in US dollars."
        }
      },
      "required": [
        "sameAssetBps",
        "stableBps",
        "majorBps",
        "otherBps",
        "fixedPremiumBps",
        "volatilityMaxBps",
        "gasMarginPct",
        "minEarningsUsd",
        "minEarningsMaxBps",
        "surgeMaxUsd",
        "refundHandlingPct",
        "refundHandlingMinUsd",
        "refundHandlingMaxUsd"
      ]
    },
    "FxSnapshot": {
      "type": "object",
      "description": "Display currencies. For showing estimates only, never for amounts that move.",
      "properties": {
        "base": {
          "type": "string",
          "const": "USD"
        },
        "rates": {
          "type": "object",
          "additionalProperties": {
            "type": "number"
          },
          "description": "Units of each currency for 1 US dollar."
        },
        "at": {
          "type": "string",
          "description": "When the rates were fetched (about once an hour).",
          "format": "date-time"
        }
      },
      "required": [
        "base",
        "rates",
        "at"
      ]
    },
    "Permissions": {
      "type": "object",
      "properties": {
        "canSwap": {
          "type": "boolean",
          "description": "False when swaps are not offered in the caller's country."
        },
        "status": {
          "$ref": "#/$defs/RuleStatus"
        },
        "reason": {
          "type": [
            "string",
            "null"
          ],
          "description": "Plain-English explanation of the country rule."
        },
        "maxOrderUsd": {
          "type": [
            "number",
            "null"
          ],
          "description": "Largest single swap without identity verification, in US dollars. null: no cap from the country rule."
        },
        "max30dUsd": {
          "type": [
            "number",
            "null"
          ],
          "description": "Rolling 30-day cap without identity verification, in US dollars."
        },
        "kycForAll": {
          "type": "boolean",
          "description": "Every swap from this country needs identity verification first."
        }
      },
      "required": [
        "canSwap",
        "status",
        "reason",
        "maxOrderUsd",
        "max30dUsd",
        "kycForAll"
      ]
    },
    "RuleStatus": {
      "type": "string",
      "description": "Country rule: allow, limited (caps without identity verification), kyc_all (verification first), block.",
      "enum": [
        "allow",
        "limited",
        "kyc_all",
        "block"
      ]
    }
  }
}