{"openapi":"3.1.0","info":{"title":"Ethereal Exchange API","description":"Ethereal HTTP API for real-time trading, order management, and market data access.\n\nFor more details, see [docs.ethereal.trade](https://docs.ethereal.trade).","contact":{},"version":"0.1.0"},"servers":[{"url":"https://api.etherealtest.net"}],"paths":{"/v1/funding":{"get":{"tags":["Funding"],"summary":"Returns a list funding rates for a product over a time period","operationId":"FundingController_listByProductId","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"productId","in":"query","description":"Id representing the registered product","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"range","in":"query","description":"The range of time of funding rates to retrieve","required":true,"schema":{"type":"string","enum":["DAY","WEEK","MONTH"],"example":"DAY"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfFundingDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/funding/projected":{"get":{"tags":["Funding"],"summary":"Returns the projected funding rate for a product","description":"Deprecated: Use GET /funding/projected-rate instead","operationId":"FundingController_getProjectedFundingRate","parameters":[{"name":"productId","in":"query","description":"Id representing the registered product","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectedFundingDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}},"deprecated":true}},"/v1/funding/projected-rate":{"get":{"tags":["Funding"],"summary":"Returns a list of projected funding rates for the given products","operationId":"FundingController_listProjectedRates","parameters":[{"name":"productIds","in":"query","description":"Array of product ids","required":true,"schema":{"type":"array","items":{"type":"string","format":"uuid"},"maxItems":50,"minItems":1,"uniqueItems":true}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfProjectedFundingDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer":{"get":{"tags":["LinkedSigner"],"summary":"List signers for a subaccount","operationId":"LinkedSignerController_listBySubaccountId","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccountId","in":"query","description":"Id representing the registered subaccount","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"statuses","in":"query","description":"Filters signers by statuses","required":false,"schema":{"type":"array","items":{"$ref":"#/components/schemas/LinkedSignerStatus"}}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt","expiresAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfSignersDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer/address/{address}":{"get":{"tags":["LinkedSigner"],"summary":"Returns a signer by its address","operationId":"LinkedSignerController_getSignerByAddress","parameters":[{"name":"address","in":"path","description":"Address of linked signer","required":true,"schema":{"type":"string","format":"hex","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignerDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer/extend":{"post":{"tags":["LinkedSigner"],"summary":"Extends the expiry of a linked signer (signed by the signer itself)","operationId":"LinkedSignerController_extendSigner","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExtendLinkedSignerDto"}}},"required":true},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignerDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer/link":{"post":{"tags":["LinkedSigner"],"summary":"Links a signer address with the sender address for order delegation","operationId":"LinkedSignerController_linkSigner","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkSignerDto"}}},"required":true},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignerDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer/quota":{"get":{"tags":["LinkedSigner"],"summary":"Returns the current signer config for a subaccount","operationId":"LinkedSignerController_getAccountQuota","parameters":[{"name":"subaccountId","in":"query","description":"Id representing the registered subaccount","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountSignerQuotaDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer/refresh":{"post":{"tags":["LinkedSigner"],"summary":"Refreshes the expiry of a linked signer (signed by EOA, supports expired signers)","operationId":"LinkedSignerController_refreshSigner","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefreshLinkedSignerDto"}}},"required":true},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignerDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer/revoke":{"delete":{"tags":["LinkedSigner"],"summary":"Revokes a signer address from a subaccount","operationId":"LinkedSignerController_revokeSigner","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeLinkedSignerDto"}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignerDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/linked-signer/{id}":{"get":{"tags":["LinkedSigner"],"summary":"Returns a signer by its id","operationId":"LinkedSignerController_getSigner","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignerDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/maintenance":{"get":{"tags":["Maintenance"],"summary":"Returns the current maintenance mode status","operationId":"MaintenanceController_isMaintenance","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MaintenanceDto"}}}}}}},"/v1/order":{"get":{"tags":["Order"],"summary":"Returns a filtered array of orders by the subaccount","operationId":"OrderController_listBySubaccountId","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccountId","in":"query","description":"Id of the subaccount to query for","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"clientOrderId","in":"query","description":"Client-generated order id to query for (either a valid UUID or alphanumeric string up to 32 characters)","required":false,"schema":{"type":"string"}},{"name":"productIds","in":"query","description":"Array of product ids to filter for","required":false,"schema":{"type":"array","items":{"type":"string","format":"uuid"},"minItems":1,"uniqueItems":true}},{"name":"createdAfter","in":"query","description":"Filter by orders created after timestamp exclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}},{"name":"createdBefore","in":"query","description":"Filter by orders created before timestamp inclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}},{"name":"side","in":"query","description":"Side of the order to filter for","required":false,"schema":{"$ref":"#/components/schemas/OrderSide"}},{"name":"close","in":"query","description":"Whether the order is a position close order","required":false,"schema":{"type":"boolean"}},{"name":"stopTypes","in":"query","description":"Array of StopTypes to filter by","required":false,"deprecated":true,"schema":{"type":"array","items":{"$ref":"#/components/schemas/StopType"}}},{"name":"isWorking","in":"query","description":"Filter by orders that are working: NEW, FILLED_PARTIAL","required":false,"schema":{"type":"boolean","enum":[true],"example":true}},{"name":"isPending","in":"query","description":"Filter by orders that are PENDING","required":false,"schema":{"type":"boolean","enum":[true],"example":true}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfOrderDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}},"post":{"tags":["Order"],"summary":"Place an order for trading","operationId":"OrderController_submit","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitOrderDto"}}},"required":true},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitOrderCreatedDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Order was created but rejected","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitOrderFailedDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/order/cancel":{"post":{"tags":["Order"],"summary":"Cancels one or more orders given an array of order ids","operationId":"OrderController_cancel","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CancelOrderDto"}}},"required":true},"responses":{"202":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListOfCancelOrderResultDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/order/dry-run":{"post":{"tags":["Order"],"summary":"Submits a dry-mode to simulate an order submission","operationId":"OrderController_dryRun","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitDryOrderDto"}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DryRunOrderCreatedDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DryRunOrderFailedUnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/order/fill":{"get":{"tags":["Order"],"summary":"Returns a filtered array of order fills","operationId":"OrderController_listFillsBySubaccountId","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccountId","in":"query","description":"Id of the subaccount to filter fills by","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"productIds","in":"query","description":"Array of product ids to filter for","required":false,"schema":{"type":"array","items":{"type":"string","format":"uuid"},"minItems":1,"uniqueItems":true}},{"name":"createdAfter","in":"query","description":"Filter by order fills created before timestamp exclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}},{"name":"createdBefore","in":"query","description":"Filter by order fills created before timestamp inclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}},{"name":"side","in":"query","description":"Side of the maker as either BUY (0) or SELL (1)","required":false,"schema":{"$ref":"#/components/schemas/OrderSide"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["productId","filled","price","createdAt"],"example":"productId"}},{"name":"includeSelfTrades","in":"query","description":"Explicitly include self trades (excluded by default)","required":false,"schema":{"type":"boolean","default":false}},{"name":"expandSelfTrades","in":"query","description":"When true and includeSelfTrades is also true, returns both maker and taker perspectives for self-trades as separate rows.","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfOrderFillDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/order/trade":{"get":{"tags":["Order"],"summary":"Returns a filtered array of trades","operationId":"OrderController_listTrades","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"productId","in":"query","description":"Id of the product to filter trades by","required":true,"schema":{"type":"string","format":"uuid","example":"1b67d5b3-9dc7-4410-bc9c-7fd23ebd32ee"}},{"name":"orderBy","in":"query","description":"Order by fields","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfTradeDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/order/{id}":{"get":{"tags":["Order"],"summary":"Returns an order by their id","operationId":"OrderController_getById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/order/{id}/group":{"get":{"tags":["Order"],"summary":"Returns all orders in the same contingency group as the specified order","operationId":"OrderController_listGroupByOrderId","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfOrderDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/points":{"get":{"tags":["Points"],"summary":"Returns a list of points periods for a given address and season","operationId":"PointsController_listPointsPeriods","parameters":[{"name":"address","in":"query","description":"Address of account","required":true,"schema":{"type":"string","format":"hex","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"}},{"name":"season","in":"query","description":"Season number","required":true,"schema":{"type":"integer","example":1,"maximum":10,"minimum":0}},{"name":"epoch","in":"query","description":"Epoch number within the season","required":true,"schema":{"type":"integer","example":1,"maximum":256,"minimum":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListOfPointsPeriodDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/points/summary":{"get":{"tags":["Points"],"summary":"Returns a list of points season summaries for a given address","operationId":"PointsController_listPointsSeasonSummaries","parameters":[{"name":"address","in":"query","description":"Address of account","required":true,"schema":{"type":"string","format":"hex","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListOfPointsSeasonSummariesDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/points/total":{"get":{"tags":["Points"],"summary":"Returns total exchange-wide points distributed","operationId":"PointsController_getTotalPoints","parameters":[{"name":"season","in":"query","description":"Season number","required":false,"schema":{"type":"integer","example":1,"maximum":10,"minimum":0}},{"name":"epoch","in":"query","description":"Epoch number within season","required":false,"schema":{"type":"integer","example":1,"maximum":256,"minimum":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TotalPointsDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/position":{"get":{"tags":["Position"],"summary":"Returns a filtered list of positions for a given subaccount","operationId":"PositionController_listBySubaccountId","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccountId","in":"query","description":"Id representing the registered subaccount","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"productIds","in":"query","description":"Array of product ids to filter for","required":false,"schema":{"type":"array","items":{"type":"string","format":"uuid"},"minItems":1,"uniqueItems":true}},{"name":"open","in":"query","description":"Include or exclude open positions (i.e. non-zero size)","required":false,"schema":{"type":"boolean","example":true}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["size","createdAt","updatedAt","realizedPnl"],"example":"size"}},{"name":"createdAfter","in":"query","description":"Filter by order fills created before timestamp exclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}},{"name":"createdBefore","in":"query","description":"Filter by order fills created before timestamp inclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}},{"name":"side","in":"query","description":"Side as either BUY (0) or SELL (1)","required":false,"schema":{"$ref":"#/components/schemas/OrderSide"}},{"name":"isLiquidated","in":"query","description":"Filter by liquidated positions","required":false,"schema":{"type":"boolean","example":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfPositionDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/position/active":{"get":{"tags":["Position"],"summary":"Returns the active position for a subaccount and product","operationId":"PositionController_getActive","parameters":[{"name":"subaccountId","in":"query","description":"Id representing the registered subaccount","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"productId","in":"query","description":"Id of product to filter position by","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PositionDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/position/fill":{"get":{"tags":["Position"],"summary":"Returns a filtered list of fills for a given position","operationId":"PositionController_listFillsByPositionId","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"positionId","in":"query","description":"Id of the position to filter fills by","required":true,"schema":{"type":"string","format":"uuid","example":"81215694-2d9f-4a87-af57-a710118938c0"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["price","filled","createdAt"],"example":"price"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfPositionFillDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/position/liquidation":{"get":{"tags":["Position"],"summary":"Returns a list of liquidations","operationId":"PositionController_listLiquidationsBySubaccountId","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfPositionLiquidationsDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/position/{id}":{"get":{"tags":["Position"],"summary":"Returns position by id","operationId":"PositionController_getById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PositionDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/product":{"get":{"tags":["Product"],"summary":"Returns a list of all products and its configuration","operationId":"ProductController_list","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt","openInterest","baseTokenName","quoteTokenName"],"example":"createdAt"}},{"name":"ticker","in":"query","description":"Filter products by ticker (alphanumeric and case insensitive)","required":false,"schema":{"type":"string","example":"ETHUSD","pattern":"^[a-zA-Z0-9]{1,16}$"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfProductDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/product/market-liquidity":{"get":{"tags":["Product"],"summary":"Returns the product market liquidity by id","operationId":"ProductController_getMarketLiquidity","parameters":[{"name":"productId","in":"query","description":"Id representing the registered product","required":true,"schema":{"type":"string","format":"uuid","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketLiquidityDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/product/market-price":{"get":{"tags":["Product"],"summary":"Returns the product prices for an array of product ids","operationId":"ProductController_getMarketPrice","parameters":[{"name":"productIds","in":"query","description":"Array of product ids","required":true,"schema":{"type":"array","items":{"type":"string","format":"uuid"},"maxItems":50,"minItems":1,"uniqueItems":true}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListOfMarketPriceDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/product/{id}":{"get":{"tags":["Product"],"summary":"Returns product by id","operationId":"ProductController_getById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/rate-limit/config":{"get":{"tags":["RateLimit"],"summary":"Returns rate limit configurations for all endpoints","operationId":"RateLimitController_getConfig","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RateLimitConfigResponseDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/referral":{"get":{"tags":["Referral"],"summary":"Returns paginated list of referrals for the sender","operationId":"ReferralController_listReferrals","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccount","in":"query","description":"Bytes32 encoded subaccount name (0x prefix, zero padded, set when using linked signer)","required":false,"schema":{"type":"string","format":"hex","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}},{"name":"X-Ethereal-Auth","in":"header","description":"Must be: EIP712Auth","required":true,"schema":{"type":"string"}},{"name":"X-Ethereal-Sender","in":"header","description":"Address that signed this message","required":true,"schema":{"type":"string","format":"hex"}},{"name":"X-Ethereal-Signature","in":"header","description":"Hex-encoded EIP-712 signature authorizing this request","required":true,"schema":{"type":"string","format":"hex"}},{"name":"X-Ethereal-Intent","in":"header","description":"Intent of the message (action to be taken)","required":true,"schema":{"type":"number","enum":[0,1,2,3]}},{"name":"X-Ethereal-SignedAt","in":"header","description":"Message signedAt current timestamp (seconds since Unix Epoch)","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfReferralDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/referral/activate":{"post":{"tags":["Referral"],"summary":"Activates the sender to acquire a referral code","operationId":"ReferralController_activate","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivateReferralDto"}}},"required":true},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferralDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/referral/claim":{"post":{"tags":["Referral"],"summary":"Claim a referral code","operationId":"ReferralController_claimCode","parameters":[],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimReferralCodeDto"}}},"required":true},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferralDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/referral/code/{code}":{"get":{"tags":["Referral"],"summary":"Returns referral code usage details","operationId":"ReferralController_getCodeUsage","parameters":[{"name":"code","in":"path","description":"Referral code (3-12 alphanumeric uppercase characters)","required":true,"schema":{"type":"string","example":"XYZ123456789","maxLength":12,"minLength":12,"pattern":"/^[A-Z0-9]+$/"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferralCodeUsageDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/referral/summary":{"get":{"tags":["Referral"],"summary":"Returns summary of your referral activity","operationId":"ReferralController_getSummary","parameters":[{"name":"subaccount","in":"query","description":"Bytes32 encoded subaccount name (0x prefix, zero padded, set when using linked signer)","required":false,"schema":{"type":"string","format":"hex","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"}},{"name":"X-Ethereal-Auth","in":"header","description":"Must be: EIP712Auth","required":true,"schema":{"type":"string"}},{"name":"X-Ethereal-Sender","in":"header","description":"Address that signed this message","required":true,"schema":{"type":"string","format":"hex"}},{"name":"X-Ethereal-Signature","in":"header","description":"Hex-encoded EIP-712 signature authorizing this request","required":true,"schema":{"type":"string","format":"hex"}},{"name":"X-Ethereal-Intent","in":"header","description":"Intent of the message (action to be taken)","required":true,"schema":{"type":"number","enum":[0,1,2,3]}},{"name":"X-Ethereal-SignedAt","in":"header","description":"Message signedAt current timestamp (seconds since Unix Epoch)","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferralDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/rpc/config":{"get":{"tags":["Rpc"],"summary":"Returns the EIP712 domain data necessary for message signing","operationId":"RpcController_getConfig","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RpcConfigDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/subaccount":{"get":{"tags":["Subaccount"],"summary":"Returns subaccounts for the given account","operationId":"SubaccountController_listByAccount","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"name","in":"query","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","required":false,"schema":{"type":"string","format":"hex"}},{"name":"sender","in":"query","description":"Address of the subaccount wallet","required":true,"schema":{"type":"string","format":"hex"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt","name"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfSubaccountDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/subaccount/all":{"get":{"tags":["Subaccount"],"summary":"Returns all subaccounts","operationId":"SubaccountController_list","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfSubaccountDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/subaccount/balance":{"get":{"tags":["Subaccount"],"summary":"Returns subaccount balances for given subaccount","operationId":"SubaccountController_listSubaccountBalances","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccountId","in":"query","description":"Id representing the registered subaccount","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["tokenName","updatedAt","amount"],"example":"tokenName"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfSubaccountBalanceDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/subaccount/{id}":{"get":{"tags":["Subaccount"],"summary":"Returns subaccount by id","operationId":"SubaccountController_getBySubaccountId","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubaccountDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/time":{"get":{"tags":["Time"],"summary":"Returns current system time in milliseconds via GET","operationId":"TimeController_getSystemTime","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SystemTimeDto"}}}}}},"post":{"tags":["Time"],"summary":"Returns current system time in milliseconds via POST","operationId":"TimeController_postSystemTime","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SystemTimeDto"}}}}}}},"/v1/token":{"get":{"tags":["Token"],"summary":"Returns a list of all tokens","operationId":"TokenController_list","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"depositEnabled","in":"query","description":"Filters tokens by if its enabled for deposit","required":false,"schema":{"type":"boolean","example":true}},{"name":"withdrawEnabled","in":"query","description":"Filters tokens by if its enabled for withdraw","required":false,"schema":{"type":"boolean","example":true}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfTokensDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/token/transfer":{"get":{"tags":["Token"],"summary":"Returns a list of transfers for the given subaccount","operationId":"TokenController_listTransfers","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccountId","in":"query","description":"Id representing the registered subaccount","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"statuses","in":"query","description":"Array of transfer statuses to filter by","required":false,"schema":{"type":"array","items":{"type":"string","enum":["SUBMITTED","PENDING","COMPLETED","REJECTED"]},"example":"COMPLETED","uniqueItems":true}},{"name":"types","in":"query","description":"Array of transfer types to filter by","required":false,"schema":{"type":"array","items":{"$ref":"#/components/schemas/TransferType"}}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}},{"name":"createdAfter","in":"query","description":"Filter by transfers created after timestamp exclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}},{"name":"createdBefore","in":"query","description":"Filter by transfers created before timestamp inclusive (ms since Unix epoch)","required":false,"schema":{"type":"integer"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfTransfersDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/token/withdraw":{"get":{"tags":["Token"],"summary":"Returns initiated or pending finalize withdraws for the given subaccount","operationId":"TokenController_listWithdraws","parameters":[{"name":"order","in":"query","description":"Direction to paginate through objects","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"limit","in":"query","description":"Limit the number of objects to return","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Pointer to the current object in pagination dataset","required":false,"schema":{"type":"string"}},{"name":"subaccountId","in":"query","description":"Id representing the registered subaccount","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"isActive","in":"query","description":"Filters active withdraws","required":false,"schema":{"type":"boolean","example":true}},{"name":"orderBy","in":"query","description":"Order by field","required":false,"schema":{"type":"string","enum":["createdAt"],"example":"createdAt"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PageOfWithdrawDtos"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/token/{id}":{"get":{"tags":["Token"],"summary":"Returns a token by its id","operationId":"TokenController_getById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/token/{id}/withdraw":{"post":{"tags":["Token"],"summary":"Initiates a withdraw for a specific token in subaccount","operationId":"TokenController_initiateWithdraw","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InitiateWithdrawDto"}}},"required":true},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WithdrawDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WithdrawFailedDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}},"/v1/whitelist":{"get":{"tags":["Whitelist"],"summary":"Checks if an address is whitelisted","operationId":"WhitelistController_isWhitelisted","parameters":[{"name":"address","in":"query","description":"Address of account","required":true,"schema":{"type":"string","format":"hex","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WhitelistDto"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestDto"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedDto"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenDto"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundDto"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityDto"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsDto"}}}},"500":{"description":"Internal Server Error"}}}}},"components":{"schemas":{"AccountSignerQuotaDto":{"type":"object","required":["maxLinkedSignersPeriodDays","maxLinkedSignersInPeriod","linkedSignersUsedInPeriod","linkedSignerRefreshHoursBeforeExpiry"],"properties":{"linkedSignerRefreshHoursBeforeExpiry":{"type":"integer","description":"Hours before expiry when a signer can be refreshed","example":48},"linkedSignersUsedInPeriod":{"type":"integer","description":"Number of signers linked within current ratelimit period","example":2},"maxLinkedSignersInPeriod":{"type":"integer","description":"Max number of signers that can be linked within ratelimit period","example":10},"maxLinkedSignersPeriodDays":{"type":"integer","description":"Ratelimit period in days for linking signers per account","example":7}}},"ActivateReferralDto":{"type":"object","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/ActivateReferralDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}}},"ActivateReferralDtoData":{"type":"object","required":["sender","intent","signedAt","subaccount"],"properties":{"intent":{"allOf":[{"$ref":"#/components/schemas/EIP712AuthIntent"}],"description":"Intent of the message (action to be taken)","example":0},"sender":{"type":"string","format":"hex","description":"Account address that produced the authorizing signature","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"signedAt":{"type":"integer","description":"Message signedAt current timestamp (seconds since Unix Epoch)","example":1712019600},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"}}},"BadRequestDto":{"type":"object","required":["statusCode","error","message"],"properties":{"error":{"type":"string","enum":["Bad Request"]},"message":{"type":"string"},"statusCode":{"type":"integer","format":"uint16","enum":[400]}}},"CancelOrderDto":{"type":"object","description":"Cancel order request containing signature and cancel data","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/CancelOrderDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}},"additionalProperties":false},"CancelOrderDtoData":{"type":"object","required":["sender","subaccount","nonce"],"properties":{"clientOrderIds":{"type":"array","items":{"type":"string"},"description":"Client order IDs to cancel (UUIDs or alphanumeric up to 32 chars)","maxItems":200,"uniqueItems":true},"nonce":{"type":"string","description":"Unique nonce for this request (nanoseconds since Unix epoch)","example":"1712019600000000000"},"orderIds":{"type":"array","items":{"type":"string","format":"uuid"},"description":"Order IDs to cancel (UUIDs)","maxItems":200,"uniqueItems":true},"sender":{"type":"string","format":"hex","description":"Address that signed this message","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"}},"additionalProperties":false},"CancelOrderResultCode":{"type":"string","enum":["Ok","NotFound","AlreadyCanceled","AlreadyFilled","AlreadyExpired","NonceAlreadyUsed","Unknown"],"example":"Ok"},"CancelOrderResultDto":{"type":"object","description":"Individual cancel result for each order","required":["id","result"],"properties":{"clientOrderId":{"type":["string","null"],"description":"Client order ID (if order was found by clientOrderIds)"},"id":{"type":"string","format":"uuid","description":"Order ID (if order was found by orderIds)"},"result":{"$ref":"#/components/schemas/CancelOrderResultCode","description":"Result code for this cancelation"}},"example":{"id":"123e4567-e89b-12d3-a456-426614174000","result":"Ok"}},"ClaimReferralCodeDto":{"type":"object","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/ClaimReferralCodeDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}}},"ClaimReferralCodeDtoData":{"type":"object","required":["sender","intent","signedAt","code"],"properties":{"code":{"type":"string","description":"The referral code to claim","example":"XYZ123456789","maxLength":12,"minLength":12,"pattern":"/^[A-Z0-9]+$/"},"intent":{"allOf":[{"$ref":"#/components/schemas/EIP712AuthIntent"}],"description":"Intent of the message (action to be taken)","example":0},"sender":{"type":"string","format":"hex","description":"Account address that produced the authorizing signature","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"signedAt":{"type":"integer","description":"Message signedAt current timestamp (seconds since Unix Epoch)","example":1712019600}}},"DomainTypeDto":{"type":"object","required":["name","version","chainId","verifyingContract"],"properties":{"chainId":{"type":"integer","description":"The EIP-155 chain id"},"name":{"type":"string","description":"Name of signing domain"},"verifyingContract":{"type":"string","format":"hex","description":"Address of the contract that will verify the signature"},"version":{"type":"string","description":"Current major version of the signing domain"}}},"DryRunOrderCreatedDto":{"type":"object","required":["marginRequired","marginAvailable","totalUsedMargin","riskUsed","riskAvailable","code"],"properties":{"code":{"allOf":[{"$ref":"#/components/schemas/SubmitOrderCreatedResultCode"}],"description":"Code indicating a result of the dry run","example":"Ok"},"marginAvailable":{"type":"string","format":"decimal","description":"Margin available excluding this order in USD expressed as a decimal (precision: 9)","example":"5000.75"},"marginRequired":{"type":"string","format":"decimal","description":"Margin required for order in USD expressed as a decimal (precision: 9)","example":"1000.5"},"riskAvailable":{"type":"string","format":"decimal","description":"Risk available for the product in USD expressed as a decimal (precision: 9)","example":"100000000"},"riskUsed":{"type":"string","format":"decimal","description":"Risk used including position and open orders in USD expressed as a decimal (precision: 9)","example":"3000.25"},"totalUsedMargin":{"type":"string","format":"decimal","description":"Total used margin including this order in USD expressed as a decimal (precision: 9)","example":"3000.25"}}},"DryRunOrderFailedDto":{"type":"object","required":["marginRequired","marginAvailable","totalUsedMargin","riskUsed","riskAvailable","code"],"properties":{"code":{"allOf":[{"$ref":"#/components/schemas/SubmitOrderFailedResultCode"}],"description":"Code indicating the reason for failure","example":"TooManyOpenOrders"},"marginAvailable":{"type":"string","format":"decimal","description":"Margin available excluding this order in USD expressed as a decimal (precision: 9)","example":"5000.75"},"marginRequired":{"type":"string","format":"decimal","description":"Margin required for order in USD expressed as a decimal (precision: 9)","example":"1000.5"},"riskAvailable":{"type":"string","format":"decimal","description":"Risk available for the product in USD expressed as a decimal (precision: 9)","example":"100000000"},"riskUsed":{"type":"string","format":"decimal","description":"Risk used including position and open orders in USD expressed as a decimal (precision: 9)","example":"3000.25"},"totalUsedMargin":{"type":"string","format":"decimal","description":"Total used margin including this order in USD expressed as a decimal (precision: 9)","example":"3000.25"}}},"DryRunOrderFailedUnprocessableEntityDto":{"type":"object","required":["statusCode","message","error","data"],"properties":{"data":{"allOf":[{"$ref":"#/components/schemas/DryRunOrderFailedDto"}],"description":"Details of the failed dry run"},"error":{"type":"string","default":"Unprocessable Entity","enum":["Unprocessable Entity"]},"message":{"allOf":[{"$ref":"#/components/schemas/SubmitOrderFailedResultCode"}],"description":"Code indicating the reason for failure","example":"TooManyOpenOrders"},"statusCode":{"type":"number","default":422,"enum":[422]}}},"EIP712AuthIntent":{"type":"number","description":"Intent of the message (action to be taken)","enum":[0,1,2,3],"x-enumNames":["REFERRAL_ACTIVATION","REFERRAL_CLAIM","REFERRAL_READ","POINTS_READ"]},"EngineType":{"type":"integer","enum":[0,1],"x-enum-varnames":["PERP","SPOT"]},"ExtendLinkedSignerDto":{"type":"object","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/ExtendLinkedSignerDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}}},"ExtendLinkedSignerDtoData":{"type":"object","required":["sender","nonce","signedAt"],"properties":{"nonce":{"type":"string","description":"Message nonce timestamp (nanoseconds since Unix Epoch)","example":"2687929537462333"},"sender":{"type":"string","format":"hex","description":"Address of the linked signer extending itself","example":"0x1Db3439a222C519ab44bb1144fC28167b4Fa6EE6"},"signedAt":{"type":"integer","description":"Message signedAt current timestamp (seconds since Unix Epoch)","example":1712019600}}},"ForbiddenDto":{"type":"object","required":["statusCode","error","message"],"properties":{"error":{"type":"string","enum":["Forbidden"]},"message":{"type":"string"},"statusCode":{"type":"integer","format":"uint16","enum":[403]}}},"FundingDto":{"type":"object","required":["createdAt","fundingRate1h"],"properties":{"createdAt":{"type":"integer","description":"Funding charge timestamp (ms since Unix Epoch)","example":1712019600000},"fundingRate1h":{"type":"string","description":"Hourly funding rate","example":"0.013876480"}}},"GroupContingencyType":{"type":"integer","enum":[0,1],"x-enum-varnames":["OTO","OCO"]},"HttpFixedRateLimitEndpointDto":{"type":"object","required":["method","path","protocol","type","fixedPoints"],"properties":{"fixedPoints":{"type":"number","description":"Fixed points consumed per request","example":5},"method":{"type":"string","description":"HTTP method","enum":["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD"]},"path":{"type":"string","description":"API endpoint path","example":"/v1/order/"},"protocol":{"type":"string","description":"Protocol","enum":["HTTP"]},"type":{"type":"string","description":"Endpoint type (either PAGINATED or FIXED)","enum":["FIXED"]}}},"HttpPaginatedRateLimitEndpointDto":{"type":"object","required":["method","path","protocol","type","basePoints","pointsPerRow"],"properties":{"basePoints":{"type":"number","description":"Base points consumed per request","example":1},"method":{"type":"string","description":"HTTP method","enum":["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD"]},"path":{"type":"string","description":"API endpoint path","example":"/v1/order/"},"pointsPerRow":{"type":"number","description":"Points consumed per row in paginated response","example":1},"protocol":{"type":"string","description":"Protocol","enum":["HTTP"]},"type":{"type":"string","description":"Endpoint type (either PAGINATED or FIXED)","enum":["PAGINATED"]}}},"InitiateWithdrawDto":{"type":"object","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/InitiateWithdrawDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}}},"InitiateWithdrawDtoData":{"type":"object","required":["account","subaccount","token","amount","lzDestinationAddress","lzDestinationEid","nonce","signedAt"],"properties":{"account":{"type":"string","format":"hex","description":"Account address to withdraw from","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"amount":{"type":"string","format":"decimal","description":"Amount to withdraw in native units expressed as a decimal (precision: 9)","example":"1337.42"},"lzDestinationAddress":{"type":"string","format":"hex","description":"Bytes32 encoded LayerZero destination address (with 0x prefix, left zero padded)","example":"0x000000000000000000000000d8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"lzDestinationEid":{"allOf":[{"$ref":"#/components/schemas/LayerZeroEndpointId"}],"description":"LayerZero destination endpoint ID for the transfer (zero if not bridging)","example":40231},"nonce":{"type":"string","description":"Message nonce timestamp (nanoseconds since Unix Epoch)","example":"2687929537462333"},"signedAt":{"type":"integer","description":"Message signedAt current timestamp (seconds since Unix Epoch)","example":1712019600},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"token":{"type":"string","format":"hex","description":"Address of token to be withdrawn","example":"0x4c9EDD5852cd905f086C759E8383e09bff1E68B3"}}},"LayerZeroEndpointId":{"type":"number","description":"LayerZero destination endpoint ID for the transfer (zero if not bridging)","enum":[0,40422,40231,40161,30391,30110,30101],"x-enumNames":["NONE","ETHEREAL_TESTNET","ARBITRUM_SEPOLIA","ETHEREUM_SEPOLIA","ETHEREAL_MAINNET","ARBITRUM_MAINNET","ETHEREUM_MAINNET"]},"LinkSignerDto":{"type":"object","required":["signature","signerSignature","data"],"properties":{"data":{"$ref":"#/components/schemas/LinkSignerDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"},"signerSignature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}}},"LinkSignerDtoData":{"type":"object","required":["subaccountId","sender","subaccount","signer","nonce","signedAt"],"properties":{"category":{"type":"string","description":"Category of the linked signer: TRADE_SESSION or API","enum":["TRADE_SESSION","API"],"example":"TRADE_SESSION"},"name":{"type":"string","description":"Optional name for the linked signer","example":"Delegated signer","maxLength":32,"minLength":1},"nonce":{"type":"string","description":"Message nonce timestamp (nanoseconds since Unix Epoch)","example":"2687929537462333"},"sender":{"type":"string","format":"hex","description":"Account address that produced the authorizing signature","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"signedAt":{"type":"integer","description":"Message signedAt current timestamp (seconds since Unix Epoch)","example":1712019600},"signer":{"type":"string","format":"hex","description":"Address of signer to allowed for delegated signing","example":"0x1Db3439a222C519ab44bb1144fC28167b4Fa6EE6"},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"subaccountId":{"type":"string","format":"uuid","description":"Id representing the registered subaccount","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"}}},"LinkedSignerStatus":{"type":"string","enum":["PENDING","ACTIVE","PENDING_REVOKE","REVOKED","REJECTED"]},"ListOfCancelOrderResultDtos":{"type":"object","description":"Response returned when cancel request is processed","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CancelOrderResultDto"},"description":"Results for each order cancelation attempt"}}},"ListOfMarketPriceDtos":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/MarketPriceDto"},"description":"Array of market price objects"}}},"ListOfPointsPeriodDtos":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PointsPeriodDto"},"description":"Array of points period objects"}}},"ListOfPointsSeasonSummariesDtos":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PointsSeasonSummaryDto"},"description":"Array of points season summary objects"}}},"MaintenanceDto":{"type":"object","required":["isEnabled"],"properties":{"isEnabled":{"type":"boolean","description":"Whether the maintenance mode is enabled","example":true}}},"MarketLiquidityDto":{"type":"object","required":["timestamp","productId","asks","bids"],"properties":{"asks":{"type":"array","items":{"type":"array","items":{"type":"string","additionalProperties":false},"maxItems":2,"minItems":2},"description":"An array of ask tuple pairs (price, quantity) ordered in asc","example":[["4200.69","1337.420"]]},"bids":{"type":"array","items":{"type":"array","items":{"type":"string","additionalProperties":false},"maxItems":2,"minItems":2},"description":"An array of bid tuple pairs (price, quantity) ordered in desc","example":[["4199.42","420.55"]]},"previousTimestamp":{"type":"integer","description":"Previous book update, undefined if never updated (ms since Unix Epoch)","example":1731664105881},"productId":{"type":"string","format":"uuid","description":"Id representing the product","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"timestamp":{"type":"integer","description":"Most recent book update, created timestamp if never updated (ms since Unix Epoch)","example":1731664105881}}},"MarketPriceDto":{"type":"object","required":["productId"],"properties":{"bestAskPrice":{"type":"string","format":"decimal","description":"Best ask price in USD expressed as a decimal (precision: 9)","example":"104400.1"},"bestBidPrice":{"type":"string","format":"decimal","description":"Best bid price in USD expressed as a decimal (precision: 9)","example":"104399.65"},"oraclePrice":{"type":"string","format":"decimal","description":"Oracle price in USD expressed as a decimal (precision: 9)","example":"104399.7"},"price24hAgo":{"type":"string","format":"decimal","description":"Price of product 24hrs ago in USD expressed as a decimal (precision: 9)","example":"101228.38"},"productId":{"type":"string","format":"uuid","description":"Id representing the registered product","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"}}},"NotFoundDto":{"type":"object","required":["statusCode","error","message"],"properties":{"error":{"type":"string","enum":["Not Found"]},"message":{"type":"string"},"statusCode":{"type":"integer","format":"uint16","enum":[404]}}},"OrderDto":{"type":"object","required":["id","type","availableQuantity","quantity","side","productId","subaccountId","status","reduceOnly","close","updatedAt","createdAt","sender","price","filled","stopPrice","expiresAt","triggered"],"properties":{"availableQuantity":{"type":"string","format":"decimal","description":"Remaining quantity (if modified or reduced) in native units expressed as a decimal (precision: 9)","example":"10.5"},"clientOrderId":{"type":"string","description":"A subaccount scoped unique client-generated order id (either a UUID or alphanumeric string up to 32 characters)","example":"28850555-0968-44ca-bdee-b51e286656d9"},"close":{"type":"boolean","description":"Order closes the entire current position"},"createdAt":{"type":"integer","description":"Order creation timestamp (ms since Unix Epoch)","example":1712019600000},"expiresAt":{"type":"integer","description":"Order expiry timestamp (seconds since Unix Epoch)","example":1712019600},"filled":{"type":"string","format":"decimal","description":"Filled amount in native units expressed as a decimal (precision: 9)","example":"0.5"},"groupContingencyType":{"allOf":[{"$ref":"#/components/schemas/GroupContingencyType"}],"description":"Type of OTOCO relationship (OTO or OCO)","example":0},"groupId":{"type":"string","format":"uuid","description":"Id of the group this order belongs to","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"id":{"type":"string","format":"uuid","description":"Id representing the order","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"postOnly":{"type":"boolean","description":"Only add order if it does not immediately fill (limit only)","example":true},"price":{"type":"string","format":"decimal","description":"Limit price in native units expressed as a decimal, zero if market order (precision: 9)","example":"4200.5"},"productId":{"type":"string","format":"uuid","description":"Id of product this order was placed against","example":"9c6bf870-a8ce-4de3-820b-542fd5c049ba"},"quantity":{"type":"string","format":"decimal","description":"Original quantity (as per order submission) in native units expressed as a decimal (precision: 9)","example":"10.5"},"reduceOnly":{"type":"boolean","description":"Indicates if the order is reduce only","example":true},"sender":{"type":"string","format":"hex","description":"Account or linked signer address that placed this order","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"side":{"allOf":[{"$ref":"#/components/schemas/OrderSide"}],"description":"Side as either BUY (0) or SELL (1)","example":1},"status":{"type":"string","description":"Status of the order","enum":["NEW","PENDING","FILLED_PARTIAL","FILLED","REJECTED","CANCELED","EXPIRED"],"example":"FILLED"},"stopPrice":{"type":"string","format":"decimal","description":"Stop price expressed as a decimal (zero if not a stop order, precision: 9)","example":"4200.5"},"stopPriceType":{"allOf":[{"$ref":"#/components/schemas/StopPriceType"}],"description":"Type of stop price (stop orders only)","example":1},"stopType":{"allOf":[{"$ref":"#/components/schemas/StopType"}],"description":"Stop type, either GAIN (0) for take-profit or LOSS (1) for stop-loss","example":1},"subaccountId":{"type":"string","format":"uuid","description":"Id of the subaccount associated to order","example":"c25c39d9-ce2b-4753-960c-c5ad558aace8"},"timeInForce":{"type":"string","description":"How long an order will remain until executed/expired (required if limit)","enum":["GTD","IOC","FOK"],"example":"GTD"},"triggered":{"type":"string","description":"Indicates order trigger conditions which have or have not been met: NOT_TRIGGERED (waiting for stop/OTO condition), TRIGGERED (immediately active), STOP_ORDER_TRIGGERED (stop price condition met), OCO_ORDER_TRIGGERED (canceled because OCO sibling filled), OTO_ORDER_TRIGGERED (activated by OTO parent filling)","enum":["NOT_TRIGGERED","TRIGGERED","STOP_ORDER_TRIGGERED","OCO_ORDER_TRIGGERED","OTO_ORDER_TRIGGERED"],"example":"TRIGGERED"},"type":{"type":"string","description":"Trade order type e.g. MARKET or LIMIT","enum":["MARKET","LIMIT"],"example":"LIMIT"},"updatedAt":{"type":"integer","description":"Order last updated timestamp (ms since Unix Epoch)","example":1712019600000}}},"OrderFillDto":{"type":"object","required":["id","orderId","price","filled","type","side","reduceOnly","feeUsd","isMaker","productId","subaccountId","createdAt"],"properties":{"clientOrderId":{"type":"string","description":"A subaccount scoped unique client-generated order id (either a UUID or alphanumeric string up to 32 characters)","example":"b1234567-89ab-cdef-0123-456789abcdef"},"createdAt":{"type":"integer","description":"Fill creation timestamp (ms since Unix Epoch)","example":1712019600000},"feeUsd":{"type":"string","format":"decimal","description":"The provided subaccount's charged fee in USD expressed as a decimal (precision: 9)","example":"3.049563"},"filled":{"type":"string","format":"decimal","description":"Quantity filled in native units expressed as a decimal (precision: 9)","example":"2.420"},"id":{"type":"string","format":"uuid","description":"Id of the fill","example":"b1234567-89ab-cdef-0123-456789abcdef"},"isMaker":{"type":"boolean","description":"Indicates if the fill was a maker or taker","example":true},"orderId":{"type":"string","format":"uuid","description":"Id of the order (from the context of the specified subaccount)","example":"b1234567-89ab-cdef-0123-456789abcdef"},"price":{"type":"string","format":"decimal","description":"Fill price in expressed as a decimal (precision: 9)","example":"4200.5"},"productId":{"type":"string","format":"uuid","description":"Id of product the order fill was made against","example":"9c6bf870-a8ce-4de3-820b-542fd5c049ba"},"reduceOnly":{"type":"boolean","description":"Indicates if the fill is reduce only","example":true},"side":{"allOf":[{"$ref":"#/components/schemas/OrderSide"}],"description":"Side as either BUY (0) or SELL (1)","example":1},"subaccountId":{"type":"string","format":"uuid","description":"Id of the subaccount associated to order fill","example":"aa301f94-f5b7-4e54-8b16-01052fccb2f9"},"type":{"allOf":[{"$ref":"#/components/schemas/OrderType"}],"description":"The provided order's type e.g. MARKET or LIMIT","example":"LIMIT"}}},"OrderSide":{"type":"integer","enum":[0,1],"x-enum-varnames":["BUY","SELL"]},"OrderTimeInForce":{"type":"string","enum":["GTD","IOC","FOK"]},"OrderType":{"type":"string","enum":["MARKET","LIMIT"]},"PageOfFundingDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/FundingDto"},"description":"Array of funding rate history objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfOrderDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/OrderDto"},"description":"Array of order objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfOrderFillDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/OrderFillDto"},"description":"Array of order fill objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfPositionDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PositionDto"},"description":"Array of position objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfPositionFillDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PositionFillDto"},"description":"Array of position fill objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfPositionLiquidationsDto":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PositionLiquidationDto"},"description":"Array of position liquidation objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfProductDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ProductDto"},"description":"Array of product objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfProjectedFundingDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ProjectedFundingDto"},"description":"Array of projected funding rate objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfReferralDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ReferralDto"},"description":"Array of referral objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfSignersDto":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SignerDto"},"description":"Array of signer objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfSubaccountBalanceDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SubaccountBalanceDto"},"description":"Array of order subaccount balances"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfSubaccountDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SubaccountDto"},"description":"Array of subaccount objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfTokensDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TokenDto"},"description":"Array of token objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfTradeDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TradeDto"},"description":"Array of trade objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfTransfersDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TransferDto"},"description":"Array of transfer objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PageOfWithdrawDtos":{"type":"object","required":["hasNext","data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/WithdrawDto"},"description":"Array of subaccount withdraw objects"},"hasNext":{"type":"boolean","description":"Whether there are more objects to paginate through","example":true},"nextCursor":{"type":"string","description":"Pointer to the next page in pagination dataset"}}},"PointsPeriodDto":{"type":"object","required":["id","address","season","epoch","points","referralPoints","startedAt","endedAt","createdAt","updatedAt"],"properties":{"address":{"type":"string","format":"hex","description":"Address of the account (non-checksummed)","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"createdAt":{"type":"integer","description":"Points period creation timestamp (ms since Unix Epoch)","example":1712019600000},"endedAt":{"type":"integer","description":"End of points period (ms since Unix Epoch)","example":1712019600000},"epoch":{"type":"integer","description":"Epoch number within the season","example":1},"id":{"type":"string","format":"uuid","description":"Id representing the points period entry","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"name":{"type":"string","description":"Optional name for the points period"},"points":{"type":"string","format":"decimal","description":"Points earned in this period (excluding referral points) expressed as a decimal (precision: 9)","example":"13.256"},"referralPoints":{"type":"string","format":"decimal","description":"Referral points earned in this period expressed as a decimal (precision: 9)","example":"1.95"},"season":{"type":"integer","description":"Season number","example":1},"startedAt":{"type":"integer","description":"Beginning of points period (ms since Unix Epoch)","example":1712019600000},"updatedAt":{"type":"integer","description":"Points period last update timestamp (ms since Unix Epoch)","example":1712019600000}}},"PointsSeasonSummaryDto":{"type":"object","required":["id","address","season","totalPoints","previousTotalPoints","referralPoints","previousReferralPoints","rank","previousRank","tier","createdAt","updatedAt"],"properties":{"address":{"type":"string","format":"hex","description":"Address of the account (non-checksummed)","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"createdAt":{"type":"integer","description":"Points season summary creation timestamp (ms since Unix Epoch)","example":1712019600000},"id":{"type":"string","format":"uuid","description":"Id representing the summary of points in this season","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"previousRank":{"type":"integer","description":"Rank before most recent distribution","example":2},"previousReferralPoints":{"type":"string","format":"decimal","description":"Referral points earned in this season before most recent distribution expressed as a decimal (precision: 9)","example":"1.95"},"previousTotalPoints":{"type":"string","format":"decimal","description":"Total points earned (excluding referral points) before most recent distribution expressed as a decimal (precision: 9)","example":"13.256"},"rank":{"type":"integer","description":"Current rank in this season","example":1},"referralPoints":{"type":"string","format":"decimal","description":"Referral points earned in this season expressed as a decimal (precision: 9)","example":"1.95"},"season":{"type":"integer","description":"Season number","example":1},"tier":{"allOf":[{"$ref":"#/components/schemas/PointsTier"}],"description":"Account tier derived based on activity this season","example":0},"totalPoints":{"type":"string","format":"decimal","description":"Total points earned (excluding referral points) in this season expressed as a decimal (precision: 9)","example":"13.256"},"updatedAt":{"type":"integer","description":"Points season summary last update timestamp (ms since Unix Epoch)","example":1712019600000}}},"PointsTier":{"type":"number","description":"Account tier derived based on activity this season","enum":[0,1,2,3,4,5],"x-enumNames":["TIER_0","TIER_1","TIER_2","TIER_3","TIER_4","TIER_5"]},"PositionDto":{"type":"object","required":["id","cost","size","fundingUsd","fundingAccruedUsd","feesAccruedUsd","realizedPnl","totalIncreaseNotional","totalIncreaseQuantity","totalDecreaseNotional","totalDecreaseQuantity","side","productId","updatedAt","createdAt","isLiquidated","wasDeleveraged"],"properties":{"cost":{"type":"string","format":"decimal","description":"Current cost of the position in USD expressed as a decimal (precision: 9)","example":"9.3"},"createdAt":{"type":"integer","description":"Position creation timestamp (ms since Unix Epoch)","example":1712019600000},"feesAccruedUsd":{"type":"string","format":"decimal","description":"Fees accrued in USD expressed as a decimal (precision: 9)","example":"0.5"},"fundingAccruedUsd":{"type":"string","format":"decimal","description":"Charged and applied funding on position, negative if paid, expressed as a decimal (precision: 9)","example":"10.5"},"fundingUsd":{"type":"string","format":"decimal","description":"Charged but unapplied funding on position, negative if paid, expressed as a decimal (precision: 9)","example":"1.35"},"id":{"type":"string","format":"uuid","description":"Id representing the position","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"isLiquidated":{"type":"boolean","description":"Whether the position was liquidated","example":true},"liquidationPrice":{"type":"string","format":"decimal","description":"Product price at the time of liquidation (undefined if not liquidated, precision: 9)","example":"1200.5"},"productId":{"type":"string","format":"uuid","description":"Id of product to this position belongs to","example":"9c6bf870-a8ce-4de3-820b-542fd5c049ba"},"realizedPnl":{"type":"string","format":"decimal","description":"Realized PnL in USD expressed as a decimal (precision: 9)","example":"-12.5"},"side":{"allOf":[{"$ref":"#/components/schemas/OrderSide"}],"description":"Side as either BUY (0) or SELL (1)","example":0},"size":{"type":"string","format":"decimal","description":"Position size in native units expressed as a decimal (precision: 9)","example":"1.5"},"totalDecreaseNotional":{"type":"string","format":"decimal","description":"Cumulative USD value of all position decreases expressed as a decimal (precision: 9)","example":"1050.0"},"totalDecreaseQuantity":{"type":"string","format":"decimal","description":"Cumulative quantity of all position decreases expressed as a decimal (precision: 9)","example":"2.5"},"totalIncreaseNotional":{"type":"string","format":"decimal","description":"Cumulative USD value of all position increases expressed as a decimal (precision: 9)","example":"1000.0"},"totalIncreaseQuantity":{"type":"string","format":"decimal","description":"Cumulative quantity of all position increases expressed as a decimal (precision: 9)","example":"2.5"},"unrealizedPnl":{"type":"string","format":"decimal","description":"Unrealized PnL in USD (negative if loss, positive if profit) approximated against the latest mark price, expressed as a decimal (precision: 9)","example":"4.2"},"updatedAt":{"type":"integer","description":"Position last updated timestamp (ms since Unix Epoch)","example":1712019600000},"wasDeleveraged":{"type":"boolean","description":"Whether the position has any associated deleverage records","example":true}}},"PositionFillDto":{"type":"object","required":["price","filled","realizedPnl","type","side","reduceOnly","feeUsd","createdAt"],"properties":{"createdAt":{"type":"integer","description":"Fill creation timestamp (ms since Unix Epoch)","example":1712019600000},"feeUsd":{"type":"string","format":"decimal","description":"The charged fee in USD expressed as a decimal (precision: 9)","example":"3.049563"},"filled":{"type":"string","format":"decimal","description":"Quantity filled in native units expressed as a decimal (precision: 9)","example":"2.420"},"price":{"type":"string","format":"decimal","description":"Fill price expressed as a decimal (precision: 9)","example":"4200.5"},"realizedPnl":{"type":"string","format":"decimal","description":"Realized PnL from the fill in USD expressed as a decimal (precision: 9)","example":"3.049563"},"reduceOnly":{"type":"boolean","description":"Indicates if the fill is reduce only","example":false},"side":{"allOf":[{"$ref":"#/components/schemas/OrderSide"}],"description":"Direction of the fill as either BUY (0) or SELL (1)","example":1},"type":{"type":"string","description":"Corresponding order type that led to the position fill","enum":["MARKET","LIMIT","REALIZED_PNL","LIQUIDATION","REALIZED_FUNDING","DELEVERAGE"],"example":"LIMIT"}}},"PositionLiquidationDto":{"type":"object","required":["id","subaccountId","productId","positionId","liquidationPrice","cause","cost","positionSide","createdAt"],"properties":{"cause":{"type":"string","description":"Cause of liquidation (either MarkChanged or Funding)","enum":["MarkChanged","Funding"],"example":"MarkUpdate"},"cost":{"type":"string","format":"decimal","description":"Position cost at the time of liquidation in USD expressed as a decimal (precision: 9)","example":"1000.5"},"createdAt":{"type":"integer","description":"Position liquidation timestamp (ms since Unix Epoch)","example":1712019600000},"fundingChargeUsd":{"type":"string","format":"decimal","description":"Funding charged in USD expressed as a decimal (precision: 9), undefined if not liquidated due to funding","example":"1200.5"},"id":{"type":"string","format":"uuid","description":"Id representing the position liquidation","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"liquidationPrice":{"type":"string","format":"decimal","description":"Liquidation mark price in USD expressed as a decimal (precision: 9)","example":"1200.5"},"positionId":{"type":"string","format":"uuid","description":"Id representing the position that was liquidated","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"positionSide":{"allOf":[{"$ref":"#/components/schemas/OrderSide"}],"description":"Position side as either BUY (0) or SELL (1)","example":0},"productId":{"type":"string","format":"uuid","description":"Id representing the product that was liquidated","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"subaccountId":{"type":"string","format":"uuid","description":"Id representing the subaccount that was liquidated","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"}}},"ProductDto":{"type":"object","required":["id","ticker","displayTicker","baseTokenAddress","quoteTokenAddress","baseTokenName","quoteTokenName","engineType","onchainId","status","blockNumber","cumulativeFundingUsd","createdAt","minQuantity","lotSize","tickSize","makerFee","takerFee","maxQuantity","minPrice","maxPrice","volume24h","maxLeverage","pythFeedId","fundingRate1h","openInterest","maxOpenInterestUsd","maxPositionNotionalUsd","fundingClampApr","fundingBaselineApr","fundingMaxApr"],"properties":{"baseTokenAddress":{"type":"string","format":"hex","description":"Address of the base token (non-checksummed; zero address if virtual)","example":"0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"},"baseTokenName":{"type":"string","description":"Name of the base token (e.g. BTC in BTCUSD)","example":"ETH"},"blockNumber":{"type":"string","description":"Block number this product was registered on","example":"123062737"},"createdAt":{"type":"integer","description":"Product creation timestamp (ms since Unix Epoch)","example":1712019600000},"cumulativeFundingUsd":{"type":"string","format":"decimal","description":"Cumulative funding in USD of the product (precision: 9)","example":"1.001"},"displayTicker":{"type":"string","description":"Product display ticker based on the base quote token","example":"ETH-USD"},"engineType":{"allOf":[{"$ref":"#/components/schemas/EngineType"}],"description":"The corresponding engine type this product was registered with","example":0},"fundingBaselineApr":{"type":"string","format":"decimal","description":"Funding baseline APR expressed as a decimal (precision: 9)","example":"0.15"},"fundingClampApr":{"type":"string","format":"decimal","description":"Funding clamp APR expressed as a decimal (precision: 9)","example":"0.01"},"fundingMaxApr":{"type":"string","format":"decimal","description":"Maximum funding APR expressed as a decimal, e.g. 2.0 = 200% (precision: 9)","example":"2.0"},"fundingRate1h":{"type":"string","format":"decimal","description":"Last computed hourly funding rate expressed as a decimal (precision: 9)","example":"0.01"},"fundingUpdatedAt":{"type":"integer","description":"Unix timestamp when funding was last updated","example":1721724269},"id":{"type":"string","format":"uuid","description":"Id representing the registered product","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"lotSize":{"type":"string","format":"decimal","description":"Quantity must be divisible by the lotSize in expressed as a decimal (precision: 9)","example":"0.01"},"makerFee":{"type":"string","format":"decimal","description":"Fee charged to the maker on order trades expressed as a decimal (precision: 9)","example":"0.001"},"maxLeverage":{"type":"number","description":"Maximum leverage allowed for the product","example":20},"maxOpenInterestUsd":{"type":"string","format":"decimal","description":"Max OI of one side in USD expressed as a decimal (precision: 9)","example":"200000000.0"},"maxPositionNotionalUsd":{"type":"string","format":"decimal","description":"Max position notional value, in USD expressed as a decimal (precision: 9)","example":"50000000.0"},"maxPrice":{"type":"string","format":"decimal","description":"Max price in USD expressed as a decimal (precision: 9)","example":"100000"},"maxQuantity":{"type":"string","format":"decimal","description":"Max quantity per order in native units expressed as a decimal (precision: 9)","example":"100000"},"minPrice":{"type":"string","format":"decimal","description":"Min price in USD expressed as a decimal (precision: 9)","example":"0"},"minQuantity":{"type":"string","format":"decimal","description":"The minimum order quantity in native units expressed as a decimal (precision: 9)","example":"0.05"},"onchainId":{"type":"integer","description":"The productId generated onchain after registering for the first time","example":1},"openInterest":{"type":"string","format":"decimal","description":"OI of both sides in native units expressed as a decimal (precision: 9)","example":"3300.17"},"pythFeedId":{"type":"integer","description":"Pyth price feed id","example":2},"quoteTokenAddress":{"type":"string","format":"hex","description":"Address of quote token (non-checksummed)","example":"0x4c9EDD5852cd905f086C759E8383e09bff1E68B3"},"quoteTokenName":{"type":"string","description":"Name of the quote token (e.g. USD in BTCUSD)","example":"USDe"},"status":{"type":"string","description":"Product status","enum":["PENDING","ACTIVE"],"example":"ACTIVE"},"takerFee":{"type":"string","format":"decimal","description":"Fee charged to the taker on order trades expressed as a decimal (precision: 9)","example":"0.004"},"tickSize":{"type":"string","format":"decimal","description":"Minimum price increment (tickSize) expressed as a decimal (precision: 9)","example":"0.0001"},"ticker":{"type":"string","description":"Product ticker based on the base quote token","example":"ETHUSD"},"volume24h":{"type":"string","format":"decimal","description":"24h volume in base token native units expressed as a decimal (precision: 9)","example":"500000000.42"}}},"ProjectedFundingDto":{"type":"object","required":["productId","fundingRateProjected1h","fundingRate1h"],"properties":{"fundingRate1h":{"type":"string","format":"decimal","description":"Funding rate expressed as a decimal (precision: 9)","example":"0.013876480"},"fundingRateProjected1h":{"type":"string","format":"decimal","description":"Projected funding rate expressed as a decimal (precision: 9)","example":"0.000078771"},"productId":{"type":"string","format":"uuid","description":"Id representing the registered product"}}},"RateLimitConfigResponseDto":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"oneOf":[{"$ref":"#/components/schemas/HttpPaginatedRateLimitEndpointDto"},{"$ref":"#/components/schemas/HttpFixedRateLimitEndpointDto"},{"$ref":"#/components/schemas/WsFixedRateLimitEndpointDto"},{"$ref":"#/components/schemas/Ws2FixedRateLimitEndpointDto"}]},"description":"List of rate limit endpoint configurations"}}},"RateLimitErrorType":{"type":"string","enum":["RATE_LIMIT_IP","RATE_LIMIT_ACCOUNT","RATE_LIMIT_WITHDRAW","RATE_LIMIT_LINKED_SIGNER"]},"ReferralCodeUsageDto":{"type":"object","required":["code","remainingUsage"],"properties":{"code":{"type":"string","description":"The referral code","example":"XYZ123456789"},"remainingUsage":{"type":"integer","description":"Number of remaining times the code can be claimed","example":5}}},"ReferralDto":{"type":"object","required":["id","referee","codeUsageRemaining","refereeTotalPoints","createdAt"],"properties":{"code":{"type":"string","description":"The referee's referral code to be shared and claimed by others (undefined if not activated)","example":"XYZ123456789"},"codeUsageRemaining":{"type":"integer","description":"Number of remaining times the referral code can be claimed","example":5},"createdAt":{"type":"integer","description":"Timestamp of when this referral was activated (ms since Unix Epoch)","example":1712019600000},"id":{"type":"string","format":"uuid","description":"Id representing the referral","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"referee":{"type":"string","format":"hex","description":"Address of the referee (non-checksummed)","example":"0x4c9EDD5852cd905f086C759E8383e09bff1E68B3"},"refereeTotalPoints":{"type":"string","format":"decimal","description":"Total points (excl. referral points) earned by the referee since referee claimed the code (precision: 9)","example":"1234567.890000000"},"referrer":{"type":"string","format":"hex","description":"Address of the referrer (non-checksummed; undefined if not set)","example":"0x41e038d9c9aF27369EcBCe72A69a96695A1fD0D3"}}},"RefreshLinkedSignerDto":{"type":"object","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/RefreshLinkedSignerDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}}},"RefreshLinkedSignerDtoData":{"type":"object","required":["subaccountId","sender","subaccount","signer","nonce","signedAt"],"properties":{"nonce":{"type":"string","description":"Message nonce timestamp (nanoseconds since Unix Epoch)","example":"2687929537462333"},"sender":{"type":"string","format":"hex","description":"Account address that produced the authorizing signature","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"signedAt":{"type":"integer","description":"Message signedAt current timestamp (seconds since Unix Epoch)","example":1712019600},"signer":{"type":"string","format":"hex","description":"Address of signer to refresh","example":"0x1Db3439a222C519ab44bb1144fC28167b4Fa6EE6"},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"subaccountId":{"type":"string","format":"uuid","description":"Id representing the registered subaccount","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"}}},"RevokeLinkedSignerDto":{"type":"object","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/RevokeLinkedSignerDtoData"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}}},"RevokeLinkedSignerDtoData":{"type":"object","required":["subaccountId","sender","subaccount","signer","nonce","signedAt"],"properties":{"nonce":{"type":"string","description":"Message nonce timestamp (nanoseconds since Unix Epoch)","example":"2687929537462333"},"sender":{"type":"string","format":"hex","description":"Account address that produced the authorizing signature","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"signedAt":{"type":"integer","description":"Message signedAt current timestamp (seconds since Unix Epoch)","example":1712019600},"signer":{"type":"string","format":"hex","description":"Address of signer to revoke","example":"0x1Db3439a222C519ab44bb1144fC28167b4Fa6EE6"},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"subaccountId":{"type":"string","format":"uuid","description":"Id representing the registered subaccount","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"}}},"RpcConfigDto":{"type":"object","required":["domain","signatureTypes"],"properties":{"domain":{"allOf":[{"$ref":"#/components/schemas/DomainTypeDto"}],"description":"Domain type"},"signatureTypes":{"allOf":[{"$ref":"#/components/schemas/SignatureTypesDto"}],"description":"Signature types"}}},"SignatureTypesDto":{"type":"object","required":["LinkSigner","TradeOrder","InitiateWithdraw","RevokeLinkedSigner","CancelOrder","RefreshLinkedSigner","ExtendLinkedSigner","EIP712Auth"],"properties":{"CancelOrder":{"type":"string","description":"CancelOrder signature type"},"EIP712Auth":{"type":"string","description":"EIP712Auth signature type"},"ExtendLinkedSigner":{"type":"string","description":"ExtendLinkedSigner signature type"},"InitiateWithdraw":{"type":"string","description":"InitiateWithdraw signature type"},"LinkSigner":{"type":"string","description":"LinkSigner signature type"},"RefreshLinkedSigner":{"type":"string","description":"RefreshLinkedSigner signature type"},"RevokeLinkedSigner":{"type":"string","description":"RevokeLinkedSigner signature type"},"TradeOrder":{"type":"string","description":"TradeOrder signature type"}}},"SignerDto":{"type":"object","required":["id","signer","status","expiresAt","createdAt"],"properties":{"blockNumber":{"type":"string","description":"Block number the signer has been linked on. Undefined means it has not be processed","example":"123062737"},"category":{"type":"string","description":"Category of the linked signer: API or TRADE_SESSION","enum":["TRADE_SESSION","API"],"example":"TRADE_SESSION"},"createdAt":{"type":"integer","description":"Link signer submission timestamp (ms since Unix Epoch)","example":1712019600000},"expiresAt":{"type":"integer","description":"Signer expiry timestamp (ms since Unix Epoch)","example":1713229200000},"id":{"type":"string","description":"Id representing the linked signer","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"linkedAt":{"type":"integer","description":"Onchain linkage timestamp (ms since Unix Epoch)","example":1712019615000},"name":{"type":"string","description":"Optional name for the linked signer","example":"Delegated signer"},"revokedAt":{"type":"integer","description":"Onchain revocation timestamp (ms since Unix Epoch)","example":1712019600000},"revokedBlockNumber":{"type":"string","description":"Block number the signer has been revoked on. Undefined means it has not be processed","example":"123062737"},"signer":{"type":"string","format":"hex","description":"Address of the signer linked with the subaccount (non-checksummed)","example":"0x1Db3439a222C519ab44bb1144fC28167b4Fa6EE6"},"status":{"type":"string","description":"Status of the signer","enum":["PENDING","ACTIVE","PENDING_REVOKE","REVOKED","REJECTED"],"example":"PENDING"}}},"StopPriceType":{"type":"number","description":"Type of stop price (stop orders only)","enum":[0,1],"x-enumNames":["LAST_PRICE","MARK_PRICE"]},"StopType":{"type":"integer","enum":[0,1],"x-enum-varnames":["GAIN","LOSS"]},"SubaccountBalanceDto":{"type":"object","required":["subaccountId","tokenId","tokenAddress","tokenName","amount","available","totalUsed","updatedAt"],"properties":{"amount":{"type":"string","format":"decimal","description":"Token balance in native units expressed as a decimal (precision: 9)","example":"1.5"},"available":{"type":"string","format":"decimal","description":"Portion of balance transferrable in native units expressed as a decimal (precision: 9)","example":"0.1337"},"subaccountId":{"type":"string","format":"uuid","description":"Id representing the subaccount","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"tokenAddress":{"type":"string","format":"hex","description":"ERC20 deposited token address (non-checksummed, zero address if virtual)","example":"0x4c9EDD5852cd905f086C759E8383e09bff1E68B3"},"tokenId":{"type":"string","format":"uuid","description":"Id representing the token","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"tokenName":{"type":"string","description":"The unique exchange defined token name driven by addToken onchain","example":"ETH"},"totalUsed":{"type":"string","format":"decimal","description":"Portion of balance non-transferrable in native units expressed as a decimal (precision: 9)","example":"1.3663"},"updatedAt":{"type":"integer","description":"Token balance last updated timestamp (ms since Unix Epoch)","example":1712019600000}}},"SubaccountDto":{"type":"object","required":["id","name","account","createdBlockNumber","createdAt"],"properties":{"account":{"type":"string","format":"hex","description":"Address of the account which registered the subaccount (non-checksummed)","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"createdAt":{"type":"integer","description":"Subaccount creation timestamp (ms since Unix Epoch)","example":1712019600000},"createdBlockNumber":{"type":"string","description":"Block number this subaccount was created on","example":"123062737"},"id":{"type":"string","format":"uuid","description":"Id representing the registered subaccount","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"name":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"registeredBlockNumber":{"type":"string","description":"Block number this subaccount was registered on","example":"123062737"}}},"SubmitCreatedCode":{"type":"string","description":"Result codes for orders that were created (may still have been rejected)","enum":["Ok","AccountSuspended","CausesImmediateLiquidation","DuplicateSameSideOco","ExchangeSuspended","ImmediateMatchPostOnly","InsufficientBalance","LiquidationError","MarketOrderReachedMaxSlippage","MaxQuantityExceeded","OcoFilled","OpenValueCapExceeded","OrderIncreasesPosition","RiskLimitExceeded","SignerRevoked","TriggerCanceledError","UnfilledFillOrKill","UnfilledImmediateOrCancel","UnfilledMarketOrder","Unknown"],"example":"Ok"},"SubmitDryOrderDto":{"type":"object","required":["data"],"properties":{"data":{"oneOf":[{"$ref":"#/components/schemas/SubmitOrderMarketDtoData"},{"$ref":"#/components/schemas/SubmitOrderLimitDtoData"}]}}},"SubmitFailedCode":{"type":"string","description":"Result codes for orders that failed to be created (outright failure)","enum":["AccountSuspended","DuplicateClientOrderId","ExchangeSuspended","InsufficientBalance","InvalidExpireTime","InvalidGroupContingencyType","InvalidQuantity","InvalidSigner","LiquidationError","MarginAccountBalanceZero","NonceAlreadyUsed","RiskLimitExceeded","TooManyOpenOrders","TooManyPositions","TooManyStopOrders","InsuranceFundCannotOpenPositions","InstrumentOpenValueCapExceeded","OcoLatencyFloorMismatch","OrderWithZeroQuantity","Unknown"]},"SubmitOrderCreatedDto":{"type":"object","description":"Response returned when order is successfully submitted","required":["id","filled","result"],"properties":{"clientOrderId":{"type":["string","null"],"description":"Client-provided order id (if supplied in request)"},"filled":{"type":"string","format":"decimal","description":"Quantity filled expressed as a decimal string (precision: 9)"},"id":{"type":"string","format":"uuid","description":"Id representing the order"},"result":{"$ref":"#/components/schemas/SubmitCreatedCode","description":"Result code indicating the outcome of the submission"}},"example":{"filled":"0.5","id":"9036443a-441a-4a66-87f2-bd5c44cdca7a","result":"Ok"}},"SubmitOrderCreatedResultCode":{"type":"string","description":"Code indicating the result of the submission","enum":["AccountSuspended","CausesImmediateLiquidation","DuplicateSameSideOco","ExchangeSuspended","ImmediateMatchPostOnly","InsufficientBalance","LiquidationError","MarketOrderReachedMaxSlippage","MaxQuantityExceeded","OcoFilled","Ok","OpenValueCapExceeded","OrderIncreasesPosition","RiskLimitExceeded","SignerRevoked","TriggerCanceledError","UnfilledFillOrKill","UnfilledImmediateOrCancel","UnfilledMarketOrder","MakerCanceledByTaker"]},"SubmitOrderData":{"oneOf":[{"$ref":"#/components/schemas/SubmitOrderMarketDtoData"},{"$ref":"#/components/schemas/SubmitOrderLimitDtoData"}]},"SubmitOrderDto":{"type":"object","description":"Submit order request containing signature and order data","required":["signature","data"],"properties":{"data":{"$ref":"#/components/schemas/SubmitOrderData","description":"Order data, either a market order or a limit order distinguished by the `type` field"},"signature":{"type":"string","format":"hex","description":"Hex-encoded EIP-712 signature authorizing this request"}},"additionalProperties":false},"SubmitOrderFailedDto":{"type":"object","required":["statusCode","error","message"],"properties":{"error":{"type":"string","enum":["Unprocessable Entity"]},"message":{"$ref":"#/components/schemas/SubmitFailedCode"},"statusCode":{"type":"integer","format":"uint16","enum":[422]}}},"SubmitOrderFailedResultCode":{"type":"string","description":"Code indicating the reason for failure","enum":["AccountSuspended","DuplicateClientOrderId","ExchangeSuspended","InsufficientBalance","InvalidBinaryData","InvalidExpireTime","InvalidGroupContingencyType","InvalidNonceForSigner","InvalidSigner","InvalidSignerAddress","InvalidTimeInForce","LiquidationError","MarginAccountBalanceZero","NonceAlreadyUsed","PriceAboveMaximum","PriceBelowMinimum","RiskLimitExceeded","TooManyOpenOrders","TooManyPositions","TooManyStopOrders","InsuranceFundCannotOpenPositions","InstrumentOpenValueCapExceeded","QuantityAboveMaximum","QuantityNotMultipleOfLotSize","OrderWithZeroQuantity","OcoLatencyFloorMismatch"]},"SubmitOrderLimitDtoData":{"type":"object","required":["sender","engineType","subaccount","onchainId","side","quantity","nonce","signedAt","price","timeInForce","postOnly","type"],"properties":{"clientOrderId":{"type":["string","null"],"description":"A subaccount scoped unique client-generated order id (either a UUID or alphanumeric string up to 32 characters)","example":"16e2da4d-58ab-4453-bdb4-8e4a865c12c1","maxLength":36},"close":{"type":"boolean","description":"Order closes the entire current position, requires zero quantity and reduceOnly","default":false},"engineType":{"$ref":"#/components/schemas/EngineType","description":"Product engine type e.g. PERP (0)"},"expiresAt":{"type":["integer","null"],"format":"uint64","description":"Order expiry timestamp (seconds since Unix Epoch), defaults to the maximum allowed value: signedAt + 6652800","example":1712623600,"minimum":0},"groupContingencyType":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/GroupContingencyType","description":"Contingency type for order groups: OTO (Order-Triggers-Order) or OCO (One-Cancels-Other)"}]},"groupId":{"type":["string","null"],"format":"uuid","description":"Group Id (UUID) for linking orders together in OCO/OTO relationships"},"nonce":{"oneOf":[{"type":"string","format":"uint64"}],"description":"Message nonce timestamp (nanoseconds since Unix Epoch)"},"onchainId":{"type":"integer","format":"uint32","description":"Onchain product ID, available from the products endpoint","example":1,"minimum":1},"postOnly":{"type":"boolean","description":"Only add order if it does not immediately fill","default":false},"price":{"type":"string","format":"decimal","description":"Limit price expressed as a decimal (precision: 9)","example":"4200.5"},"quantity":{"type":"string","format":"decimal","description":"Non-directional quantity of product in native units expressed as a decimal (precision: 9)","example":"5.5"},"reduceOnly":{"type":"boolean","description":"Whether this should be a reduce-only order. Must be true when close is true","default":false},"sender":{"type":"string","format":"hex","description":"Account address that produced the authorizing signature","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"side":{"$ref":"#/components/schemas/OrderSide","description":"Side as either BUY (0) or SELL (1)"},"signedAt":{"oneOf":[{"type":"integer","format":"uint64","minimum":0}],"description":"Message signedAt current timestamp (seconds since Unix Epoch)"},"stopPrice":{"type":["string","null"],"format":"decimal","description":"Stop price expressed as a decimal (precision: 9), requires stopType","default":"0","example":"4200.5"},"stopType":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/StopType","description":"Stop type, either 0 (take-profit) or 1 (stop-loss), requires non-zero stopPrice"}]},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"timeInForce":{"$ref":"#/components/schemas/OrderTimeInForce","description":"How long an order will remain until executed/expired"},"type":{"type":"string","enum":["LIMIT"]}},"additionalProperties":false},"SubmitOrderMarketDtoData":{"type":"object","required":["sender","engineType","subaccount","onchainId","side","quantity","nonce","signedAt","type"],"properties":{"clientOrderId":{"type":["string","null"],"description":"A subaccount scoped unique client-generated order id (either a UUID or alphanumeric string up to 32 characters)","example":"16e2da4d-58ab-4453-bdb4-8e4a865c12c1","maxLength":36},"close":{"type":"boolean","description":"Order closes the entire current position, requires zero quantity and reduceOnly","default":false},"engineType":{"$ref":"#/components/schemas/EngineType","description":"Product engine type e.g. PERP (0)"},"expiresAt":{"type":["integer","null"],"format":"uint64","description":"Order expiry timestamp (seconds since Unix Epoch), defaults to the maximum allowed value: signedAt + 6652800","example":1712623600,"minimum":0},"groupContingencyType":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/GroupContingencyType","description":"Contingency type for order groups: OTO (Order-Triggers-Order) or OCO (One-Cancels-Other)"}]},"groupId":{"type":["string","null"],"format":"uuid","description":"Group Id (UUID) for linking orders together in OCO/OTO relationships"},"nonce":{"oneOf":[{"type":"string","format":"uint64"}],"description":"Message nonce timestamp (nanoseconds since Unix Epoch)"},"onchainId":{"type":"integer","format":"uint32","description":"Onchain product ID, available from the products endpoint","example":1,"minimum":1},"quantity":{"type":"string","format":"decimal","description":"Non-directional quantity of product in native units expressed as a decimal (precision: 9)","example":"5.5"},"reduceOnly":{"type":"boolean","description":"Whether this should be a reduce-only order. Must be true when close is true","default":false},"sender":{"type":"string","format":"hex","description":"Account address that produced the authorizing signature","example":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"},"side":{"$ref":"#/components/schemas/OrderSide","description":"Side as either BUY (0) or SELL (1)"},"signedAt":{"oneOf":[{"type":"integer","format":"uint64","minimum":0}],"description":"Message signedAt current timestamp (seconds since Unix Epoch)"},"stopPrice":{"type":["string","null"],"format":"decimal","description":"Stop price expressed as a decimal (precision: 9), requires stopType","default":"0","example":"4200.5"},"stopType":{"oneOf":[{"type":"null"},{"$ref":"#/components/schemas/StopType","description":"Stop type, either 0 (take-profit) or 1 (stop-loss), requires non-zero stopPrice"}]},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"type":{"type":"string","enum":["MARKET"]}},"additionalProperties":false},"SystemTimeDto":{"type":"object","required":["time"],"properties":{"time":{"type":"number","description":"Current system timestamp (ms since Unix Epoch)","example":1712019600000}}},"TokenDto":{"type":"object","required":["id","address","lzOftAddress","name","depositEnabled","withdrawEnabled","depositFee","withdrawFee","minDeposit","addedBlockNumber","createdAt"],"properties":{"addedBlockNumber":{"type":"string","description":"Block number when the token was added","example":"838808"},"address":{"type":"string","format":"hex","description":"Address of the token (non-checksummed; zero address if virtual)","example":"0x4c9EDD5852cd905f086C759E8383e09bff1E68B3"},"createdAt":{"type":"integer","description":"Token creation timestamp (ms since Unix Epoch)","example":1712019600000},"depositEnabled":{"type":"boolean","description":"Whether the token is enabled for deposit","example":true},"depositFee":{"type":"string","format":"decimal","description":"Amount of native units charged on deposit expressed as a decimal (precision: 9)","example":"0"},"erc20Decimals":{"type":"number","description":"ERC20 token decimals (available if not virtual)","example":18},"erc20Name":{"type":"string","description":"ERC20 token name (available if not virtual)","example":"Wrapped USDe"},"erc20Symbol":{"type":"string","description":"ERC20 token symbol (available if not virtual)","example":"WUSDe"},"id":{"type":"string","format":"uuid","description":"Id representing the token","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"lzOftAddress":{"type":"string","format":"hex","description":"LayerZero OFT address of the token (non-checksummed; if has LZ OFT or adapter, zero address if not)","example":"0x41e038d9c9aF27369EcBCe72A69a96695A1fD0D3"},"minDeposit":{"type":"string","format":"decimal","description":"Min deposit amount as native units expressed as a decimal (precision: 9)","example":"10.123456"},"name":{"type":"string","description":"The unique exchange defined token name driven by addToken onchain","example":"USD"},"removedBlockNumber":{"type":"string","description":"Block number when the token was removed (undefined if not removed)"},"withdrawEnabled":{"type":"boolean","description":"Whether the token is enabled for withdraw","example":true},"withdrawFee":{"type":"string","format":"decimal","description":"Amount of native units charged on withdraw expressed as a decimal (precision: 9)","example":"1"}}},"TooManyRequestsDto":{"type":"object","required":["statusCode","error","message","type"],"properties":{"error":{"type":"string","enum":["Too Many Requests"]},"message":{"type":"string"},"statusCode":{"type":"integer","format":"uint16","enum":[429]},"type":{"$ref":"#/components/schemas/RateLimitErrorType"}}},"TotalPointsDto":{"type":"object","required":["totalPoints","referralPoints"],"properties":{"referralPoints":{"type":"string","format":"decimal","description":"Total referral points distributed (precision: 9)","example":"123456.78"},"totalPoints":{"type":"string","format":"decimal","description":"Total points distributed (precision: 9)","example":"1234567.89"},"updatedAt":{"type":"integer","description":"Last update timestamp of the aggregated points periods (ms since Unix Epoch)","example":1712019600000}}},"TradeDto":{"type":"object","required":["id","takerOrderId","makerOrderId","makerFeeUsd","takerFeeUsd","price","filled","makerSide","takerSide","productId","createdAt"],"properties":{"createdAt":{"type":"integer","description":"Trade creation timestamp (ms since Unix Epoch)","example":1712019600000},"filled":{"type":"string","format":"decimal","description":"Quantity filled in native units expressed as a decimal (precision: 9)","example":"2.420"},"id":{"type":"string","format":"uuid","description":"Id representing the trade","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"makerClientOrderId":{"type":"string","description":"Client-generated order id of the maker order","example":"e3f0a8b7-6daa-498a-bf53-c16dc5e779de"},"makerFeeUsd":{"type":"string","format":"decimal","description":"Maker fee in USD expressed as a decimal (precision: 9)","example":"3.049563"},"makerOrderId":{"type":"string","format":"uuid","description":"Id of the maker order","example":"e3f0a8b7-6daa-498a-bf53-c16dc5e779de"},"makerSide":{"allOf":[{"$ref":"#/components/schemas/OrderSide"}],"description":"Maker side as either BUY (0) or SELL (1)","example":1},"price":{"type":"string","format":"decimal","description":"Price expressed as a decimal (precision: 9)","example":"4200.5"},"productId":{"type":"string","format":"uuid","description":"Id of product the trade was made against","example":"9c6bf870-a8ce-4de3-820b-542fd5c049ba"},"takerClientOrderId":{"type":"string","description":"Client-generated order id of the taker order","example":"b1234567-89ab-cdef-0123-456789abcdef"},"takerFeeUsd":{"type":"string","format":"decimal","description":"Taker fee in USD expressed as a decimal (precision: 9)","example":"4.5743445"},"takerOrderId":{"type":"string","format":"uuid","description":"Id of the taker order","example":"b1234567-89ab-cdef-0123-456789abcdef"},"takerSide":{"allOf":[{"$ref":"#/components/schemas/OrderSide"}],"description":"Taker side as either BUY (0) or SELL (1)","example":0}}},"TransferDto":{"type":"object","required":["id","status","subaccountId","tokenName","tokenAddress","type","amount","fee","createdAt"],"properties":{"amount":{"type":"string","format":"decimal","description":"Amount of tokens transferred in native units expressed as a decimal (precision: 9)","example":"0.42"},"createdAt":{"type":"integer","description":"Transfer creation timestamp (ms since Unix Epoch)","example":1712019600000},"fee":{"type":"string","format":"decimal","description":"Fee paid for the transfer in native units expressed as a decimal (precision: 9)","example":"0.42"},"finalizedBlockNumber":{"type":"string","description":"Block number the transfer was completed on","example":"123062992"},"finalizedTransactionHash":{"type":"string","format":"hex","description":"Transaction hash for the finalization of the transfer","example":"0x42aa378d58b92c639dda64d528a6123f14e59e071c4b56e058d3a54b819e2b79"},"id":{"type":"string","format":"uuid","description":"Id representing the transfer","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"initiatedBlockNumber":{"type":"string","description":"Block number the transfer was initiated on","example":"123062000"},"initiatedTransactionHash":{"type":"string","format":"hex","description":"Transaction hash for the initiation of the transfer","example":"0x8ffa427c4079a78a64811e80fe4dbefa8bd8e2f4cc572cda9717297d220d4f8e"},"lzDestinationAddress":{"type":"string","format":"hex","description":"LayerZero destination address (leading 0x bytes32 encoded) for the transfer (if withdraw)"},"lzDestinationEid":{"type":"integer","description":"LayerZero destination endpoint ID for the transfer (if withdraw)","example":40422},"status":{"type":"string","description":"Current status of the transfer","enum":["SUBMITTED","PENDING","COMPLETED","REJECTED"],"example":"PENDING"},"subaccountId":{"type":"string","format":"uuid","description":"Id representing the registered subaccount","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"tokenAddress":{"type":"string","format":"hex","description":"Address of token transferred (non-checksummed)","example":"0x4c9EDD5852cd905f086C759E8383e09bff1E68B3"},"tokenName":{"type":"string","description":"The unique exchange defined token name driven by addToken onchain","example":"ETH"},"type":{"type":"string","description":"Type of transfer (WITHDRAW or DEPOSIT)","enum":["DEPOSIT","WITHDRAW"],"example":"WITHDRAW"}}},"TransferStatus":{"type":"string","description":"Current status of the withdraw","enum":["SUBMITTED","PENDING","COMPLETED","REJECTED"]},"TransferType":{"type":"string","enum":["DEPOSIT","WITHDRAW"]},"UnauthorizedDto":{"type":"object","required":["statusCode","error","message"],"properties":{"error":{"type":"string","enum":["Unauthorized"]},"message":{"type":"string"},"statusCode":{"type":"integer","format":"uint16","enum":[401]}}},"UnprocessableEntityDto":{"type":"object","required":["statusCode","error","message"],"properties":{"error":{"type":"string","enum":["Unprocessable Entity"]},"message":{"type":"string"},"statusCode":{"type":"integer","format":"uint16","enum":[422]}}},"WhitelistDto":{"type":"object","required":["isWhitelisted"],"properties":{"isWhitelisted":{"type":"boolean","description":"Whether the address is whitelisted","example":true}}},"WithdrawDto":{"type":"object","required":["id","status","subaccount","token","amount","createdAt","withdrawDigest"],"properties":{"amount":{"type":"string","description":"Amount of asset transferred expressed as a decimal","example":"1.5"},"createdAt":{"type":"integer","description":"Withdraw creation timestamp (ms since Unix Epoch)","example":1712019600000},"finalizedBlockNumber":{"type":"string","description":"Block number the withdraw was completed on","example":"123062992"},"id":{"type":"string","format":"uuid","description":"Id representing the withdraw","example":"9036443a-441a-4a66-87f2-bd5c44cdca7a"},"initiatedBlockNumber":{"type":"string","description":"Block number the withdraw was initiated on","example":"123062000"},"lzDestinationAddress":{"type":"string","format":"hex","description":"LayerZero destination address (leading 0x bytes32 encoded) for the transfer (if withdraw)"},"lzDestinationEid":{"type":"integer","description":"LayerZero destination endpoint ID for the transfer (if withdraw)","example":30391},"status":{"allOf":[{"$ref":"#/components/schemas/TransferStatus"}],"description":"Current status of the withdraw","example":"PENDING"},"subaccount":{"type":"string","format":"hex","description":"Bytes32 encoded subaccount name (0x prefix, zero padded)","example":"0x7072696d61727900000000000000000000000000000000000000000000000000"},"token":{"type":"string","format":"hex","description":"Address of asset to withdraw (non-checksummed)","example":"0x4c9EDD5852cd905f086C759E8383e09bff1E68B3"},"withdrawDigest":{"type":"string","format":"hex","description":"Bytes32 hash of the withdraw data (with 0x prefix)"}}},"WithdrawErrorCode":{"type":"string","description":"Error code indicating the reason for failure","enum":["AccountSuspended","EngineSuspended","InsufficientBalance","InsuranceFundCannotWithdraw"]},"WithdrawFailedDto":{"type":"object","required":["statusCode","message","error"],"properties":{"error":{"type":"string","default":"Unprocessable Entity","enum":["Unprocessable Entity"]},"message":{"allOf":[{"$ref":"#/components/schemas/WithdrawErrorCode"}],"description":"Error code indicating the reason for failure","example":"InsufficientBalance"},"statusCode":{"type":"number","default":422,"enum":[422]}}},"Ws2FixedRateLimitEndpointDto":{"type":"object","required":["path","protocol","type","fixedPoints"],"properties":{"fixedPoints":{"type":"number","description":"Fixed points consumed per request","example":5},"path":{"type":"string","description":"WebSocket path","example":"/v1/stream"},"protocol":{"type":"string","description":"Protocol","enum":["WS2"]},"type":{"type":"string","description":"Endpoint type (either PAGINATED or FIXED)","enum":["FIXED"]}}},"WsFixedRateLimitEndpointDto":{"type":"object","required":["namespace","protocol","type","fixedPoints"],"properties":{"fixedPoints":{"type":"number","description":"Fixed points consumed per request","example":5},"namespace":{"type":"string","description":"WebSocket namespace","example":"orders"},"protocol":{"type":"string","description":"Protocol","enum":["WS"]},"type":{"type":"string","description":"Endpoint type (either PAGINATED or FIXED)","enum":["FIXED"]}}}}},"tags":[{"name":"Order","description":"Order submission, cancelation, and management"},{"name":"Position","description":"Position queries, fill history, and liquidation data"},{"name":"Product","description":"Product listing and configuration"},{"name":"Funding","description":"Funding rate and payment history"},{"name":"Subaccount","description":"Subaccount management, balances, and deposits"},{"name":"LinkedSigner","description":"Linked signer (delegate) management"},{"name":"Token","description":"Authentication token management"},{"name":"Whitelist","description":"Whitelist status queries"},{"name":"Referral","description":"Referral program and referral code management"},{"name":"Points","description":"Points, rewards, and season information"},{"name":"RateLimit","description":"Rate limit status and quota information"},{"name":"Rpc","description":"RPC configuration and EIP-712 signing data"},{"name":"Time","description":"Server time synchronization"},{"name":"Maintenance","description":"Maintenance mode status"},{"name":"Order","description":"Order submission, cancellation, and management"}]}