{
  "components": {
    "schemas": {
      "Account": {
        "additionalProperties": false,
        "properties": {
          "assets": {
            "items": {
              "$ref": "#/components/schemas/Balance"
            },
            "type": "array"
          },
          "availableBalance": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "canDeposit": {
            "const": false,
            "type": "boolean"
          },
          "canTrade": {
            "type": "boolean"
          },
          "canWithdraw": {
            "const": false,
            "type": "boolean"
          },
          "feeTier": {
            "format": "int64",
            "type": "integer"
          },
          "maxWithdrawAmount": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "positions": {
            "items": {
              "$ref": "#/components/schemas/AccountPosition"
            },
            "type": "array"
          },
          "totalCrossUnPnl": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalCrossWalletBalance": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalInitialMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalMaintMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalMarginBalance": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalOpenOrderInitialMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalPositionInitialMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalUnrealizedProfit": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "totalWalletBalance": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "updateTime": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "feeTier",
          "canTrade",
          "canDeposit",
          "canWithdraw",
          "updateTime",
          "totalWalletBalance",
          "totalUnrealizedProfit",
          "totalMarginBalance",
          "totalCrossWalletBalance",
          "totalCrossUnPnl",
          "totalInitialMargin",
          "totalMaintMargin",
          "totalPositionInitialMargin",
          "totalOpenOrderInitialMargin",
          "availableBalance",
          "maxWithdrawAmount",
          "assets",
          "positions"
        ],
        "type": "object"
      },
      "AccountPosition": {
        "additionalProperties": false,
        "properties": {
          "entryPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "initialMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "isolated": {
            "type": "boolean"
          },
          "leverage": {
            "type": "string"
          },
          "maintMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "marginType": {
            "enum": [
              "cross"
            ],
            "type": "string"
          },
          "maxNotional": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "openOrderInitialMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "positionAmt": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "positionInitialMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "positionSide": {
            "enum": [
              "BOTH"
            ],
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "unrealizedProfit": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "updateTime": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "positionAmt",
          "entryPrice",
          "leverage",
          "marginType",
          "positionSide",
          "updateTime",
          "unrealizedProfit",
          "initialMargin",
          "maintMargin",
          "positionInitialMargin",
          "openOrderInitialMargin",
          "maxNotional",
          "isolated"
        ],
        "type": "object"
      },
      "AggTrade": {
        "additionalProperties": false,
        "properties": {
          "T": {
            "format": "int64",
            "type": "integer"
          },
          "a": {
            "format": "int64",
            "type": "integer"
          },
          "f": {
            "format": "int64",
            "type": "integer"
          },
          "l": {
            "format": "int64",
            "type": "integer"
          },
          "m": {
            "type": "boolean"
          },
          "p": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "q": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          }
        },
        "required": [
          "a",
          "p",
          "q",
          "f",
          "l",
          "T",
          "m"
        ],
        "type": "object"
      },
      "AggTrades": {
        "items": {
          "$ref": "#/components/schemas/AggTrade"
        },
        "type": "array"
      },
      "ApiError": {
        "additionalProperties": false,
        "examples": [
          {
            "code": -1022,
            "msg": "Signature for this request is not valid."
          }
        ],
        "properties": {
          "code": {
            "format": "int64",
            "type": "integer"
          },
          "msg": {
            "type": "string"
          }
        },
        "required": [
          "code",
          "msg"
        ],
        "type": "object"
      },
      "Balance": {
        "additionalProperties": false,
        "examples": [
          {
            "accountAlias": "",
            "accountId": 42,
            "asset": "USDT",
            "availableBalance": "900.00000000",
            "balance": "1000.00000000",
            "crossUnPnl": "0.00000000",
            "crossWalletBalance": "1000.00000000",
            "marginAvailable": true,
            "maxWithdrawAmount": "900.00000000",
            "updateTime": 1700000000000
          }
        ],
        "properties": {
          "accountAlias": {
            "type": "string"
          },
          "accountId": {
            "format": "int64",
            "type": "integer"
          },
          "asset": {
            "type": "string"
          },
          "availableBalance": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "balance": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "crossUnPnl": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "crossWalletBalance": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "marginAvailable": {
            "type": "boolean"
          },
          "maxWithdrawAmount": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "updateTime": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "accountAlias",
          "accountId",
          "asset",
          "balance",
          "crossWalletBalance",
          "crossUnPnl",
          "availableBalance",
          "maxWithdrawAmount",
          "marginAvailable",
          "updateTime"
        ],
        "type": "object"
      },
      "Balances": {
        "items": {
          "$ref": "#/components/schemas/Balance"
        },
        "type": "array"
      },
      "BookTicker": {
        "additionalProperties": false,
        "properties": {
          "askPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "askQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "bidPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "bidQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "bidPrice",
          "bidQty",
          "askPrice",
          "askQty",
          "time"
        ],
        "type": "object"
      },
      "CommissionRate": {
        "additionalProperties": false,
        "examples": [
          {
            "makerCommissionRate": "0.000200",
            "symbol": "BTCUSDT",
            "takerCommissionRate": "0.000400"
          }
        ],
        "properties": {
          "makerCommissionRate": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "takerCommissionRate": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          }
        },
        "required": [
          "symbol",
          "makerCommissionRate",
          "takerCommissionRate"
        ],
        "type": "object"
      },
      "Depth": {
        "additionalProperties": false,
        "properties": {
          "E": {
            "format": "int64",
            "type": "integer"
          },
          "T": {
            "format": "int64",
            "type": "integer"
          },
          "asks": {
            "items": {
              "items": {
                "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                "type": "string"
              },
              "maxItems": 2,
              "minItems": 2,
              "type": "array"
            },
            "type": "array"
          },
          "bids": {
            "items": {
              "items": {
                "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                "type": "string"
              },
              "maxItems": 2,
              "minItems": 2,
              "type": "array"
            },
            "type": "array"
          },
          "lastUpdateId": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "lastUpdateId",
          "E",
          "T",
          "bids",
          "asks"
        ],
        "type": "object"
      },
      "Empty": {
        "additionalProperties": false,
        "examples": [
          {}
        ],
        "properties": {},
        "required": [],
        "type": "object"
      },
      "ExchangeInfo": {
        "additionalProperties": false,
        "properties": {
          "assets": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "asset": {
                  "type": "string"
                },
                "autoAssetExchange": {
                  "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                  "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                  "type": "string"
                },
                "marginAvailable": {
                  "type": "boolean"
                }
              },
              "required": [
                "asset",
                "marginAvailable",
                "autoAssetExchange"
              ],
              "type": "object"
            },
            "type": "array"
          },
          "exchangeFilters": {
            "maxItems": 0,
            "type": "array"
          },
          "futuresType": {
            "type": "string"
          },
          "rateLimits": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "interval": {
                  "type": "string"
                },
                "intervalNum": {
                  "format": "int64",
                  "type": "integer"
                },
                "limit": {
                  "format": "int64",
                  "type": "integer"
                },
                "rateLimitType": {
                  "type": "string"
                }
              },
              "required": [
                "rateLimitType",
                "interval",
                "intervalNum",
                "limit"
              ],
              "type": "object"
            },
            "type": "array"
          },
          "serverTime": {
            "format": "int64",
            "type": "integer"
          },
          "symbols": {
            "items": {
              "$ref": "#/components/schemas/SymbolInfo"
            },
            "type": "array"
          },
          "timezone": {
            "type": "string"
          }
        },
        "required": [
          "timezone",
          "serverTime",
          "futuresType",
          "rateLimits",
          "exchangeFilters",
          "assets",
          "symbols"
        ],
        "type": "object"
      },
      "ForceOrder": {
        "additionalProperties": false,
        "examples": [
          {
            "avgPrice": "25000.00",
            "clientOrderId": "autoclose-43",
            "closePosition": false,
            "cumQuote": "25000.00000",
            "executedQty": "1.000",
            "orderId": 43,
            "origQty": "1.000",
            "origType": "LIMIT",
            "positionSide": "BOTH",
            "price": "25000.00",
            "reduceOnly": true,
            "side": "SELL",
            "status": "FILLED",
            "symbol": "BTCUSDT",
            "time": 1700000000000,
            "timeInForce": "IOC",
            "type": "LIMIT",
            "updateTime": 1700000000000
          }
        ],
        "properties": {
          "avgPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "clientOrderId": {
            "type": "string"
          },
          "closePosition": {
            "type": "boolean"
          },
          "cumQuote": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "executedQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "orderId": {
            "format": "int64",
            "type": "integer"
          },
          "origQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "origType": {
            "enum": [
              "LIMIT",
              "MARKET"
            ],
            "type": "string"
          },
          "positionSide": {
            "enum": [
              "BOTH"
            ],
            "type": "string"
          },
          "price": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "reduceOnly": {
            "type": "boolean"
          },
          "side": {
            "enum": [
              "BUY",
              "SELL"
            ],
            "type": "string"
          },
          "status": {
            "enum": [
              "NEW",
              "PARTIALLY_FILLED",
              "FILLED",
              "CANCELED",
              "EXPIRED",
              "EXPIRED_IN_MATCH"
            ],
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          },
          "timeInForce": {
            "enum": [
              "GTC",
              "IOC",
              "FOK",
              "GTX"
            ],
            "type": "string"
          },
          "type": {
            "enum": [
              "LIMIT",
              "MARKET"
            ],
            "type": "string"
          },
          "updateTime": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "orderId",
          "symbol",
          "status",
          "clientOrderId",
          "price",
          "avgPrice",
          "origQty",
          "executedQty",
          "cumQuote",
          "timeInForce",
          "type",
          "origType",
          "reduceOnly",
          "closePosition",
          "side",
          "positionSide",
          "updateTime",
          "time"
        ],
        "type": "object"
      },
      "ForceOrders": {
        "items": {
          "$ref": "#/components/schemas/ForceOrder"
        },
        "type": "array"
      },
      "FundingInfo": {
        "additionalProperties": false,
        "properties": {
          "adjustedFundingRateCap": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "adjustedFundingRateFloor": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "disclaimer": {
            "type": "boolean"
          },
          "fundingIntervalHours": {
            "format": "int64",
            "type": "integer"
          },
          "symbol": {
            "type": "string"
          }
        },
        "required": [
          "symbol",
          "adjustedFundingRateCap",
          "adjustedFundingRateFloor",
          "fundingIntervalHours",
          "disclaimer"
        ],
        "type": "object"
      },
      "FundingInfos": {
        "items": {
          "$ref": "#/components/schemas/FundingInfo"
        },
        "type": "array"
      },
      "FundingRate": {
        "additionalProperties": false,
        "examples": [
          {
            "fundingRate": "0.00010000",
            "fundingTime": 1700000000000,
            "symbol": "BTCUSDT"
          }
        ],
        "properties": {
          "fundingRate": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "fundingTime": {
            "format": "int64",
            "type": "integer"
          },
          "symbol": {
            "type": "string"
          }
        },
        "required": [
          "symbol",
          "fundingRate",
          "fundingTime"
        ],
        "type": "object"
      },
      "FundingRates": {
        "items": {
          "$ref": "#/components/schemas/FundingRate"
        },
        "type": "array"
      },
      "Income": {
        "additionalProperties": false,
        "examples": [
          {
            "asset": "USDT",
            "income": "1000.00000000",
            "incomeType": "TRANSFER",
            "info": "TRANSFER",
            "symbol": "",
            "time": 1700000000000,
            "tradeId": "",
            "tranId": 42
          }
        ],
        "properties": {
          "asset": {
            "type": "string"
          },
          "income": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "incomeType": {
            "type": "string"
          },
          "info": {
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          },
          "tradeId": {
            "type": "string"
          },
          "tranId": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "incomeType",
          "income",
          "asset",
          "info",
          "time",
          "tranId",
          "tradeId"
        ],
        "type": "object"
      },
      "Incomes": {
        "items": {
          "$ref": "#/components/schemas/Income"
        },
        "type": "array"
      },
      "Kline": {
        "description": "Ordered tuple: openTime, open, high, low, close, volume, closeTime, quoteVolume, tradeCount, takerBuyVolume, takerBuyQuote, ignore.",
        "examples": [
          [
            1700000000000,
            "25000.00",
            "25100.00",
            "24900.00",
            "25050.00",
            "1.000",
            1700000059999,
            "25050.00000",
            1,
            "1.000",
            "25050.00000",
            "0"
          ]
        ],
        "items": false,
        "maxItems": 12,
        "minItems": 12,
        "prefixItems": [
          {
            "format": "int64",
            "type": "integer"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "format": "int64",
            "type": "integer"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "format": "int64",
            "type": "integer"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          {
            "enum": [
              "0"
            ],
            "type": "string"
          }
        ],
        "type": "array"
      },
      "Klines": {
        "examples": [
          [
            [
              1700000000000,
              "25000.00",
              "25100.00",
              "24900.00",
              "25050.00",
              "1.000",
              1700000059999,
              "25050.00000",
              1,
              "1.000",
              "25050.00000",
              "0"
            ]
          ]
        ],
        "items": {
          "$ref": "#/components/schemas/Kline"
        },
        "type": "array"
      },
      "Leverage": {
        "additionalProperties": false,
        "properties": {
          "leverage": {
            "format": "int64",
            "type": "integer"
          },
          "maxNotionalValue": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "symbol": {
            "type": "string"
          }
        },
        "required": [
          "leverage",
          "maxNotionalValue",
          "symbol"
        ],
        "type": "object"
      },
      "LeverageBracket": {
        "additionalProperties": false,
        "examples": [
          {
            "brackets": [
              {
                "bracket": 1,
                "cum": "0.00000000",
                "initialLeverage": 125,
                "maintMarginRatio": "0.00400000",
                "notionalCap": 50000,
                "notionalFloor": 0
              },
              {
                "bracket": 2,
                "cum": "50.00000000",
                "initialLeverage": 100,
                "maintMarginRatio": "0.00500000",
                "notionalCap": 500000,
                "notionalFloor": 50000
              },
              {
                "bracket": 3,
                "cum": "2550.00000000",
                "initialLeverage": 50,
                "maintMarginRatio": "0.01000000",
                "notionalCap": 10000000,
                "notionalFloor": 500000
              },
              {
                "bracket": 4,
                "cum": "152550.00000000",
                "initialLeverage": 20,
                "maintMarginRatio": "0.02500000",
                "notionalCap": 80000000,
                "notionalFloor": 10000000
              },
              {
                "bracket": 5,
                "cum": "2152550.00000000",
                "initialLeverage": 10,
                "maintMarginRatio": "0.05000000",
                "notionalCap": 150000000,
                "notionalFloor": 80000000
              },
              {
                "bracket": 6,
                "cum": "9652550.00000000",
                "initialLeverage": 5,
                "maintMarginRatio": "0.10000000",
                "notionalCap": 300000000,
                "notionalFloor": 150000000
              },
              {
                "bracket": 7,
                "cum": "17152550.00000000",
                "initialLeverage": 4,
                "maintMarginRatio": "0.12500000",
                "notionalCap": 450000000,
                "notionalFloor": 300000000
              },
              {
                "bracket": 8,
                "cum": "28402550.00000000",
                "initialLeverage": 3,
                "maintMarginRatio": "0.15000000",
                "notionalCap": 600000000,
                "notionalFloor": 450000000
              },
              {
                "bracket": 9,
                "cum": "88402550.00000000",
                "initialLeverage": 2,
                "maintMarginRatio": "0.25000000",
                "notionalCap": 800000000,
                "notionalFloor": 600000000
              },
              {
                "bracket": 10,
                "cum": "288402550.00000000",
                "initialLeverage": 1,
                "maintMarginRatio": "0.50000000",
                "notionalCap": 1000000000,
                "notionalFloor": 800000000
              }
            ],
            "symbol": "BTCUSDT"
          }
        ],
        "properties": {
          "brackets": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "bracket": {
                  "format": "int64",
                  "type": "integer"
                },
                "cum": {
                  "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                  "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                  "type": "string"
                },
                "initialLeverage": {
                  "format": "int64",
                  "type": "integer"
                },
                "maintMarginRatio": {
                  "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                  "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                  "type": "string"
                },
                "notionalCap": {
                  "format": "int64",
                  "type": "integer"
                },
                "notionalFloor": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "required": [
                "bracket",
                "initialLeverage",
                "notionalCap",
                "notionalFloor",
                "maintMarginRatio",
                "cum"
              ],
              "type": "object"
            },
            "type": "array"
          },
          "symbol": {
            "type": "string"
          }
        },
        "required": [
          "symbol",
          "brackets"
        ],
        "type": "object"
      },
      "LeverageBrackets": {
        "items": {
          "$ref": "#/components/schemas/LeverageBracket"
        },
        "type": "array"
      },
      "ListenKey": {
        "additionalProperties": false,
        "properties": {
          "listenKey": {
            "description": "Synthetic examples only. Treat a real Listen Key as a bearer secret.",
            "pattern": "^[0-9a-f]{64}$",
            "type": "string"
          }
        },
        "required": [
          "listenKey"
        ],
        "type": "object"
      },
      "Message": {
        "additionalProperties": false,
        "examples": [
          {
            "code": 200,
            "msg": "success"
          }
        ],
        "properties": {
          "code": {
            "format": "int64",
            "type": "integer"
          },
          "msg": {
            "type": "string"
          }
        },
        "required": [
          "code",
          "msg"
        ],
        "type": "object"
      },
      "OpenInterest": {
        "additionalProperties": false,
        "properties": {
          "openInterest": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "openInterest",
          "time"
        ],
        "type": "object"
      },
      "Order": {
        "additionalProperties": false,
        "examples": [
          {
            "avgPrice": "0.00",
            "clientOrderId": "example-order-42",
            "closePosition": false,
            "cumQty": "0.000",
            "cumQuote": "0.00000",
            "executedQty": "0.000",
            "goodTillDate": 0,
            "orderId": 42,
            "origQty": "1.000",
            "origType": "LIMIT",
            "positionSide": "BOTH",
            "price": "25000.00",
            "priceMatch": "NONE",
            "priceProtect": false,
            "reduceOnly": false,
            "selfTradePreventionMode": "EXPIRE_MAKER",
            "side": "BUY",
            "status": "NEW",
            "stopPrice": "0",
            "symbol": "BTCUSDT",
            "timeInForce": "GTC",
            "type": "LIMIT",
            "updateTime": 1700000000000,
            "workingType": "CONTRACT_PRICE"
          }
        ],
        "properties": {
          "avgPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "clientOrderId": {
            "type": "string"
          },
          "closePosition": {
            "type": "boolean"
          },
          "cumQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "cumQuote": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "executedQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "goodTillDate": {
            "format": "int64",
            "type": "integer"
          },
          "orderId": {
            "format": "int64",
            "type": "integer"
          },
          "origQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "origType": {
            "enum": [
              "LIMIT",
              "MARKET"
            ],
            "type": "string"
          },
          "positionSide": {
            "enum": [
              "BOTH"
            ],
            "type": "string"
          },
          "price": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "priceMatch": {
            "enum": [
              "NONE"
            ],
            "type": "string"
          },
          "priceProtect": {
            "type": "boolean"
          },
          "reduceOnly": {
            "type": "boolean"
          },
          "selfTradePreventionMode": {
            "enum": [
              "NONE",
              "EXPIRE_TAKER",
              "EXPIRE_MAKER",
              "EXPIRE_BOTH"
            ],
            "type": "string"
          },
          "side": {
            "enum": [
              "BUY",
              "SELL"
            ],
            "type": "string"
          },
          "status": {
            "enum": [
              "NEW",
              "PARTIALLY_FILLED",
              "FILLED",
              "CANCELED",
              "EXPIRED",
              "EXPIRED_IN_MATCH"
            ],
            "type": "string"
          },
          "stopPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "timeInForce": {
            "enum": [
              "GTC",
              "IOC",
              "FOK",
              "GTX"
            ],
            "type": "string"
          },
          "type": {
            "enum": [
              "LIMIT",
              "MARKET"
            ],
            "type": "string"
          },
          "updateTime": {
            "format": "int64",
            "type": "integer"
          },
          "workingType": {
            "enum": [
              "CONTRACT_PRICE"
            ],
            "type": "string"
          }
        },
        "required": [
          "orderId",
          "symbol",
          "status",
          "clientOrderId",
          "price",
          "avgPrice",
          "origQty",
          "executedQty",
          "cumQty",
          "cumQuote",
          "timeInForce",
          "type",
          "origType",
          "reduceOnly",
          "closePosition",
          "side",
          "positionSide",
          "stopPrice",
          "workingType",
          "priceProtect",
          "priceMatch",
          "selfTradePreventionMode",
          "goodTillDate",
          "updateTime"
        ],
        "type": "object"
      },
      "Orders": {
        "examples": [
          [
            {
              "avgPrice": "0.00",
              "clientOrderId": "example-order-42",
              "closePosition": false,
              "cumQty": "0.000",
              "cumQuote": "0.00000",
              "executedQty": "0.000",
              "goodTillDate": 0,
              "orderId": 42,
              "origQty": "1.000",
              "origType": "LIMIT",
              "positionSide": "BOTH",
              "price": "25000.00",
              "priceMatch": "NONE",
              "priceProtect": false,
              "reduceOnly": false,
              "selfTradePreventionMode": "EXPIRE_MAKER",
              "side": "BUY",
              "status": "NEW",
              "stopPrice": "0",
              "symbol": "BTCUSDT",
              "timeInForce": "GTC",
              "type": "LIMIT",
              "updateTime": 1700000000000,
              "workingType": "CONTRACT_PRICE"
            }
          ]
        ],
        "items": {
          "$ref": "#/components/schemas/Order"
        },
        "type": "array"
      },
      "PositionMode": {
        "additionalProperties": false,
        "properties": {
          "dualSidePosition": {
            "const": false,
            "type": "boolean"
          }
        },
        "required": [
          "dualSidePosition"
        ],
        "type": "object"
      },
      "PositionRisk": {
        "additionalProperties": false,
        "examples": [
          {
            "breakEvenPrice": "25000.00",
            "entryPrice": "25000.00",
            "isAutoAddMargin": "false",
            "isolatedMargin": "0.00000000",
            "isolatedWallet": "0",
            "leverage": "20",
            "liquidationPrice": "0.00",
            "marginType": "cross",
            "markPrice": "25000.00000000",
            "maxNotionalValue": "50000",
            "notional": "25000.00000000",
            "positionAmt": "1.000",
            "positionSide": "BOTH",
            "symbol": "BTCUSDT",
            "unRealizedProfit": "0.00000000",
            "updateTime": 1700000000000
          }
        ],
        "properties": {
          "breakEvenPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "entryPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "isAutoAddMargin": {
            "enum": [
              "false"
            ],
            "type": "string"
          },
          "isolatedMargin": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "isolatedWallet": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "leverage": {
            "type": "string"
          },
          "liquidationPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "marginType": {
            "enum": [
              "cross"
            ],
            "type": "string"
          },
          "markPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "maxNotionalValue": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "notional": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "positionAmt": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "positionSide": {
            "enum": [
              "BOTH"
            ],
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "unRealizedProfit": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "updateTime": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "positionAmt",
          "entryPrice",
          "leverage",
          "marginType",
          "positionSide",
          "updateTime",
          "breakEvenPrice",
          "markPrice",
          "unRealizedProfit",
          "liquidationPrice",
          "maxNotionalValue",
          "isolatedMargin",
          "isAutoAddMargin",
          "notional",
          "isolatedWallet"
        ],
        "type": "object"
      },
      "PositionRisks": {
        "items": {
          "$ref": "#/components/schemas/PositionRisk"
        },
        "type": "array"
      },
      "Premium": {
        "additionalProperties": false,
        "examples": [
          {
            "estimatedSettlePrice": "25000.00000000",
            "indexPrice": "25000.00000000",
            "interestRate": "0.00010000",
            "lastFundingRate": "0.00010000",
            "markPrice": "25000.00000000",
            "nextFundingTime": 1700028800000,
            "symbol": "BTCUSDT",
            "time": 1700000000000
          }
        ],
        "properties": {
          "estimatedSettlePrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "indexPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "interestRate": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "lastFundingRate": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "markPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "nextFundingTime": {
            "format": "int64",
            "type": "integer"
          },
          "symbol": {
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "markPrice",
          "indexPrice",
          "estimatedSettlePrice",
          "lastFundingRate",
          "interestRate",
          "nextFundingTime",
          "time"
        ],
        "type": "object"
      },
      "PremiumResult": {
        "examples": [
          {
            "estimatedSettlePrice": "25000.00000000",
            "indexPrice": "25000.00000000",
            "interestRate": "0.00010000",
            "lastFundingRate": "0.00010000",
            "markPrice": "25000.00000000",
            "nextFundingTime": 1700028800000,
            "symbol": "BTCUSDT",
            "time": 1700000000000
          }
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Premium"
          },
          {
            "items": {
              "$ref": "#/components/schemas/Premium"
            },
            "type": "array"
          }
        ]
      },
      "Price": {
        "additionalProperties": false,
        "properties": {
          "price": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "price",
          "time"
        ],
        "type": "object"
      },
      "PriceResult": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/Price"
          },
          {
            "items": {
              "$ref": "#/components/schemas/Price"
            },
            "type": "array"
          }
        ]
      },
      "ServerTime": {
        "additionalProperties": false,
        "examples": [
          {
            "serverTime": 1700000000000
          }
        ],
        "properties": {
          "serverTime": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "serverTime"
        ],
        "type": "object"
      },
      "SymbolInfo": {
        "additionalProperties": false,
        "examples": [
          {
            "baseAsset": "BTC",
            "baseAssetPrecision": 8,
            "contractType": "PERPETUAL",
            "deliveryDate": 4133404800000,
            "filters": [
              {
                "filterType": "PRICE_FILTER",
                "maxPrice": "4529764.00",
                "minPrice": "556.80",
                "tickSize": "0.10"
              },
              {
                "filterType": "LOT_SIZE",
                "maxQty": "1000.000",
                "minQty": "0.001",
                "stepSize": "0.001"
              },
              {
                "filterType": "MARKET_LOT_SIZE",
                "maxQty": "120.000",
                "minQty": "0.001",
                "stepSize": "0.001"
              },
              {
                "filterType": "MAX_NUM_ORDERS",
                "limit": 200
              },
              {
                "filterType": "MAX_NUM_ALGO_ORDERS",
                "limit": 10
              },
              {
                "filterType": "MIN_NOTIONAL",
                "notional": "100.00000"
              },
              {
                "filterType": "PERCENT_PRICE",
                "multiplierDecimal": "4",
                "multiplierDown": "0.9500",
                "multiplierUp": "1.0500"
              }
            ],
            "marginAsset": "USDT",
            "onboardDate": 1569398400000,
            "orderTypes": [
              "LIMIT",
              "MARKET"
            ],
            "pair": "BTCUSDT",
            "pricePrecision": 2,
            "quantityPrecision": 3,
            "quoteAsset": "USDT",
            "quotePrecision": 8,
            "settlePlan": 0,
            "status": "TRADING",
            "symbol": "BTCUSDT",
            "timeInForce": [
              "GTC",
              "IOC",
              "FOK",
              "GTX"
            ],
            "triggerProtect": "0.0500",
            "underlyingType": "COIN"
          }
        ],
        "properties": {
          "baseAsset": {
            "type": "string"
          },
          "baseAssetPrecision": {
            "format": "int64",
            "type": "integer"
          },
          "contractType": {
            "type": "string"
          },
          "deliveryDate": {
            "format": "int64",
            "type": "integer"
          },
          "filters": {
            "items": {
              "oneOf": [
                {
                  "additionalProperties": false,
                  "properties": {
                    "filterType": {
                      "enum": [
                        "PRICE_FILTER"
                      ],
                      "type": "string"
                    },
                    "maxPrice": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    },
                    "minPrice": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    },
                    "tickSize": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "filterType",
                    "minPrice",
                    "maxPrice",
                    "tickSize"
                  ],
                  "type": "object"
                },
                {
                  "additionalProperties": false,
                  "properties": {
                    "filterType": {
                      "enum": [
                        "LOT_SIZE"
                      ],
                      "type": "string"
                    },
                    "maxQty": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    },
                    "minQty": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    },
                    "stepSize": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "filterType",
                    "minQty",
                    "maxQty",
                    "stepSize"
                  ],
                  "type": "object"
                },
                {
                  "additionalProperties": false,
                  "properties": {
                    "filterType": {
                      "enum": [
                        "MARKET_LOT_SIZE"
                      ],
                      "type": "string"
                    },
                    "maxQty": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    },
                    "minQty": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    },
                    "stepSize": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "filterType",
                    "minQty",
                    "maxQty",
                    "stepSize"
                  ],
                  "type": "object"
                },
                {
                  "additionalProperties": false,
                  "properties": {
                    "filterType": {
                      "enum": [
                        "MAX_NUM_ORDERS"
                      ],
                      "type": "string"
                    },
                    "limit": {
                      "format": "int64",
                      "type": "integer"
                    }
                  },
                  "required": [
                    "filterType",
                    "limit"
                  ],
                  "type": "object"
                },
                {
                  "additionalProperties": false,
                  "properties": {
                    "filterType": {
                      "enum": [
                        "MAX_NUM_ALGO_ORDERS"
                      ],
                      "type": "string"
                    },
                    "limit": {
                      "format": "int64",
                      "type": "integer"
                    }
                  },
                  "required": [
                    "filterType",
                    "limit"
                  ],
                  "type": "object"
                },
                {
                  "additionalProperties": false,
                  "properties": {
                    "filterType": {
                      "enum": [
                        "MIN_NOTIONAL"
                      ],
                      "type": "string"
                    },
                    "notional": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "filterType",
                    "notional"
                  ],
                  "type": "object"
                },
                {
                  "additionalProperties": false,
                  "properties": {
                    "filterType": {
                      "enum": [
                        "PERCENT_PRICE"
                      ],
                      "type": "string"
                    },
                    "multiplierDecimal": {
                      "type": "string"
                    },
                    "multiplierDown": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    },
                    "multiplierUp": {
                      "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
                      "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "filterType",
                    "multiplierUp",
                    "multiplierDown",
                    "multiplierDecimal"
                  ],
                  "type": "object"
                }
              ]
            },
            "type": "array"
          },
          "marginAsset": {
            "type": "string"
          },
          "onboardDate": {
            "format": "int64",
            "type": "integer"
          },
          "orderTypes": {
            "items": {
              "enum": [
                "LIMIT",
                "MARKET"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "pair": {
            "type": "string"
          },
          "pricePrecision": {
            "format": "int64",
            "type": "integer"
          },
          "quantityPrecision": {
            "format": "int64",
            "type": "integer"
          },
          "quoteAsset": {
            "type": "string"
          },
          "quotePrecision": {
            "format": "int64",
            "type": "integer"
          },
          "settlePlan": {
            "format": "int64",
            "type": "integer"
          },
          "status": {
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "timeInForce": {
            "items": {
              "enum": [
                "GTC",
                "IOC",
                "FOK",
                "GTX"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "triggerProtect": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "underlyingType": {
            "type": "string"
          }
        },
        "required": [
          "symbol",
          "pair",
          "contractType",
          "deliveryDate",
          "onboardDate",
          "status",
          "baseAsset",
          "quoteAsset",
          "marginAsset",
          "pricePrecision",
          "quantityPrecision",
          "baseAssetPrecision",
          "quotePrecision",
          "underlyingType",
          "settlePlan",
          "triggerProtect",
          "filters",
          "orderTypes",
          "timeInForce"
        ],
        "type": "object"
      },
      "Ticker24": {
        "additionalProperties": false,
        "examples": [
          {
            "closeTime": 1700000000000,
            "count": 0,
            "firstId": 0,
            "highPrice": "0.00",
            "lastId": 0,
            "lastPrice": "0.00",
            "lastQty": "0",
            "lowPrice": "0.00",
            "openPrice": "0.00",
            "openTime": 1700000000000,
            "priceChange": "0.00",
            "priceChangePercent": "0.000",
            "quoteVolume": "0.00000",
            "symbol": "BTCUSDT",
            "volume": "0.000",
            "weightedAvgPrice": "0"
          }
        ],
        "properties": {
          "closeTime": {
            "format": "int64",
            "type": "integer"
          },
          "count": {
            "format": "int64",
            "type": "integer"
          },
          "firstId": {
            "format": "int64",
            "type": "integer"
          },
          "highPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "lastId": {
            "format": "int64",
            "type": "integer"
          },
          "lastPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "lastQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "lowPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "openPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "openTime": {
            "format": "int64",
            "type": "integer"
          },
          "priceChange": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "priceChangePercent": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "quoteVolume": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "volume": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "weightedAvgPrice": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          }
        },
        "required": [
          "symbol",
          "priceChange",
          "priceChangePercent",
          "weightedAvgPrice",
          "lastPrice",
          "lastQty",
          "openPrice",
          "highPrice",
          "lowPrice",
          "volume",
          "quoteVolume",
          "openTime",
          "closeTime",
          "firstId",
          "lastId",
          "count"
        ],
        "type": "object"
      },
      "Ticker24Result": {
        "examples": [
          [
            {
              "closeTime": 1700000000000,
              "count": 0,
              "firstId": 0,
              "highPrice": "0.00",
              "lastId": 0,
              "lastPrice": "0.00",
              "lastQty": "0",
              "lowPrice": "0.00",
              "openPrice": "0.00",
              "openTime": 1700000000000,
              "priceChange": "0.00",
              "priceChangePercent": "0.000",
              "quoteVolume": "0.00000",
              "symbol": "BTCUSDT",
              "volume": "0.000",
              "weightedAvgPrice": "0"
            }
          ]
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Ticker24"
          },
          {
            "items": {
              "$ref": "#/components/schemas/Ticker24"
            },
            "type": "array"
          }
        ]
      },
      "Trade": {
        "additionalProperties": false,
        "properties": {
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "isBuyerMaker": {
            "type": "boolean"
          },
          "price": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "qty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "quoteQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "id",
          "price",
          "qty",
          "quoteQty",
          "time",
          "isBuyerMaker"
        ],
        "type": "object"
      },
      "Trades": {
        "items": {
          "$ref": "#/components/schemas/Trade"
        },
        "type": "array"
      },
      "UserTrade": {
        "additionalProperties": false,
        "properties": {
          "buyer": {
            "type": "boolean"
          },
          "commission": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "commissionAsset": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "maker": {
            "type": "boolean"
          },
          "orderId": {
            "format": "int64",
            "type": "integer"
          },
          "positionSide": {
            "enum": [
              "BOTH"
            ],
            "type": "string"
          },
          "price": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "qty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "quoteQty": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "realizedPnl": {
            "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
            "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
            "type": "string"
          },
          "side": {
            "enum": [
              "BUY",
              "SELL"
            ],
            "type": "string"
          },
          "symbol": {
            "type": "string"
          },
          "time": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "symbol",
          "id",
          "orderId",
          "side",
          "buyer",
          "maker",
          "price",
          "qty",
          "quoteQty",
          "realizedPnl",
          "commission",
          "commissionAsset",
          "positionSide",
          "time"
        ],
        "type": "object"
      },
      "UserTrades": {
        "items": {
          "$ref": "#/components/schemas/UserTrade"
        },
        "type": "array"
      }
    },
    "securitySchemes": {
      "ApiKey": {
        "description": "API Credential key for one Trading Account. Signed routes additionally require per-request HMAC-SHA256. This field does not compute signatures. Never paste secrets into the documentation site.",
        "in": "header",
        "name": "X-MBX-APIKEY",
        "type": "apiKey"
      }
    }
  },
  "info": {
    "description": "Implemented Binance-compatible USD-M REST subset. Paper is a restricted Internal Paper Pilot; implementation does not imply approved public availability. API Credentials authorize one Trading Account and never browser login, funding, or account administration. The separately deployed documentation site does not change API endpoint hosts.",
    "title": "Mariex Trading REST API",
    "version": "0.1.0"
  },
  "openapi": "3.1.0",
  "paths": {
    "/fapi/v1/aggTrades": {
      "get": {
        "description": "",
        "operationId": "agg_trades",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Values above 1000 are clamped to 1000.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 500,
              "minimum": 1,
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AggTrades"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "One aggregate per persisted local match",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/allOpenOrders": {
      "delete": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nTRADE permission is required.",
        "operationId": "cancel_all_orders",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "code": 200,
                  "msg": "success"
                },
                "schema": {
                  "$ref": "#/components/schemas/Message"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Cancel every open order for one symbol",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "TRADE"
      }
    },
    "/fapi/v1/allOrders": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "all_orders",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Values above 1000 are clamped to 1000.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 500,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "limit": {
                    "default": 500,
                    "description": "Values above 1000 are clamped to 1000.",
                    "minimum": 1,
                    "type": "integer"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": [
                  {
                    "avgPrice": "0.00",
                    "clientOrderId": "example-order-42",
                    "closePosition": false,
                    "cumQty": "0.000",
                    "cumQuote": "0.00000",
                    "executedQty": "0.000",
                    "goodTillDate": 0,
                    "orderId": 42,
                    "origQty": "1.000",
                    "origType": "LIMIT",
                    "positionSide": "BOTH",
                    "price": "25000.00",
                    "priceMatch": "NONE",
                    "priceProtect": false,
                    "reduceOnly": false,
                    "selfTradePreventionMode": "EXPIRE_MAKER",
                    "side": "BUY",
                    "status": "NEW",
                    "stopPrice": "0",
                    "symbol": "BTCUSDT",
                    "timeInForce": "GTC",
                    "type": "LIMIT",
                    "updateTime": 1700000000000,
                    "workingType": "CONTRACT_PRICE"
                  }
                ],
                "schema": {
                  "$ref": "#/components/schemas/Orders"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Persisted order history, may lag acknowledged commands",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "limit": {
              "default": 500,
              "description": "Values above 1000 are clamped to 1000.",
              "minimum": 1,
              "type": "integer"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 5,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v1/commissionRate": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "commission_rate",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "makerCommissionRate": "0.000200",
                  "symbol": "BTCUSDT",
                  "takerCommissionRate": "0.000400"
                },
                "schema": {
                  "$ref": "#/components/schemas/CommissionRate"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Global default commission schedule",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v1/depth": {
      "get": {
        "description": "",
        "operationId": "depth",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Only these discrete sizes are accepted.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 500,
              "enum": [
                5,
                10,
                20,
                50,
                100,
                500,
                1000
              ],
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Depth"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Local order book snapshot",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 5,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/exchangeInfo": {
      "get": {
        "description": "",
        "operationId": "exchange_info",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ExchangeInfo"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Listed symbols, filters and configured rate limits",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/forceOrders": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "force_orders",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "startTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "endTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Values above 100 are clamped to 100.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "endTime": {
                    "description": "Inclusive epoch milliseconds; absent means unbounded.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "limit": {
                    "default": 50,
                    "description": "Values above 100 are clamped to 100.",
                    "minimum": 1,
                    "type": "integer"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "startTime": {
                    "description": "Inclusive epoch milliseconds; absent means unbounded.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ForceOrders"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Persisted liquidation closing orders, newest first",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "endTime": {
              "description": "Inclusive epoch milliseconds; absent means unbounded.",
              "format": "int64",
              "type": "integer"
            },
            "limit": {
              "default": 50,
              "description": "Values above 100 are clamped to 100.",
              "minimum": 1,
              "type": "integer"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "startTime": {
              "description": "Inclusive epoch milliseconds; absent means unbounded.",
              "format": "int64",
              "type": "integer"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v1/fundingInfo": {
      "get": {
        "description": "",
        "operationId": "funding_info",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundingInfos"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Cached funding caps and intervals",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/fundingRate": {
      "get": {
        "description": "",
        "operationId": "funding_rate",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "startTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "endTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Values above 1000 are clamped to 1000.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 100,
              "minimum": 1,
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundingRates"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Local funding history, symbol required",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 5,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/income": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "income",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "startTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "endTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Values above 1000 are clamped to 1000.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 100,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "TRANSFER, REALIZED_PNL, COMMISSION, FUNDING_FEE; other types return an empty array.",
            "in": "query",
            "name": "incomeType",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "One-based page number.",
            "in": "query",
            "name": "page",
            "required": false,
            "schema": {
              "default": 1,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "endTime": {
                    "description": "Inclusive epoch milliseconds; absent means unbounded.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "incomeType": {
                    "description": "TRANSFER, REALIZED_PNL, COMMISSION, FUNDING_FEE; other types return an empty array.",
                    "type": "string"
                  },
                  "limit": {
                    "default": 100,
                    "description": "Values above 1000 are clamped to 1000.",
                    "minimum": 1,
                    "type": "integer"
                  },
                  "page": {
                    "default": 1,
                    "description": "One-based page number.",
                    "minimum": 1,
                    "type": "integer"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "startTime": {
                    "description": "Inclusive epoch milliseconds; absent means unbounded.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Incomes"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Persisted wallet movements, oldest first, may lag live balance",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "endTime": {
              "description": "Inclusive epoch milliseconds; absent means unbounded.",
              "format": "int64",
              "type": "integer"
            },
            "incomeType": {
              "description": "TRANSFER, REALIZED_PNL, COMMISSION, FUNDING_FEE; other types return an empty array.",
              "type": "string"
            },
            "limit": {
              "default": 100,
              "description": "Values above 1000 are clamped to 1000.",
              "minimum": 1,
              "type": "integer"
            },
            "page": {
              "default": 1,
              "description": "One-based page number.",
              "minimum": 1,
              "type": "integer"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "startTime": {
              "description": "Inclusive epoch milliseconds; absent means unbounded.",
              "format": "int64",
              "type": "integer"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 30,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v1/klines": {
      "get": {
        "description": "",
        "operationId": "klines",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "startTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Inclusive epoch milliseconds; absent means unbounded.",
            "in": "query",
            "name": "endTime",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Values above 1500 are clamped to 1500.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 500,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "Candles come from local trades, not upstream exchange candles.",
            "in": "query",
            "name": "interval",
            "required": false,
            "schema": {
              "default": "1m",
              "enum": [
                "1m",
                "3m",
                "5m",
                "15m",
                "30m",
                "1h",
                "2h",
                "4h",
                "6h",
                "12h",
                "1d"
              ],
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": [
                  [
                    1700000000000,
                    "25000.00",
                    "25100.00",
                    "24900.00",
                    "25050.00",
                    "1.000",
                    1700000059999,
                    "25050.00000",
                    1,
                    "1.000",
                    "25050.00000",
                    "0"
                  ]
                ],
                "schema": {
                  "$ref": "#/components/schemas/Klines"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Local trade candles, higher intervals rolled up on read",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 5,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/leverage": {
      "post": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nTRADE permission is required.",
        "operationId": "change_leverage",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Must also fit the symbol's configured leverage bracket.",
            "in": "query",
            "name": "leverage",
            "required": false,
            "schema": {
              "maximum": 4294967295,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "leverage": {
                    "description": "Must also fit the symbol's configured leverage bracket.",
                    "maximum": 4294967295,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Leverage"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Change leverage within the configured bracket cap",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "leverage": {
              "description": "Must also fit the symbol's configured leverage bracket.",
              "maximum": 4294967295,
              "minimum": 1,
              "type": "integer"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "leverage",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "leverage",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "TRADE"
      }
    },
    "/fapi/v1/leverageBracket": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "leverage_bracket",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LeverageBrackets"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Seeded leverage brackets, always an array",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v1/listenKey": {
      "delete": {
        "description": "API key only. No HMAC signature, timestamp or listenKey parameter is required. Operates on the calling credential's key, not a supplied bearer. Sibling credentials retain independent Listen Keys. PUT without a live key returns -1125; DELETE is idempotent.",
        "operationId": "listen_key_delete",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {},
                "schema": {
                  "$ref": "#/components/schemas/Empty"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Close the calling credential's Listen Key",
        "tags": [
          "Listen Keys"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "USER_STREAM"
      },
      "post": {
        "description": "API key only. No HMAC signature, timestamp or listenKey parameter is required. Operates on the calling credential's key, not a supplied bearer. Sibling credentials retain independent Listen Keys. PUT without a live key returns -1125; DELETE is idempotent.",
        "operationId": "listen_key_create",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ListenKey"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Create or rearm the calling credential's 60-minute Listen Key",
        "tags": [
          "Listen Keys"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "USER_STREAM"
      },
      "put": {
        "description": "API key only. No HMAC signature, timestamp or listenKey parameter is required. Operates on the calling credential's key, not a supplied bearer. Sibling credentials retain independent Listen Keys. PUT without a live key returns -1125; DELETE is idempotent.",
        "operationId": "listen_key_extend",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {},
                "schema": {
                  "$ref": "#/components/schemas/Empty"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Extend the calling credential's live Listen Key",
        "tags": [
          "Listen Keys"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "USER_STREAM"
      }
    },
    "/fapi/v1/marginType": {
      "post": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nTRADE permission is required.",
        "operationId": "change_margin_type",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Only CROSSED succeeds; ISOLATED returns -4046.",
            "in": "query",
            "name": "marginType",
            "required": false,
            "schema": {
              "enum": [
                "CROSSED",
                "ISOLATED"
              ],
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "marginType": {
                    "description": "Only CROSSED succeeds; ISOLATED returns -4046.",
                    "enum": [
                      "CROSSED",
                      "ISOLATED"
                    ],
                    "type": "string"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "code": 200,
                  "msg": "success"
                },
                "schema": {
                  "$ref": "#/components/schemas/Message"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Retain cross margin, isolated margin is rejected",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "marginType": {
              "description": "Only CROSSED succeeds; ISOLATED returns -4046.",
              "enum": [
                "CROSSED",
                "ISOLATED"
              ],
              "type": "string"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "marginType",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "marginType",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "TRADE"
      }
    },
    "/fapi/v1/openInterest": {
      "get": {
        "description": "",
        "operationId": "open_interest",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenInterest"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Last-good upstream open interest cache",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/openOrders": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "open_orders",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": [
                  {
                    "avgPrice": "0.00",
                    "clientOrderId": "example-order-42",
                    "closePosition": false,
                    "cumQty": "0.000",
                    "cumQuote": "0.00000",
                    "executedQty": "0.000",
                    "goodTillDate": 0,
                    "orderId": 42,
                    "origQty": "1.000",
                    "origType": "LIMIT",
                    "positionSide": "BOTH",
                    "price": "25000.00",
                    "priceMatch": "NONE",
                    "priceProtect": false,
                    "reduceOnly": false,
                    "selfTradePreventionMode": "EXPIRE_MAKER",
                    "side": "BUY",
                    "status": "NEW",
                    "stopPrice": "0",
                    "symbol": "BTCUSDT",
                    "timeInForce": "GTC",
                    "type": "LIMIT",
                    "updateTime": 1700000000000,
                    "workingType": "CONTRACT_PRICE"
                  }
                ],
                "schema": {
                  "$ref": "#/components/schemas/Orders"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Current open orders from live state with database fallback",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v1/order": {
      "delete": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nTRADE permission is required.",
        "operationId": "cancel_order",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "One of orderId or origClientOrderId is required. orderId wins when both are present.",
            "in": "query",
            "name": "orderId",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Client identifier alternative to orderId.",
            "in": "query",
            "name": "origClientOrderId",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "orderId": {
                    "description": "One of orderId or origClientOrderId is required. orderId wins when both are present.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "origClientOrderId": {
                    "description": "Client identifier alternative to orderId.",
                    "type": "string"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "avgPrice": "0.00",
                  "clientOrderId": "example-order-42",
                  "closePosition": false,
                  "cumQty": "0.000",
                  "cumQuote": "0.00000",
                  "executedQty": "0.000",
                  "goodTillDate": 0,
                  "orderId": 42,
                  "origQty": "1.000",
                  "origType": "LIMIT",
                  "positionSide": "BOTH",
                  "price": "25000.00",
                  "priceMatch": "NONE",
                  "priceProtect": false,
                  "reduceOnly": false,
                  "selfTradePreventionMode": "EXPIRE_MAKER",
                  "side": "BUY",
                  "status": "NEW",
                  "stopPrice": "0",
                  "symbol": "BTCUSDT",
                  "timeInForce": "GTC",
                  "type": "LIMIT",
                  "updateTime": 1700000000000,
                  "workingType": "CONTRACT_PRICE"
                },
                "schema": {
                  "$ref": "#/components/schemas/Order"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Cancel one order, orderId takes precedence over origClientOrderId",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "anyOf": [
            {
              "required": [
                "orderId"
              ]
            },
            {
              "required": [
                "origClientOrderId"
              ]
            }
          ],
          "properties": {
            "orderId": {
              "description": "One of orderId or origClientOrderId is required. orderId wins when both are present.",
              "format": "int64",
              "type": "integer"
            },
            "origClientOrderId": {
              "description": "Client identifier alternative to orderId.",
              "type": "string"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "TRADE"
      },
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "query_order",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "One of orderId or origClientOrderId is required. orderId wins when both are present.",
            "in": "query",
            "name": "orderId",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Client identifier alternative to orderId.",
            "in": "query",
            "name": "origClientOrderId",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "orderId": {
                    "description": "One of orderId or origClientOrderId is required. orderId wins when both are present.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "origClientOrderId": {
                    "description": "Client identifier alternative to orderId.",
                    "type": "string"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "avgPrice": "0.00",
                  "clientOrderId": "example-order-42",
                  "closePosition": false,
                  "cumQty": "0.000",
                  "cumQuote": "0.00000",
                  "executedQty": "0.000",
                  "goodTillDate": 0,
                  "orderId": 42,
                  "origQty": "1.000",
                  "origType": "LIMIT",
                  "positionSide": "BOTH",
                  "price": "25000.00",
                  "priceMatch": "NONE",
                  "priceProtect": false,
                  "reduceOnly": false,
                  "selfTradePreventionMode": "EXPIRE_MAKER",
                  "side": "BUY",
                  "status": "NEW",
                  "stopPrice": "0",
                  "symbol": "BTCUSDT",
                  "timeInForce": "GTC",
                  "type": "LIMIT",
                  "updateTime": 1700000000000,
                  "workingType": "CONTRACT_PRICE"
                },
                "schema": {
                  "$ref": "#/components/schemas/Order"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Query one order, orderId takes precedence over origClientOrderId",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "anyOf": [
            {
              "required": [
                "orderId"
              ]
            },
            {
              "required": [
                "origClientOrderId"
              ]
            }
          ],
          "properties": {
            "orderId": {
              "description": "One of orderId or origClientOrderId is required. orderId wins when both are present.",
              "format": "int64",
              "type": "integer"
            },
            "origClientOrderId": {
              "description": "Client identifier alternative to orderId.",
              "type": "string"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      },
      "post": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nTRADE permission is required.\n\nclosePosition, stopPrice, priceMatch, goodTillDate and workingType are rejected when present. MARKET rejects price when present, and MARKET timeInForce accepts absent or IOC only. LIMIT timeInForce defaults to GTC. STP defaults to EXPIRE_MAKER and NONE is rejected. After an uncertain command outcome, query authoritative order/open-order state before retrying; persisted history may lag.",
        "operationId": "place_order",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Order side.",
            "in": "query",
            "name": "side",
            "required": false,
            "schema": {
              "enum": [
                "BUY",
                "SELL"
              ],
              "type": "string"
            }
          },
          {
            "description": "Only LIMIT and MARKET are implemented.",
            "in": "query",
            "name": "type",
            "required": false,
            "schema": {
              "enum": [
                "LIMIT",
                "MARKET"
              ],
              "type": "string"
            }
          },
          {
            "description": "Positive quantity at symbol precision and within symbol filters.",
            "in": "query",
            "name": "quantity",
            "required": false,
            "schema": {
              "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
              "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
              "type": "string"
            }
          },
          {
            "description": "Required for LIMIT. Rejected when present for MARKET.",
            "in": "query",
            "name": "price",
            "required": false,
            "schema": {
              "description": "Decimal encoded as a string. Precision follows the symbol or the field's documented scale. Never convert to a binary floating-point number for signing or accounting.",
              "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
              "type": "string"
            }
          },
          {
            "description": "LIMIT defaults to GTC. MARKET accepts absent or IOC only.",
            "in": "query",
            "name": "timeInForce",
            "required": false,
            "schema": {
              "enum": [
                "GTC",
                "IOC",
                "FOK",
                "GTX"
              ],
              "type": "string"
            }
          },
          {
            "description": "Default false.",
            "in": "query",
            "name": "reduceOnly",
            "required": false,
            "schema": {
              "enum": [
                "false",
                "true"
              ],
              "type": "string"
            }
          },
          {
            "description": "Only BOTH is accepted.",
            "in": "query",
            "name": "positionSide",
            "required": false,
            "schema": {
              "enum": [
                "BOTH"
              ],
              "type": "string"
            }
          },
          {
            "description": "Unique among open orders. Duplicate open IDs return -4116. Resolve uncertain outcomes through reads before retrying.",
            "in": "query",
            "name": "newClientOrderId",
            "required": false,
            "schema": {
              "pattern": "^[.A-Z:/a-z0-9_-]{1,36}$",
              "type": "string"
            }
          },
          {
            "description": "Both return the same synchronous post-match report.",
            "in": "query",
            "name": "newOrderRespType",
            "required": false,
            "schema": {
              "enum": [
                "ACK",
                "RESULT"
              ],
              "type": "string"
            }
          },
          {
            "description": "Default EXPIRE_MAKER. NONE is rejected; applied by the matching engine.",
            "in": "query",
            "name": "selfTradePreventionMode",
            "required": false,
            "schema": {
              "enum": [
                "EXPIRE_TAKER",
                "EXPIRE_MAKER",
                "EXPIRE_BOTH"
              ],
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "newClientOrderId": {
                    "description": "Unique among open orders. Duplicate open IDs return -4116. Resolve uncertain outcomes through reads before retrying.",
                    "pattern": "^[.A-Z:/a-z0-9_-]{1,36}$",
                    "type": "string"
                  },
                  "newOrderRespType": {
                    "description": "Both return the same synchronous post-match report.",
                    "enum": [
                      "ACK",
                      "RESULT"
                    ],
                    "type": "string"
                  },
                  "positionSide": {
                    "description": "Only BOTH is accepted.",
                    "enum": [
                      "BOTH"
                    ],
                    "type": "string"
                  },
                  "price": {
                    "description": "Required for LIMIT. Rejected when present for MARKET.",
                    "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                    "type": "string"
                  },
                  "quantity": {
                    "description": "Positive quantity at symbol precision and within symbol filters.",
                    "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
                    "type": "string"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "reduceOnly": {
                    "description": "Default false.",
                    "enum": [
                      "false",
                      "true"
                    ],
                    "type": "string"
                  },
                  "selfTradePreventionMode": {
                    "description": "Default EXPIRE_MAKER. NONE is rejected; applied by the matching engine.",
                    "enum": [
                      "EXPIRE_TAKER",
                      "EXPIRE_MAKER",
                      "EXPIRE_BOTH"
                    ],
                    "type": "string"
                  },
                  "side": {
                    "description": "Order side.",
                    "enum": [
                      "BUY",
                      "SELL"
                    ],
                    "type": "string"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timeInForce": {
                    "description": "LIMIT defaults to GTC. MARKET accepts absent or IOC only.",
                    "enum": [
                      "GTC",
                      "IOC",
                      "FOK",
                      "GTX"
                    ],
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  },
                  "type": {
                    "description": "Only LIMIT and MARKET are implemented.",
                    "enum": [
                      "LIMIT",
                      "MARKET"
                    ],
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "avgPrice": "0.00",
                  "clientOrderId": "example-order-42",
                  "closePosition": false,
                  "cumQty": "0.000",
                  "cumQuote": "0.00000",
                  "executedQty": "0.000",
                  "goodTillDate": 0,
                  "orderId": 42,
                  "origQty": "1.000",
                  "origType": "LIMIT",
                  "positionSide": "BOTH",
                  "price": "25000.00",
                  "priceMatch": "NONE",
                  "priceProtect": false,
                  "reduceOnly": false,
                  "selfTradePreventionMode": "EXPIRE_MAKER",
                  "side": "BUY",
                  "status": "NEW",
                  "stopPrice": "0",
                  "symbol": "BTCUSDT",
                  "timeInForce": "GTC",
                  "type": "LIMIT",
                  "updateTime": 1700000000000,
                  "workingType": "CONTRACT_PRICE"
                },
                "schema": {
                  "$ref": "#/components/schemas/Order"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-ORDER-COUNT-1M": {
                "description": "Completed successful placements for the verified account. Outstanding reservations can exhaust capacity below this count. Absent for unauthenticated requests.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-ORDER-COUNT-1M": {
                "description": "Completed successful placements for the verified account. Outstanding reservations can exhaust capacity below this count. Absent for unauthenticated requests.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-ORDER-COUNT-1M": {
                "description": "Completed successful placements for the verified account. Outstanding reservations can exhaust capacity below this count. Absent for unauthenticated requests.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-ORDER-COUNT-1M": {
                "description": "Completed successful placements for the verified account. Outstanding reservations can exhaust capacity below this count. Absent for unauthenticated requests.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-ORDER-COUNT-1M": {
                "description": "Completed successful placements for the verified account. Outstanding reservations can exhaust capacity below this count. Absent for unauthenticated requests.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-ORDER-COUNT-1M": {
                "description": "Completed successful placements for the verified account. Outstanding reservations can exhaust capacity below this count. Absent for unauthenticated requests.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Place LIMIT or MARKET order",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "allOf": [
            {
              "if": {
                "properties": {
                  "type": {
                    "const": "LIMIT"
                  }
                }
              },
              "then": {
                "required": [
                  "price"
                ]
              }
            },
            {
              "if": {
                "properties": {
                  "type": {
                    "const": "MARKET"
                  }
                }
              },
              "then": {
                "not": {
                  "required": [
                    "price"
                  ]
                },
                "properties": {
                  "timeInForce": {
                    "const": "IOC"
                  }
                }
              }
            },
            {
              "not": {
                "anyOf": [
                  {
                    "required": [
                      "closePosition"
                    ]
                  },
                  {
                    "required": [
                      "stopPrice"
                    ]
                  },
                  {
                    "required": [
                      "priceMatch"
                    ]
                  },
                  {
                    "required": [
                      "goodTillDate"
                    ]
                  },
                  {
                    "required": [
                      "workingType"
                    ]
                  }
                ]
              }
            }
          ],
          "properties": {
            "newClientOrderId": {
              "description": "Unique among open orders. Duplicate open IDs return -4116. Resolve uncertain outcomes through reads before retrying.",
              "pattern": "^[.A-Z:/a-z0-9_-]{1,36}$",
              "type": "string"
            },
            "newOrderRespType": {
              "description": "Both return the same synchronous post-match report.",
              "enum": [
                "ACK",
                "RESULT"
              ],
              "type": "string"
            },
            "positionSide": {
              "description": "Only BOTH is accepted.",
              "enum": [
                "BOTH"
              ],
              "type": "string"
            },
            "price": {
              "description": "Required for LIMIT. Rejected when present for MARKET.",
              "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
              "type": "string"
            },
            "quantity": {
              "description": "Positive quantity at symbol precision and within symbol filters.",
              "pattern": "^-?[0-9]+(\\.[0-9]+)?$",
              "type": "string"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "reduceOnly": {
              "description": "Default false.",
              "enum": [
                "false",
                "true"
              ],
              "type": "string"
            },
            "selfTradePreventionMode": {
              "description": "Default EXPIRE_MAKER. NONE is rejected; applied by the matching engine.",
              "enum": [
                "EXPIRE_TAKER",
                "EXPIRE_MAKER",
                "EXPIRE_BOTH"
              ],
              "type": "string"
            },
            "side": {
              "description": "Order side.",
              "enum": [
                "BUY",
                "SELL"
              ],
              "type": "string"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timeInForce": {
              "description": "LIMIT defaults to GTC. MARKET accepts absent or IOC only.",
              "enum": [
                "GTC",
                "IOC",
                "FOK",
                "GTX"
              ],
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            },
            "type": {
              "description": "Only LIMIT and MARKET are implemented.",
              "enum": [
                "LIMIT",
                "MARKET"
              ],
              "type": "string"
            }
          },
          "required": [
            "symbol",
            "side",
            "type",
            "quantity",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "side",
          "type",
          "quantity",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "TRADE"
      }
    },
    "/fapi/v1/ping": {
      "get": {
        "description": "",
        "operationId": "ping",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {},
                "schema": {
                  "$ref": "#/components/schemas/Empty"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Connectivity probe",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/positionSide/dual": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "position_mode",
        "parameters": [
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PositionMode"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "One-way position mode",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      },
      "post": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nTRADE permission is required.",
        "operationId": "change_position_mode",
        "parameters": [
          {
            "description": "String parameter. Only false succeeds; true returns -4061.",
            "in": "query",
            "name": "dualSidePosition",
            "required": false,
            "schema": {
              "enum": [
                "false",
                "true"
              ],
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "dualSidePosition": {
                    "description": "String parameter. Only false succeeds; true returns -4061.",
                    "enum": [
                      "false",
                      "true"
                    ],
                    "type": "string"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "code": 200,
                  "msg": "success"
                },
                "schema": {
                  "$ref": "#/components/schemas/Message"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Retain one-way mode, hedge mode is rejected",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "dualSidePosition": {
              "description": "String parameter. Only false succeeds; true returns -4061.",
              "enum": [
                "false",
                "true"
              ],
              "type": "string"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "dualSidePosition",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 1,
        "x-mariex-required-merged-parameters": [
          "dualSidePosition",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "TRADE"
      }
    },
    "/fapi/v1/premiumIndex": {
      "get": {
        "description": "With symbol, a missing oracle tick returns 503/-1008. Without symbol, symbols without ticks are omitted, so the array may be empty.",
        "operationId": "premium_index",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "estimatedSettlePrice": "25000.00000000",
                  "indexPrice": "25000.00000000",
                  "interestRate": "0.00010000",
                  "lastFundingRate": "0.00010000",
                  "markPrice": "25000.00000000",
                  "nextFundingTime": 1700028800000,
                  "symbol": "BTCUSDT",
                  "time": 1700000000000
                },
                "schema": {
                  "$ref": "#/components/schemas/PremiumResult"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Oracle marks, object with symbol or array without",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/ticker/24hr": {
      "get": {
        "description": "weightedAvgPrice, firstId and lastId are stubbed. Empty local history returns zeros.",
        "operationId": "ticker_24hr",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": [
                  {
                    "closeTime": 1700000000000,
                    "count": 0,
                    "firstId": 0,
                    "highPrice": "0.00",
                    "lastId": 0,
                    "lastPrice": "0.00",
                    "lastQty": "0",
                    "lowPrice": "0.00",
                    "openPrice": "0.00",
                    "openTime": 1700000000000,
                    "priceChange": "0.00",
                    "priceChangePercent": "0.000",
                    "quoteVolume": "0.00000",
                    "symbol": "BTCUSDT",
                    "volume": "0.000",
                    "weightedAvgPrice": "0"
                  }
                ],
                "schema": {
                  "$ref": "#/components/schemas/Ticker24Result"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Local rolling 24-hour statistics, object with symbol or array without",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/ticker/bookTicker": {
      "get": {
        "description": "",
        "operationId": "book_ticker",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BookTicker"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Unavailable market data, replay gate or server overload (-1008).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Best local bid and ask, symbol required",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/ticker/price": {
      "get": {
        "description": "",
        "operationId": "ticker_price",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PriceResult"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Latest local trade price, object with symbol or array without",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/time": {
      "get": {
        "description": "",
        "operationId": "server_time",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "serverTime": 1700000000000
                },
                "schema": {
                  "$ref": "#/components/schemas/ServerTime"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Server time in milliseconds",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/trades": {
      "get": {
        "description": "",
        "operationId": "recent_trades",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Values above 1000 are clamped to 1000.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 500,
              "minimum": 1,
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Trades"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [],
        "summary": "Recent local matches, oldest first within the selected window",
        "tags": [
          "Market data"
        ],
        "x-mariex-request-weight": 1,
        "x-mariex-security-type": "NONE"
      }
    },
    "/fapi/v1/userTrades": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "user_trades",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Values above 1000 are clamped to 1000.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 500,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "limit": {
                    "default": 500,
                    "description": "Values above 1000 are clamped to 1000.",
                    "minimum": 1,
                    "type": "integer"
                  },
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserTrades"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Persisted fills, may lag acknowledged commands",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "limit": {
              "default": 500,
              "description": "Values above 1000 are clamped to 1000.",
              "minimum": 1,
              "type": "integer"
            },
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "symbol",
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 5,
        "x-mariex-required-merged-parameters": [
          "symbol",
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v2/account": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "account",
        "parameters": [
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Account"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Live account totals and open positions with database fallback",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 5,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v2/balance": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "balance",
        "parameters": [
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Balances"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Live USDT balance with database fallback",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 5,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    },
    "/fapi/v2/positionRisk": {
      "get": {
        "description": "Requires X-MBX-APIKEY and per-request HMAC-SHA256. Send timestamp (milliseconds), optional recvWindow (default 5000, maximum 60000), and signature. Sign the exact raw query followed by the exact raw body, with NO inserted ampersand, excluding signature. Signature must be last in query or body. Query values take precedence over body values; the first duplicate in each location wins. Values are not percent-decoded. Timestamp must be less than serverTime + 1000 and serverTime - timestamp <= recvWindow. The API-key authorization field alone does not sign requests.\n\nParameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.\n\nUSER_DATA (READ) permission is required.",
        "operationId": "position_risk",
        "parameters": [
          {
            "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
            "in": "query",
            "name": "symbol",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Client epoch milliseconds checked against the receive window.",
            "in": "query",
            "name": "timestamp",
            "required": false,
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "description": "Receive window in milliseconds.",
            "in": "query",
            "name": "recvWindow",
            "required": false,
            "schema": {
              "default": 5000,
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
            "in": "query",
            "name": "signature",
            "required": false,
            "schema": {
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "properties": {
                  "recvWindow": {
                    "default": 5000,
                    "description": "Receive window in milliseconds.",
                    "maximum": 60000,
                    "minimum": 1,
                    "type": "integer"
                  },
                  "signature": {
                    "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
                    "pattern": "^[0-9a-fA-F]{64}$",
                    "type": "string"
                  },
                  "symbol": {
                    "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
                    "type": "string"
                  },
                  "timestamp": {
                    "description": "Client epoch milliseconds checked against the receive window.",
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "description": "Parameters may be in query, raw urlencoded body, or split across both. Required fields apply to the merged parameters, not independently to each location. Query parameters are marked optional to represent this alternative. GET bodies work at the server but many HTTP clients and proxies cannot send them; use query parameters for portable GET requests. Send the exact bytes you signed, without form re-encoding.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PositionRisks"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Parameter, authentication or Listen Key lifecycle failure. See the authored error reference for codes.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Credential permission or authority rejected.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Request-weight or account order budget exhausted (-1003).",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            },
            "description": "Internal or key-store failure (-1000); mutation outcome may be uncertain.",
            "headers": {
              "X-DP-ACCOUNT-USED-WEIGHT-1M": {
                "description": "Per-verified-Trading-Account admitted weight when authenticated.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              },
              "X-MBX-USED-WEIGHT-1M": {
                "description": "Per-IP admitted request weight in the current minute. Requests admitted by the limiter count even if authentication or validation later fails.",
                "schema": {
                  "format": "int64",
                  "type": "integer"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ],
        "summary": "Cross-margin positions and liquidation estimates",
        "tags": [
          "Trading and account"
        ],
        "x-mariex-merged-parameters-schema": {
          "properties": {
            "recvWindow": {
              "default": 5000,
              "description": "Receive window in milliseconds.",
              "maximum": 60000,
              "minimum": 1,
              "type": "integer"
            },
            "signature": {
              "description": "HMAC-SHA256 of exact raw query + body excluding signature; final parameter in query or body.",
              "pattern": "^[0-9a-fA-F]{64}$",
              "type": "string"
            },
            "symbol": {
              "description": "Listed symbol, for example BTCUSDT. Unlisted symbols return -1121.",
              "type": "string"
            },
            "timestamp": {
              "description": "Client epoch milliseconds checked against the receive window.",
              "format": "int64",
              "type": "integer"
            }
          },
          "required": [
            "timestamp",
            "signature"
          ],
          "type": "object"
        },
        "x-mariex-request-weight": 5,
        "x-mariex-required-merged-parameters": [
          "timestamp",
          "signature"
        ],
        "x-mariex-security-type": "USER_DATA"
      }
    }
  },
  "servers": [
    {
      "description": "Restricted Internal Paper Pilot. Availability requires separate release approval.",
      "url": "https://paper.mariex.com"
    }
  ],
  "x-mariex-source": {
    "availability": "restricted-internal-paper-pilot",
    "commit": "e8605e9fdcac8142ec9bfee00851650e90bc3a5f",
    "crateVersion": "0.1.0",
    "dirty": true,
    "publicationApproved": false,
    "release": null,
    "treeSha256": "95552e1bd85f07da8db557fdfe42d13780ea8a593968cb8232a68a8fafb8ee3b"
  }
}
