@polyester/sdk 0.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (745) hide show
  1. package/CHANGELOG.md +1 -0
  2. package/LICENSE +7 -0
  3. package/README.md +55 -0
  4. package/SECURITY.md +14 -0
  5. package/dist/_virtual/_rolldown/runtime.js +13 -0
  6. package/dist/account-signer/create-polyester-account-signer.d.ts +28 -0
  7. package/dist/account-signer/create-polyester-account-signer.d.ts.map +1 -0
  8. package/dist/account-signer/create-polyester-account-signer.js +101 -0
  9. package/dist/account-signer/create-polyester-account-signer.js.map +1 -0
  10. package/dist/account-signer/index.d.ts +3 -0
  11. package/dist/account-signer/index.js +3 -0
  12. package/dist/account-signer/predict-safe-address.js +230 -0
  13. package/dist/account-signer/predict-safe-address.js.map +1 -0
  14. package/dist/account-signer/types.d.ts +40 -0
  15. package/dist/account-signer/types.d.ts.map +1 -0
  16. package/dist/account-signer/types.js +29 -0
  17. package/dist/account-signer/types.js.map +1 -0
  18. package/dist/browser-client.d.ts +37 -0
  19. package/dist/browser-client.d.ts.map +1 -0
  20. package/dist/browser-client.js +69 -0
  21. package/dist/browser-client.js.map +1 -0
  22. package/dist/catalogs/client-catalog.d.ts +6 -0
  23. package/dist/catalogs/client-catalog.d.ts.map +1 -0
  24. package/dist/catalogs/client-catalog.js +88 -0
  25. package/dist/catalogs/client-catalog.js.map +1 -0
  26. package/dist/catalogs/decimal.js +92 -0
  27. package/dist/catalogs/decimal.js.map +1 -0
  28. package/dist/catalogs/index.d.ts +10 -0
  29. package/dist/catalogs/index.js +8 -0
  30. package/dist/catalogs/indexes.js +36 -0
  31. package/dist/catalogs/indexes.js.map +1 -0
  32. package/dist/catalogs/market-data-catalog.d.ts +37 -0
  33. package/dist/catalogs/market-data-catalog.d.ts.map +1 -0
  34. package/dist/catalogs/market-data-catalog.js +49 -0
  35. package/dist/catalogs/market-data-catalog.js.map +1 -0
  36. package/dist/catalogs/readers.d.ts +6 -0
  37. package/dist/catalogs/readers.d.ts.map +1 -0
  38. package/dist/catalogs/readers.js +545 -0
  39. package/dist/catalogs/readers.js.map +1 -0
  40. package/dist/catalogs/snapshot.d.ts +18 -0
  41. package/dist/catalogs/snapshot.d.ts.map +1 -0
  42. package/dist/catalogs/snapshot.js +16 -0
  43. package/dist/catalogs/snapshot.js.map +1 -0
  44. package/dist/catalogs/types.d.ts +268 -0
  45. package/dist/catalogs/types.d.ts.map +1 -0
  46. package/dist/catalogs/types.js +48 -0
  47. package/dist/catalogs/types.js.map +1 -0
  48. package/dist/catalogs/unknown-asset.d.ts +27 -0
  49. package/dist/catalogs/unknown-asset.d.ts.map +1 -0
  50. package/dist/catalogs/unknown-asset.js +38 -0
  51. package/dist/catalogs/unknown-asset.js.map +1 -0
  52. package/dist/catalogs/zipper-catalog.d.ts +33 -0
  53. package/dist/catalogs/zipper-catalog.d.ts.map +1 -0
  54. package/dist/catalogs/zipper-catalog.js +54 -0
  55. package/dist/catalogs/zipper-catalog.js.map +1 -0
  56. package/dist/catalogs/zipper-supply.d.ts +10 -0
  57. package/dist/catalogs/zipper-supply.d.ts.map +1 -0
  58. package/dist/catalogs/zipper-supply.js +40 -0
  59. package/dist/catalogs/zipper-supply.js.map +1 -0
  60. package/dist/core-client.d.ts +155 -0
  61. package/dist/core-client.d.ts.map +1 -0
  62. package/dist/core-client.js +266 -0
  63. package/dist/core-client.js.map +1 -0
  64. package/dist/environment.d.ts +57 -0
  65. package/dist/environment.d.ts.map +1 -0
  66. package/dist/environment.js +153 -0
  67. package/dist/environment.js.map +1 -0
  68. package/dist/gen/auth/v1/address_book_pb.d.ts +2012 -0
  69. package/dist/gen/auth/v1/address_book_pb.d.ts.map +1 -0
  70. package/dist/gen/auth/v1/address_book_pb.js +505 -0
  71. package/dist/gen/auth/v1/address_book_pb.js.map +1 -0
  72. package/dist/gen/auth/v1/api_keys_pb.d.ts +496 -0
  73. package/dist/gen/auth/v1/api_keys_pb.d.ts.map +1 -0
  74. package/dist/gen/auth/v1/api_keys_pb.js +137 -0
  75. package/dist/gen/auth/v1/api_keys_pb.js.map +1 -0
  76. package/dist/gen/auth/v1/auth_pb.d.ts +523 -0
  77. package/dist/gen/auth/v1/auth_pb.d.ts.map +1 -0
  78. package/dist/gen/auth/v1/auth_pb.js +313 -0
  79. package/dist/gen/auth/v1/auth_pb.js.map +1 -0
  80. package/dist/gen/auth/v1/mfa_pb.d.ts +1020 -0
  81. package/dist/gen/auth/v1/mfa_pb.d.ts.map +1 -0
  82. package/dist/gen/auth/v1/mfa_pb.js +315 -0
  83. package/dist/gen/auth/v1/mfa_pb.js.map +1 -0
  84. package/dist/gen/auth/v1/policies_pb.d.ts +1410 -0
  85. package/dist/gen/auth/v1/policies_pb.d.ts.map +1 -0
  86. package/dist/gen/auth/v1/policies_pb.js +341 -0
  87. package/dist/gen/auth/v1/policies_pb.js.map +1 -0
  88. package/dist/gen/auth/v1/profile_pb.d.ts +370 -0
  89. package/dist/gen/auth/v1/profile_pb.d.ts.map +1 -0
  90. package/dist/gen/auth/v1/profile_pb.js +114 -0
  91. package/dist/gen/auth/v1/profile_pb.js.map +1 -0
  92. package/dist/gen/auth/v1/resolve_pb.d.ts +174 -0
  93. package/dist/gen/auth/v1/resolve_pb.d.ts.map +1 -0
  94. package/dist/gen/auth/v1/resolve_pb.js +80 -0
  95. package/dist/gen/auth/v1/resolve_pb.js.map +1 -0
  96. package/dist/gen/auth/v1/social_verification_pb.d.ts +408 -0
  97. package/dist/gen/auth/v1/social_verification_pb.d.ts.map +1 -0
  98. package/dist/gen/auth/v1/social_verification_pb.js +196 -0
  99. package/dist/gen/auth/v1/social_verification_pb.js.map +1 -0
  100. package/dist/gen/auth/v1/subaccounts_pb.d.ts +1490 -0
  101. package/dist/gen/auth/v1/subaccounts_pb.d.ts.map +1 -0
  102. package/dist/gen/auth/v1/subaccounts_pb.js +574 -0
  103. package/dist/gen/auth/v1/subaccounts_pb.js.map +1 -0
  104. package/dist/gen/chain/analytics/v1/analytics_read_pb.d.ts +426 -0
  105. package/dist/gen/chain/analytics/v1/analytics_read_pb.d.ts.map +1 -0
  106. package/dist/gen/chain/analytics/v1/analytics_read_pb.js +119 -0
  107. package/dist/gen/chain/analytics/v1/analytics_read_pb.js.map +1 -0
  108. package/dist/gen/chain/deposit/v1/deposit_pb.d.ts +158 -0
  109. package/dist/gen/chain/deposit/v1/deposit_pb.d.ts.map +1 -0
  110. package/dist/gen/chain/deposit/v1/deposit_pb.js +52 -0
  111. package/dist/gen/chain/deposit/v1/deposit_pb.js.map +1 -0
  112. package/dist/gen/chain/guard/v1/guard_signer_pb.d.ts +588 -0
  113. package/dist/gen/chain/guard/v1/guard_signer_pb.d.ts.map +1 -0
  114. package/dist/gen/chain/guard/v1/guard_signer_pb.js +195 -0
  115. package/dist/gen/chain/guard/v1/guard_signer_pb.js.map +1 -0
  116. package/dist/gen/chain/lifecycle/v1/lifecycle_read_pb.d.ts +1297 -0
  117. package/dist/gen/chain/lifecycle/v1/lifecycle_read_pb.d.ts.map +1 -0
  118. package/dist/gen/chain/lifecycle/v1/lifecycle_read_pb.js +408 -0
  119. package/dist/gen/chain/lifecycle/v1/lifecycle_read_pb.js.map +1 -0
  120. package/dist/gen/chain/lifecycle/v1/types_pb.d.ts +359 -0
  121. package/dist/gen/chain/lifecycle/v1/types_pb.d.ts.map +1 -0
  122. package/dist/gen/chain/lifecycle/v1/types_pb.js +322 -0
  123. package/dist/gen/chain/lifecycle/v1/types_pb.js.map +1 -0
  124. package/dist/gen/chain/withdraw/v1/withdraw_pb.d.ts +236 -0
  125. package/dist/gen/chain/withdraw/v1/withdraw_pb.d.ts.map +1 -0
  126. package/dist/gen/chain/withdraw/v1/withdraw_pb.js +79 -0
  127. package/dist/gen/chain/withdraw/v1/withdraw_pb.js.map +1 -0
  128. package/dist/gen/chain/zipper/v1/reason_pb.d.ts +349 -0
  129. package/dist/gen/chain/zipper/v1/reason_pb.d.ts.map +1 -0
  130. package/dist/gen/chain/zipper/v1/reason_pb.js +330 -0
  131. package/dist/gen/chain/zipper/v1/reason_pb.js.map +1 -0
  132. package/dist/gen/chain/zipper/v1/zipper_pb.d.ts +396 -0
  133. package/dist/gen/chain/zipper/v1/zipper_pb.d.ts.map +1 -0
  134. package/dist/gen/chain/zipper/v1/zipper_pb.js +70 -0
  135. package/dist/gen/chain/zipper/v1/zipper_pb.js.map +1 -0
  136. package/dist/gen/collab/v1/whiteboard_pb.d.ts +829 -0
  137. package/dist/gen/collab/v1/whiteboard_pb.d.ts.map +1 -0
  138. package/dist/gen/collab/v1/whiteboard_pb.js +250 -0
  139. package/dist/gen/collab/v1/whiteboard_pb.js.map +1 -0
  140. package/dist/gen/index.d.ts +35 -0
  141. package/dist/gen/index.js +35 -0
  142. package/dist/gen/layout/v1/layout_pb.d.ts +1289 -0
  143. package/dist/gen/layout/v1/layout_pb.d.ts.map +1 -0
  144. package/dist/gen/layout/v1/layout_pb.js +313 -0
  145. package/dist/gen/layout/v1/layout_pb.js.map +1 -0
  146. package/dist/gen/ledger/read/v1/ledger_read_pb.d.ts +1000 -0
  147. package/dist/gen/ledger/read/v1/ledger_read_pb.d.ts.map +1 -0
  148. package/dist/gen/ledger/read/v1/ledger_read_pb.js +347 -0
  149. package/dist/gen/ledger/read/v1/ledger_read_pb.js.map +1 -0
  150. package/dist/gen/ledger/v1/catalog_pb.d.ts +129 -0
  151. package/dist/gen/ledger/v1/catalog_pb.d.ts.map +1 -0
  152. package/dist/gen/ledger/v1/catalog_pb.js +138 -0
  153. package/dist/gen/ledger/v1/catalog_pb.js.map +1 -0
  154. package/dist/gen/marketdata/v1/heatmap_pb.d.ts +571 -0
  155. package/dist/gen/marketdata/v1/heatmap_pb.d.ts.map +1 -0
  156. package/dist/gen/marketdata/v1/heatmap_pb.js +194 -0
  157. package/dist/gen/marketdata/v1/heatmap_pb.js.map +1 -0
  158. package/dist/gen/marketdata/v1/marketdata_pb.d.ts +1015 -0
  159. package/dist/gen/marketdata/v1/marketdata_pb.d.ts.map +1 -0
  160. package/dist/gen/marketdata/v1/marketdata_pb.js +274 -0
  161. package/dist/gen/marketdata/v1/marketdata_pb.js.map +1 -0
  162. package/dist/gen/marketoverview/v1/marketoverview_pb.d.ts +419 -0
  163. package/dist/gen/marketoverview/v1/marketoverview_pb.d.ts.map +1 -0
  164. package/dist/gen/marketoverview/v1/marketoverview_pb.js +212 -0
  165. package/dist/gen/marketoverview/v1/marketoverview_pb.js.map +1 -0
  166. package/dist/gen/orderbook/v1/orderbook_pb.d.ts +260 -0
  167. package/dist/gen/orderbook/v1/orderbook_pb.d.ts.map +1 -0
  168. package/dist/gen/orderbook/v1/orderbook_pb.js +119 -0
  169. package/dist/gen/orderbook/v1/orderbook_pb.js.map +1 -0
  170. package/dist/gen/orders/v1/orders_pb.d.ts +2497 -0
  171. package/dist/gen/orders/v1/orders_pb.d.ts.map +1 -0
  172. package/dist/gen/orders/v1/orders_pb.js +1043 -0
  173. package/dist/gen/orders/v1/orders_pb.js.map +1 -0
  174. package/dist/gen/orders/v1/orders_read_pb.d.ts +1322 -0
  175. package/dist/gen/orders/v1/orders_read_pb.d.ts.map +1 -0
  176. package/dist/gen/orders/v1/orders_read_pb.js +408 -0
  177. package/dist/gen/orders/v1/orders_read_pb.js.map +1 -0
  178. package/dist/gen/polychart/events/v1/polychart_events_pb.d.ts +192 -0
  179. package/dist/gen/polychart/events/v1/polychart_events_pb.d.ts.map +1 -0
  180. package/dist/gen/polychart/events/v1/polychart_events_pb.js +57 -0
  181. package/dist/gen/polychart/events/v1/polychart_events_pb.js.map +1 -0
  182. package/dist/gen/polychart/v1/polychart_pb.d.ts +1208 -0
  183. package/dist/gen/polychart/v1/polychart_pb.d.ts.map +1 -0
  184. package/dist/gen/polychart/v1/polychart_pb.js +244 -0
  185. package/dist/gen/polychart/v1/polychart_pb.js.map +1 -0
  186. package/dist/gen/polyester/api/options_pb.d.ts +67 -0
  187. package/dist/gen/polyester/api/options_pb.d.ts.map +1 -0
  188. package/dist/gen/polyester/api/options_pb.js +76 -0
  189. package/dist/gen/polyester/api/options_pb.js.map +1 -0
  190. package/dist/gen/polyester/type/v1/u128_pb.d.ts +42 -0
  191. package/dist/gen/polyester/type/v1/u128_pb.d.ts.map +1 -0
  192. package/dist/gen/polyester/type/v1/u128_pb.js +20 -0
  193. package/dist/gen/polyester/type/v1/u128_pb.js.map +1 -0
  194. package/dist/gen/tradews/v1/trade_ws_pb.d.ts +316 -0
  195. package/dist/gen/tradews/v1/trade_ws_pb.d.ts.map +1 -0
  196. package/dist/gen/tradews/v1/trade_ws_pb.js +63 -0
  197. package/dist/gen/tradews/v1/trade_ws_pb.js.map +1 -0
  198. package/dist/gen/transfer/v1/internal_transfer_pb.d.ts +235 -0
  199. package/dist/gen/transfer/v1/internal_transfer_pb.d.ts.map +1 -0
  200. package/dist/gen/transfer/v1/internal_transfer_pb.js +81 -0
  201. package/dist/gen/transfer/v1/internal_transfer_pb.js.map +1 -0
  202. package/dist/gen/triggers/v1/triggers_pb.d.ts +1731 -0
  203. package/dist/gen/triggers/v1/triggers_pb.d.ts.map +1 -0
  204. package/dist/gen/triggers/v1/triggers_pb.js +413 -0
  205. package/dist/gen/triggers/v1/triggers_pb.js.map +1 -0
  206. package/dist/index.d.ts +100 -0
  207. package/dist/index.js +18 -0
  208. package/dist/realtime/client.d.ts +18 -0
  209. package/dist/realtime/client.d.ts.map +1 -0
  210. package/dist/realtime/client.js +420 -0
  211. package/dist/realtime/client.js.map +1 -0
  212. package/dist/realtime/index.d.ts +3 -0
  213. package/dist/realtime/snapshot-then-stream.js +144 -0
  214. package/dist/realtime/snapshot-then-stream.js.map +1 -0
  215. package/dist/realtime/types.d.ts +41 -0
  216. package/dist/realtime/types.d.ts.map +1 -0
  217. package/dist/server-client.d.ts +73 -0
  218. package/dist/server-client.d.ts.map +1 -0
  219. package/dist/server-client.js +126 -0
  220. package/dist/server-client.js.map +1 -0
  221. package/dist/server-session.d.ts +4 -0
  222. package/dist/server-session.js +3 -0
  223. package/dist/services/accounts/accounts.codecs.js +17 -0
  224. package/dist/services/accounts/accounts.codecs.js.map +1 -0
  225. package/dist/services/accounts/accounts.d.ts +18 -0
  226. package/dist/services/accounts/accounts.d.ts.map +1 -0
  227. package/dist/services/accounts/accounts.js +27 -0
  228. package/dist/services/accounts/accounts.js.map +1 -0
  229. package/dist/services/accounts/accounts.schemas.d.ts +20 -0
  230. package/dist/services/accounts/accounts.schemas.d.ts.map +1 -0
  231. package/dist/services/accounts/accounts.schemas.js +28 -0
  232. package/dist/services/accounts/accounts.schemas.js.map +1 -0
  233. package/dist/services/accounts/accounts.types.d.ts +2 -0
  234. package/dist/services/accounts/index.d.ts +3 -0
  235. package/dist/services/address-book/address-book.codecs.d.ts +1 -0
  236. package/dist/services/address-book/address-book.codecs.js +61 -0
  237. package/dist/services/address-book/address-book.codecs.js.map +1 -0
  238. package/dist/services/address-book/address-book.d.ts +95 -0
  239. package/dist/services/address-book/address-book.d.ts.map +1 -0
  240. package/dist/services/address-book/address-book.js +166 -0
  241. package/dist/services/address-book/address-book.js.map +1 -0
  242. package/dist/services/address-book/address-book.schemas.d.ts +1140 -0
  243. package/dist/services/address-book/address-book.schemas.d.ts.map +1 -0
  244. package/dist/services/address-book/address-book.schemas.js +343 -0
  245. package/dist/services/address-book/address-book.schemas.js.map +1 -0
  246. package/dist/services/address-book/address-book.types.d.ts +2 -0
  247. package/dist/services/address-book/index.d.ts +4 -0
  248. package/dist/services/api-keys/api-keys.codecs.js +24 -0
  249. package/dist/services/api-keys/api-keys.codecs.js.map +1 -0
  250. package/dist/services/api-keys/api-keys.d.ts +62 -0
  251. package/dist/services/api-keys/api-keys.d.ts.map +1 -0
  252. package/dist/services/api-keys/api-keys.js +104 -0
  253. package/dist/services/api-keys/api-keys.js.map +1 -0
  254. package/dist/services/api-keys/api-keys.schemas.d.ts +181 -0
  255. package/dist/services/api-keys/api-keys.schemas.d.ts.map +1 -0
  256. package/dist/services/api-keys/api-keys.schemas.js +111 -0
  257. package/dist/services/api-keys/api-keys.schemas.js.map +1 -0
  258. package/dist/services/api-keys/api-keys.types.d.ts +2 -0
  259. package/dist/services/api-keys/index.d.ts +3 -0
  260. package/dist/services/auth/account-signer-auth.d.ts +131 -0
  261. package/dist/services/auth/account-signer-auth.d.ts.map +1 -0
  262. package/dist/services/auth/account-signer-auth.js +337 -0
  263. package/dist/services/auth/account-signer-auth.js.map +1 -0
  264. package/dist/services/auth/auth.d.ts +91 -0
  265. package/dist/services/auth/auth.d.ts.map +1 -0
  266. package/dist/services/auth/auth.js +71 -0
  267. package/dist/services/auth/auth.js.map +1 -0
  268. package/dist/services/auth/auth.types.d.ts +3 -0
  269. package/dist/services/auth/cookie-constants.d.ts +6 -0
  270. package/dist/services/auth/cookie-constants.d.ts.map +1 -0
  271. package/dist/services/auth/cookie-constants.js +8 -0
  272. package/dist/services/auth/cookie-constants.js.map +1 -0
  273. package/dist/services/auth/profile/profile.d.ts +35 -0
  274. package/dist/services/auth/profile/profile.d.ts.map +1 -0
  275. package/dist/services/auth/profile/profile.js +61 -0
  276. package/dist/services/auth/profile/profile.js.map +1 -0
  277. package/dist/services/auth/profile/profile.schemas.d.ts +58 -0
  278. package/dist/services/auth/profile/profile.schemas.d.ts.map +1 -0
  279. package/dist/services/auth/profile/profile.schemas.js +39 -0
  280. package/dist/services/auth/profile/profile.schemas.js.map +1 -0
  281. package/dist/services/auth/profile/profile.types.d.ts +2 -0
  282. package/dist/services/auth/session-codec.js +22 -0
  283. package/dist/services/auth/session-codec.js.map +1 -0
  284. package/dist/services/auth/session.d.ts +51 -0
  285. package/dist/services/auth/session.d.ts.map +1 -0
  286. package/dist/services/auth/session.js +200 -0
  287. package/dist/services/auth/session.js.map +1 -0
  288. package/dist/services/auth/session.schemas.js +41 -0
  289. package/dist/services/auth/session.schemas.js.map +1 -0
  290. package/dist/services/auth/session.types.d.ts +70 -0
  291. package/dist/services/auth/session.types.d.ts.map +1 -0
  292. package/dist/services/auth/token-storage.d.ts +27 -0
  293. package/dist/services/auth/token-storage.d.ts.map +1 -0
  294. package/dist/services/auth/token-storage.js +61 -0
  295. package/dist/services/auth/token-storage.js.map +1 -0
  296. package/dist/services/balances/balances.codecs.js +29 -0
  297. package/dist/services/balances/balances.codecs.js.map +1 -0
  298. package/dist/services/balances/balances.d.ts +39 -0
  299. package/dist/services/balances/balances.d.ts.map +1 -0
  300. package/dist/services/balances/balances.js +85 -0
  301. package/dist/services/balances/balances.js.map +1 -0
  302. package/dist/services/balances/balances.merge.d.ts +9 -0
  303. package/dist/services/balances/balances.merge.d.ts.map +1 -0
  304. package/dist/services/balances/balances.merge.js +31 -0
  305. package/dist/services/balances/balances.merge.js.map +1 -0
  306. package/dist/services/balances/balances.schemas.d.ts +265 -0
  307. package/dist/services/balances/balances.schemas.d.ts.map +1 -0
  308. package/dist/services/balances/balances.schemas.js +167 -0
  309. package/dist/services/balances/balances.schemas.js.map +1 -0
  310. package/dist/services/balances/balances.types.d.ts +2 -0
  311. package/dist/services/balances/index.d.ts +4 -0
  312. package/dist/services/candles/candles.codecs.js +48 -0
  313. package/dist/services/candles/candles.codecs.js.map +1 -0
  314. package/dist/services/candles/candles.d.ts +45 -0
  315. package/dist/services/candles/candles.d.ts.map +1 -0
  316. package/dist/services/candles/candles.js +108 -0
  317. package/dist/services/candles/candles.js.map +1 -0
  318. package/dist/services/candles/candles.schemas.d.ts +182 -0
  319. package/dist/services/candles/candles.schemas.d.ts.map +1 -0
  320. package/dist/services/candles/candles.schemas.js +154 -0
  321. package/dist/services/candles/candles.schemas.js.map +1 -0
  322. package/dist/services/candles/candles.types.d.ts +2 -0
  323. package/dist/services/candles/index.d.ts +3 -0
  324. package/dist/services/chain-analytics/chain-analytics.codecs.d.ts +1 -0
  325. package/dist/services/chain-analytics/chain-analytics.codecs.js +33 -0
  326. package/dist/services/chain-analytics/chain-analytics.codecs.js.map +1 -0
  327. package/dist/services/chain-analytics/chain-analytics.d.ts +27 -0
  328. package/dist/services/chain-analytics/chain-analytics.d.ts.map +1 -0
  329. package/dist/services/chain-analytics/chain-analytics.js +48 -0
  330. package/dist/services/chain-analytics/chain-analytics.js.map +1 -0
  331. package/dist/services/chain-analytics/chain-analytics.schemas.d.ts +192 -0
  332. package/dist/services/chain-analytics/chain-analytics.schemas.d.ts.map +1 -0
  333. package/dist/services/chain-analytics/chain-analytics.schemas.js +100 -0
  334. package/dist/services/chain-analytics/chain-analytics.schemas.js.map +1 -0
  335. package/dist/services/chain-analytics/chain-analytics.types.d.ts +2 -0
  336. package/dist/services/chain-analytics/index.d.ts +4 -0
  337. package/dist/services/deposit/deposit.d.ts +23 -0
  338. package/dist/services/deposit/deposit.d.ts.map +1 -0
  339. package/dist/services/deposit/deposit.js +42 -0
  340. package/dist/services/deposit/deposit.js.map +1 -0
  341. package/dist/services/deposit/deposit.schemas.d.ts +40 -0
  342. package/dist/services/deposit/deposit.schemas.d.ts.map +1 -0
  343. package/dist/services/deposit/deposit.schemas.js +27 -0
  344. package/dist/services/deposit/deposit.schemas.js.map +1 -0
  345. package/dist/services/deposit/deposit.types.d.ts +2 -0
  346. package/dist/services/deposit/index.d.ts +3 -0
  347. package/dist/services/guard-signer/guard-signer.codecs.d.ts +1 -0
  348. package/dist/services/guard-signer/guard-signer.codecs.js +33 -0
  349. package/dist/services/guard-signer/guard-signer.codecs.js.map +1 -0
  350. package/dist/services/guard-signer/guard-signer.d.ts +40 -0
  351. package/dist/services/guard-signer/guard-signer.d.ts.map +1 -0
  352. package/dist/services/guard-signer/guard-signer.js +85 -0
  353. package/dist/services/guard-signer/guard-signer.js.map +1 -0
  354. package/dist/services/guard-signer/guard-signer.schemas.d.ts +269 -0
  355. package/dist/services/guard-signer/guard-signer.schemas.d.ts.map +1 -0
  356. package/dist/services/guard-signer/guard-signer.schemas.js +93 -0
  357. package/dist/services/guard-signer/guard-signer.schemas.js.map +1 -0
  358. package/dist/services/guard-signer/guard-signer.types.d.ts +2 -0
  359. package/dist/services/guard-signer/index.d.ts +4 -0
  360. package/dist/services/heatmap/heatmap.codecs.d.ts +11 -0
  361. package/dist/services/heatmap/heatmap.codecs.d.ts.map +1 -0
  362. package/dist/services/heatmap/heatmap.codecs.js +76 -0
  363. package/dist/services/heatmap/heatmap.codecs.js.map +1 -0
  364. package/dist/services/heatmap/heatmap.d.ts +33 -0
  365. package/dist/services/heatmap/heatmap.d.ts.map +1 -0
  366. package/dist/services/heatmap/heatmap.js +79 -0
  367. package/dist/services/heatmap/heatmap.js.map +1 -0
  368. package/dist/services/heatmap/heatmap.schemas.d.ts +412 -0
  369. package/dist/services/heatmap/heatmap.schemas.d.ts.map +1 -0
  370. package/dist/services/heatmap/heatmap.schemas.js +174 -0
  371. package/dist/services/heatmap/heatmap.schemas.js.map +1 -0
  372. package/dist/services/heatmap/heatmap.types.d.ts +3 -0
  373. package/dist/services/heatmap/index.d.ts +4 -0
  374. package/dist/services/internal-transfers/index.d.ts +3 -0
  375. package/dist/services/internal-transfers/internal-transfers.codecs.js +10 -0
  376. package/dist/services/internal-transfers/internal-transfers.codecs.js.map +1 -0
  377. package/dist/services/internal-transfers/internal-transfers.d.ts +20 -0
  378. package/dist/services/internal-transfers/internal-transfers.d.ts.map +1 -0
  379. package/dist/services/internal-transfers/internal-transfers.js +39 -0
  380. package/dist/services/internal-transfers/internal-transfers.js.map +1 -0
  381. package/dist/services/internal-transfers/internal-transfers.schemas.d.ts +174 -0
  382. package/dist/services/internal-transfers/internal-transfers.schemas.d.ts.map +1 -0
  383. package/dist/services/internal-transfers/internal-transfers.schemas.js +90 -0
  384. package/dist/services/internal-transfers/internal-transfers.schemas.js.map +1 -0
  385. package/dist/services/internal-transfers/internal-transfers.types.d.ts +2 -0
  386. package/dist/services/lifecycle/index.d.ts +4 -0
  387. package/dist/services/lifecycle/lifecycle.codecs.d.ts +23 -0
  388. package/dist/services/lifecycle/lifecycle.codecs.d.ts.map +1 -0
  389. package/dist/services/lifecycle/lifecycle.codecs.js +171 -0
  390. package/dist/services/lifecycle/lifecycle.codecs.js.map +1 -0
  391. package/dist/services/lifecycle/lifecycle.d.ts +42 -0
  392. package/dist/services/lifecycle/lifecycle.d.ts.map +1 -0
  393. package/dist/services/lifecycle/lifecycle.js +87 -0
  394. package/dist/services/lifecycle/lifecycle.js.map +1 -0
  395. package/dist/services/lifecycle/lifecycle.schemas.d.ts +2107 -0
  396. package/dist/services/lifecycle/lifecycle.schemas.d.ts.map +1 -0
  397. package/dist/services/lifecycle/lifecycle.schemas.js +282 -0
  398. package/dist/services/lifecycle/lifecycle.schemas.js.map +1 -0
  399. package/dist/services/lifecycle/lifecycle.types.d.ts +2 -0
  400. package/dist/services/market-data/index.d.ts +4 -0
  401. package/dist/services/market-data/market-data.codecs.js +18 -0
  402. package/dist/services/market-data/market-data.codecs.js.map +1 -0
  403. package/dist/services/market-data/market-data.d.ts +40 -0
  404. package/dist/services/market-data/market-data.d.ts.map +1 -0
  405. package/dist/services/market-data/market-data.js +75 -0
  406. package/dist/services/market-data/market-data.js.map +1 -0
  407. package/dist/services/market-data/market-data.schemas.d.ts +56 -0
  408. package/dist/services/market-data/market-data.schemas.d.ts.map +1 -0
  409. package/dist/services/market-data/market-data.schemas.js +178 -0
  410. package/dist/services/market-data/market-data.schemas.js.map +1 -0
  411. package/dist/services/market-data/market-data.types.d.ts +3 -0
  412. package/dist/services/market-overview/index.d.ts +4 -0
  413. package/dist/services/market-overview/market-overview.codecs.d.ts +1 -0
  414. package/dist/services/market-overview/market-overview.codecs.js +44 -0
  415. package/dist/services/market-overview/market-overview.codecs.js.map +1 -0
  416. package/dist/services/market-overview/market-overview.d.ts +32 -0
  417. package/dist/services/market-overview/market-overview.d.ts.map +1 -0
  418. package/dist/services/market-overview/market-overview.js +100 -0
  419. package/dist/services/market-overview/market-overview.js.map +1 -0
  420. package/dist/services/market-overview/market-overview.schemas.d.ts +85 -0
  421. package/dist/services/market-overview/market-overview.schemas.d.ts.map +1 -0
  422. package/dist/services/market-overview/market-overview.schemas.js +71 -0
  423. package/dist/services/market-overview/market-overview.schemas.js.map +1 -0
  424. package/dist/services/market-overview/market-overview.types.d.ts +2 -0
  425. package/dist/services/mfa/index.d.ts +4 -0
  426. package/dist/services/mfa/mfa.codecs.d.ts +1 -0
  427. package/dist/services/mfa/mfa.codecs.js +44 -0
  428. package/dist/services/mfa/mfa.codecs.js.map +1 -0
  429. package/dist/services/mfa/mfa.d.ts +74 -0
  430. package/dist/services/mfa/mfa.d.ts.map +1 -0
  431. package/dist/services/mfa/mfa.js +139 -0
  432. package/dist/services/mfa/mfa.js.map +1 -0
  433. package/dist/services/mfa/mfa.schemas.d.ts +392 -0
  434. package/dist/services/mfa/mfa.schemas.d.ts.map +1 -0
  435. package/dist/services/mfa/mfa.schemas.js +132 -0
  436. package/dist/services/mfa/mfa.schemas.js.map +1 -0
  437. package/dist/services/mfa/mfa.types.d.ts +2 -0
  438. package/dist/services/orderbook/index.d.ts +3 -0
  439. package/dist/services/orderbook/orderbook.codecs.js +45 -0
  440. package/dist/services/orderbook/orderbook.codecs.js.map +1 -0
  441. package/dist/services/orderbook/orderbook.d.ts +42 -0
  442. package/dist/services/orderbook/orderbook.d.ts.map +1 -0
  443. package/dist/services/orderbook/orderbook.js +193 -0
  444. package/dist/services/orderbook/orderbook.js.map +1 -0
  445. package/dist/services/orderbook/orderbook.schemas.d.ts +68 -0
  446. package/dist/services/orderbook/orderbook.schemas.d.ts.map +1 -0
  447. package/dist/services/orderbook/orderbook.schemas.js +43 -0
  448. package/dist/services/orderbook/orderbook.schemas.js.map +1 -0
  449. package/dist/services/orderbook/orderbook.types.d.ts +3 -0
  450. package/dist/services/orders/index.d.ts +9 -0
  451. package/dist/services/orders/order-enums.codecs.js +85 -0
  452. package/dist/services/orders/order-enums.codecs.js.map +1 -0
  453. package/dist/services/orders/order-errors.schemas.d.ts +7 -0
  454. package/dist/services/orders/order-errors.schemas.d.ts.map +1 -0
  455. package/dist/services/orders/order-errors.schemas.js +20 -0
  456. package/dist/services/orders/order-errors.schemas.js.map +1 -0
  457. package/dist/services/orders/orders-batch.schemas.d.ts +2979 -0
  458. package/dist/services/orders/orders-batch.schemas.d.ts.map +1 -0
  459. package/dist/services/orders/orders-batch.schemas.js +282 -0
  460. package/dist/services/orders/orders-batch.schemas.js.map +1 -0
  461. package/dist/services/orders/orders-identifiers.schemas.js +11 -0
  462. package/dist/services/orders/orders-identifiers.schemas.js.map +1 -0
  463. package/dist/services/orders/orders-input.schemas.d.ts +3738 -0
  464. package/dist/services/orders/orders-input.schemas.d.ts.map +1 -0
  465. package/dist/services/orders/orders-input.schemas.js +267 -0
  466. package/dist/services/orders/orders-input.schemas.js.map +1 -0
  467. package/dist/services/orders/orders-modify.schemas.d.ts +1774 -0
  468. package/dist/services/orders/orders-modify.schemas.d.ts.map +1 -0
  469. package/dist/services/orders/orders-modify.schemas.js +132 -0
  470. package/dist/services/orders/orders-modify.schemas.js.map +1 -0
  471. package/dist/services/orders/orders-output.schemas.d.ts +598 -0
  472. package/dist/services/orders/orders-output.schemas.d.ts.map +1 -0
  473. package/dist/services/orders/orders-output.schemas.js +139 -0
  474. package/dist/services/orders/orders-output.schemas.js.map +1 -0
  475. package/dist/services/orders/orders-risk.schemas.d.ts +1041 -0
  476. package/dist/services/orders/orders-risk.schemas.d.ts.map +1 -0
  477. package/dist/services/orders/orders-risk.schemas.js +251 -0
  478. package/dist/services/orders/orders-risk.schemas.js.map +1 -0
  479. package/dist/services/orders/orders.codecs.js +75 -0
  480. package/dist/services/orders/orders.codecs.js.map +1 -0
  481. package/dist/services/orders/orders.d.ts +88 -0
  482. package/dist/services/orders/orders.d.ts.map +1 -0
  483. package/dist/services/orders/orders.js +242 -0
  484. package/dist/services/orders/orders.js.map +1 -0
  485. package/dist/services/orders/orders.schemas.d.ts +7 -0
  486. package/dist/services/orders/orders.types.d.ts +8 -0
  487. package/dist/services/policies/api-key-policies/api-key-policies.d.ts +39 -0
  488. package/dist/services/policies/api-key-policies/api-key-policies.d.ts.map +1 -0
  489. package/dist/services/policies/api-key-policies/api-key-policies.js +74 -0
  490. package/dist/services/policies/api-key-policies/api-key-policies.js.map +1 -0
  491. package/dist/services/policies/api-key-policies/api-key-policies.schemas.d.ts +392 -0
  492. package/dist/services/policies/api-key-policies/api-key-policies.schemas.d.ts.map +1 -0
  493. package/dist/services/policies/api-key-policies/api-key-policies.schemas.js +169 -0
  494. package/dist/services/policies/api-key-policies/api-key-policies.schemas.js.map +1 -0
  495. package/dist/services/policies/api-key-policies/api-key-policies.types.d.ts +2 -0
  496. package/dist/services/policies/api-key-policies/index.d.ts +3 -0
  497. package/dist/services/policies/policies.types.d.ts +2 -0
  498. package/dist/services/policies/shared.codecs.js +61 -0
  499. package/dist/services/policies/shared.codecs.js.map +1 -0
  500. package/dist/services/policies/shared.d.ts +10 -0
  501. package/dist/services/policies/shared.d.ts.map +1 -0
  502. package/dist/services/policies/shared.js +33 -0
  503. package/dist/services/policies/shared.js.map +1 -0
  504. package/dist/services/policies/subaccount-policies/index.d.ts +3 -0
  505. package/dist/services/policies/subaccount-policies/subaccount-policies.d.ts +50 -0
  506. package/dist/services/policies/subaccount-policies/subaccount-policies.d.ts.map +1 -0
  507. package/dist/services/policies/subaccount-policies/subaccount-policies.js +93 -0
  508. package/dist/services/policies/subaccount-policies/subaccount-policies.js.map +1 -0
  509. package/dist/services/policies/subaccount-policies/subaccount-policies.schemas.d.ts +429 -0
  510. package/dist/services/policies/subaccount-policies/subaccount-policies.schemas.d.ts.map +1 -0
  511. package/dist/services/policies/subaccount-policies/subaccount-policies.schemas.js +300 -0
  512. package/dist/services/policies/subaccount-policies/subaccount-policies.schemas.js.map +1 -0
  513. package/dist/services/policies/subaccount-policies/subaccount-policies.types.d.ts +2 -0
  514. package/dist/services/shared.js +24 -0
  515. package/dist/services/shared.js.map +1 -0
  516. package/dist/services/social-verification/index.d.ts +3 -0
  517. package/dist/services/social-verification/social-verification.codecs.d.ts +1 -0
  518. package/dist/services/social-verification/social-verification.codecs.js +55 -0
  519. package/dist/services/social-verification/social-verification.codecs.js.map +1 -0
  520. package/dist/services/social-verification/social-verification.d.ts +27 -0
  521. package/dist/services/social-verification/social-verification.d.ts.map +1 -0
  522. package/dist/services/social-verification/social-verification.js +43 -0
  523. package/dist/services/social-verification/social-verification.js.map +1 -0
  524. package/dist/services/social-verification/social-verification.schemas.d.ts +96 -0
  525. package/dist/services/social-verification/social-verification.schemas.d.ts.map +1 -0
  526. package/dist/services/social-verification/social-verification.schemas.js +69 -0
  527. package/dist/services/social-verification/social-verification.schemas.js.map +1 -0
  528. package/dist/services/social-verification/social-verification.types.d.ts +2 -0
  529. package/dist/services/subaccount-resolver.d.ts +14 -0
  530. package/dist/services/subaccount-resolver.d.ts.map +1 -0
  531. package/dist/services/subaccount-resolver.js +33 -0
  532. package/dist/services/subaccount-resolver.js.map +1 -0
  533. package/dist/services/subaccounts/index.d.ts +3 -0
  534. package/dist/services/subaccounts/subaccounts.codecs.js +94 -0
  535. package/dist/services/subaccounts/subaccounts.codecs.js.map +1 -0
  536. package/dist/services/subaccounts/subaccounts.d.ts +102 -0
  537. package/dist/services/subaccounts/subaccounts.d.ts.map +1 -0
  538. package/dist/services/subaccounts/subaccounts.js +196 -0
  539. package/dist/services/subaccounts/subaccounts.js.map +1 -0
  540. package/dist/services/subaccounts/subaccounts.schemas.d.ts +257 -0
  541. package/dist/services/subaccounts/subaccounts.schemas.d.ts.map +1 -0
  542. package/dist/services/subaccounts/subaccounts.schemas.js +178 -0
  543. package/dist/services/subaccounts/subaccounts.schemas.js.map +1 -0
  544. package/dist/services/subaccounts/subaccounts.types.d.ts +2 -0
  545. package/dist/services/trades/index.d.ts +3 -0
  546. package/dist/services/trades/trades.codecs.js +10 -0
  547. package/dist/services/trades/trades.codecs.js.map +1 -0
  548. package/dist/services/trades/trades.d.ts +33 -0
  549. package/dist/services/trades/trades.d.ts.map +1 -0
  550. package/dist/services/trades/trades.js +64 -0
  551. package/dist/services/trades/trades.js.map +1 -0
  552. package/dist/services/trades/trades.schemas.d.ts +80 -0
  553. package/dist/services/trades/trades.schemas.d.ts.map +1 -0
  554. package/dist/services/trades/trades.schemas.js +66 -0
  555. package/dist/services/trades/trades.schemas.js.map +1 -0
  556. package/dist/services/trades/trades.types.d.ts +2 -0
  557. package/dist/services/trading-withdraws/index.d.ts +4 -0
  558. package/dist/services/trading-withdraws/trading-withdraws.codecs.d.ts +1 -0
  559. package/dist/services/trading-withdraws/trading-withdraws.codecs.js +10 -0
  560. package/dist/services/trading-withdraws/trading-withdraws.codecs.js.map +1 -0
  561. package/dist/services/trading-withdraws/trading-withdraws.d.ts +124 -0
  562. package/dist/services/trading-withdraws/trading-withdraws.d.ts.map +1 -0
  563. package/dist/services/trading-withdraws/trading-withdraws.js +218 -0
  564. package/dist/services/trading-withdraws/trading-withdraws.js.map +1 -0
  565. package/dist/services/trading-withdraws/trading-withdraws.schemas.d.ts +73 -0
  566. package/dist/services/trading-withdraws/trading-withdraws.schemas.d.ts.map +1 -0
  567. package/dist/services/trading-withdraws/trading-withdraws.schemas.js +95 -0
  568. package/dist/services/trading-withdraws/trading-withdraws.schemas.js.map +1 -0
  569. package/dist/services/trading-withdraws/trading-withdraws.types.d.ts +3 -0
  570. package/dist/services/trailing-oneof-inputs.js +49 -0
  571. package/dist/services/trailing-oneof-inputs.js.map +1 -0
  572. package/dist/services/transfers/index.d.ts +4 -0
  573. package/dist/services/transfers/transfers.codecs.d.ts +6 -0
  574. package/dist/services/transfers/transfers.codecs.d.ts.map +1 -0
  575. package/dist/services/transfers/transfers.codecs.js +15 -0
  576. package/dist/services/transfers/transfers.codecs.js.map +1 -0
  577. package/dist/services/transfers/transfers.d.ts +33 -0
  578. package/dist/services/transfers/transfers.d.ts.map +1 -0
  579. package/dist/services/transfers/transfers.js +63 -0
  580. package/dist/services/transfers/transfers.js.map +1 -0
  581. package/dist/services/transfers/transfers.schemas.d.ts +121 -0
  582. package/dist/services/transfers/transfers.schemas.d.ts.map +1 -0
  583. package/dist/services/transfers/transfers.schemas.js +77 -0
  584. package/dist/services/transfers/transfers.schemas.js.map +1 -0
  585. package/dist/services/transfers/transfers.types.d.ts +3 -0
  586. package/dist/services/triggers/index.d.ts +5 -0
  587. package/dist/services/triggers/trigger-child-order.schemas.js +89 -0
  588. package/dist/services/triggers/trigger-child-order.schemas.js.map +1 -0
  589. package/dist/services/triggers/trigger-input.schemas.d.ts +1009 -0
  590. package/dist/services/triggers/trigger-input.schemas.d.ts.map +1 -0
  591. package/dist/services/triggers/trigger-input.schemas.js +270 -0
  592. package/dist/services/triggers/trigger-input.schemas.js.map +1 -0
  593. package/dist/services/triggers/triggers-output.schemas.d.ts +688 -0
  594. package/dist/services/triggers/triggers-output.schemas.d.ts.map +1 -0
  595. package/dist/services/triggers/triggers-output.schemas.js +372 -0
  596. package/dist/services/triggers/triggers-output.schemas.js.map +1 -0
  597. package/dist/services/triggers/triggers.codecs.js +100 -0
  598. package/dist/services/triggers/triggers.codecs.js.map +1 -0
  599. package/dist/services/triggers/triggers.d.ts +71 -0
  600. package/dist/services/triggers/triggers.d.ts.map +1 -0
  601. package/dist/services/triggers/triggers.js +176 -0
  602. package/dist/services/triggers/triggers.js.map +1 -0
  603. package/dist/services/triggers/triggers.schemas.d.ts +3 -0
  604. package/dist/services/triggers/triggers.types.d.ts +5 -0
  605. package/dist/services/whiteboard/index.d.ts +3 -0
  606. package/dist/services/whiteboard/whiteboard.codecs.js +55 -0
  607. package/dist/services/whiteboard/whiteboard.codecs.js.map +1 -0
  608. package/dist/services/whiteboard/whiteboard.d.ts +42 -0
  609. package/dist/services/whiteboard/whiteboard.d.ts.map +1 -0
  610. package/dist/services/whiteboard/whiteboard.js +76 -0
  611. package/dist/services/whiteboard/whiteboard.js.map +1 -0
  612. package/dist/services/whiteboard/whiteboard.schemas.d.ts +771 -0
  613. package/dist/services/whiteboard/whiteboard.schemas.d.ts.map +1 -0
  614. package/dist/services/whiteboard/whiteboard.schemas.js +133 -0
  615. package/dist/services/whiteboard/whiteboard.schemas.js.map +1 -0
  616. package/dist/services/whiteboard/whiteboard.types.d.ts +2 -0
  617. package/dist/services/zipper/index.d.ts +4 -0
  618. package/dist/services/zipper/zipper.d.ts +28 -0
  619. package/dist/services/zipper/zipper.d.ts.map +1 -0
  620. package/dist/services/zipper/zipper.js +84 -0
  621. package/dist/services/zipper/zipper.js.map +1 -0
  622. package/dist/services/zipper/zipper.schemas.d.ts +13 -0
  623. package/dist/services/zipper/zipper.schemas.d.ts.map +1 -0
  624. package/dist/services/zipper/zipper.schemas.js +89 -0
  625. package/dist/services/zipper/zipper.schemas.js.map +1 -0
  626. package/dist/services/zipper/zipper.types.d.ts +4 -0
  627. package/dist/shared/account-scope.d.ts +17 -0
  628. package/dist/shared/account-scope.d.ts.map +1 -0
  629. package/dist/shared/account-scope.js +14 -0
  630. package/dist/shared/account-scope.js.map +1 -0
  631. package/dist/shared/catalog-config.d.ts +95 -0
  632. package/dist/shared/catalog-config.d.ts.map +1 -0
  633. package/dist/shared/catalog-config.js +12 -0
  634. package/dist/shared/catalog-config.js.map +1 -0
  635. package/dist/shared/connect-error-mapping.d.ts +23 -0
  636. package/dist/shared/connect-error-mapping.d.ts.map +1 -0
  637. package/dist/shared/connect-error-mapping.js +147 -0
  638. package/dist/shared/connect-error-mapping.js.map +1 -0
  639. package/dist/shared/decimal-surface.d.ts +18 -0
  640. package/dist/shared/decimal-surface.d.ts.map +1 -0
  641. package/dist/shared/decimal-surface.js +89 -0
  642. package/dist/shared/decimal-surface.js.map +1 -0
  643. package/dist/shared/errors.d.ts +242 -0
  644. package/dist/shared/errors.d.ts.map +1 -0
  645. package/dist/shared/errors.js +271 -0
  646. package/dist/shared/errors.js.map +1 -0
  647. package/dist/shared/ledger-codes.d.ts +9 -0
  648. package/dist/shared/ledger-codes.d.ts.map +1 -0
  649. package/dist/shared/ledger-codes.js +63 -0
  650. package/dist/shared/ledger-codes.js.map +1 -0
  651. package/dist/shared/proto-enum-codec.js +13 -0
  652. package/dist/shared/proto-enum-codec.js.map +1 -0
  653. package/dist/shared/reconciliation.d.ts +14 -0
  654. package/dist/shared/reconciliation.d.ts.map +1 -0
  655. package/dist/shared/reconciliation.js +30 -0
  656. package/dist/shared/reconciliation.js.map +1 -0
  657. package/dist/shared/request-options.d.ts +10 -0
  658. package/dist/shared/request-options.d.ts.map +1 -0
  659. package/dist/shared/request-options.js +22 -0
  660. package/dist/shared/request-options.js.map +1 -0
  661. package/dist/shared/schemas.js +65 -0
  662. package/dist/shared/schemas.js.map +1 -0
  663. package/dist/shared/subscription-errors.d.ts +14 -0
  664. package/dist/shared/subscription-errors.d.ts.map +1 -0
  665. package/dist/shared/subscription-errors.js +49 -0
  666. package/dist/shared/subscription-errors.js.map +1 -0
  667. package/dist/shared/transports.d.ts +28 -0
  668. package/dist/shared/transports.d.ts.map +1 -0
  669. package/dist/shared/transports.js +111 -0
  670. package/dist/shared/transports.js.map +1 -0
  671. package/dist/shared/types.d.ts +11 -0
  672. package/dist/shared/types.d.ts.map +1 -0
  673. package/dist/smart-account/index.d.ts +2 -0
  674. package/dist/smart-account/index.js +2 -0
  675. package/dist/smart-account/smart-account.d.ts +3093 -0
  676. package/dist/smart-account/smart-account.d.ts.map +1 -0
  677. package/dist/smart-account/smart-account.js +94 -0
  678. package/dist/smart-account/smart-account.js.map +1 -0
  679. package/dist/utils/base58-id.js +110 -0
  680. package/dist/utils/base58-id.js.map +1 -0
  681. package/dist/utils/columnar-time.d.ts +11 -0
  682. package/dist/utils/columnar-time.d.ts.map +1 -0
  683. package/dist/utils/columnar-time.js +30 -0
  684. package/dist/utils/columnar-time.js.map +1 -0
  685. package/dist/utils/connect-mfa-errors.d.ts +23 -0
  686. package/dist/utils/connect-mfa-errors.d.ts.map +1 -0
  687. package/dist/utils/connect-mfa-errors.js +34 -0
  688. package/dist/utils/connect-mfa-errors.js.map +1 -0
  689. package/dist/utils/connect-order-errors.d.ts +9 -0
  690. package/dist/utils/connect-order-errors.d.ts.map +1 -0
  691. package/dist/utils/connect-order-errors.js +20 -0
  692. package/dist/utils/connect-order-errors.js.map +1 -0
  693. package/dist/utils/cookie-es/_utils.js +41 -0
  694. package/dist/utils/cookie-es/_utils.js.map +1 -0
  695. package/dist/utils/cookie-es/cookie/parse.js +53 -0
  696. package/dist/utils/cookie-es/cookie/parse.js.map +1 -0
  697. package/dist/utils/cookie-es/cookie/serialize.js +145 -0
  698. package/dist/utils/cookie-es/cookie/serialize.js.map +1 -0
  699. package/dist/utils/cookies.d.ts +7 -0
  700. package/dist/utils/cookies.d.ts.map +1 -0
  701. package/dist/utils/cookies.js +110 -0
  702. package/dist/utils/cookies.js.map +1 -0
  703. package/dist/utils/errors.d.ts +36 -0
  704. package/dist/utils/errors.d.ts.map +1 -0
  705. package/dist/utils/errors.js +111 -0
  706. package/dist/utils/errors.js.map +1 -0
  707. package/dist/utils/event-emitter.d.ts +31 -0
  708. package/dist/utils/event-emitter.d.ts.map +1 -0
  709. package/dist/utils/event-emitter.js +51 -0
  710. package/dist/utils/event-emitter.js.map +1 -0
  711. package/dist/utils/evm.d.ts +33 -0
  712. package/dist/utils/evm.d.ts.map +1 -0
  713. package/dist/utils/evm.js +53 -0
  714. package/dist/utils/evm.js.map +1 -0
  715. package/dist/utils/is-dev.js +57 -0
  716. package/dist/utils/is-dev.js.map +1 -0
  717. package/dist/utils/jwt.d.ts +8 -0
  718. package/dist/utils/jwt.d.ts.map +1 -0
  719. package/dist/utils/jwt.js +74 -0
  720. package/dist/utils/jwt.js.map +1 -0
  721. package/dist/utils/numbers.js +60 -0
  722. package/dist/utils/numbers.js.map +1 -0
  723. package/dist/utils/proto-patch.js +29 -0
  724. package/dist/utils/proto-patch.js.map +1 -0
  725. package/dist/utils/remove-undefined.js +12 -0
  726. package/dist/utils/remove-undefined.js.map +1 -0
  727. package/dist/utils/streams.js +19 -0
  728. package/dist/utils/streams.js.map +1 -0
  729. package/dist/utils/time.d.ts +22 -0
  730. package/dist/utils/time.d.ts.map +1 -0
  731. package/dist/utils/time.js +71 -0
  732. package/dist/utils/time.js.map +1 -0
  733. package/dist/utils/timestamp.js +52 -0
  734. package/dist/utils/timestamp.js.map +1 -0
  735. package/dist/utils/types.d.ts +6 -0
  736. package/dist/utils/types.d.ts.map +1 -0
  737. package/dist/utils/u128.d.ts +8 -0
  738. package/dist/utils/u128.d.ts.map +1 -0
  739. package/dist/utils/u128.js +43 -0
  740. package/dist/utils/u128.js.map +1 -0
  741. package/dist/wired-services.d.ts +15 -0
  742. package/dist/wired-services.d.ts.map +1 -0
  743. package/dist/wired-services.js +67 -0
  744. package/dist/wired-services.js.map +1 -0
  745. package/package.json +117 -0
@@ -0,0 +1,3738 @@
1
+ import { ErrorCode, FeeAsset, LimitFok, LimitGtc, LimitIoc, MarketIoc, RiskLimitGtc, RiskMarketIoc, SelfTradePreventionMode, Side } from "../../gen/orders/v1/orders_pb.js";
2
+ import { OrderStatus } from "../../gen/orders/v1/orders_read_pb.js";
3
+ import { SdkScales } from "../../shared/decimal-surface.js";
4
+ import * as v from "valibot";
5
+ //#region src/services/orders/orders-input.schemas.d.ts
6
+ declare const OpenOrdersInputSchema: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
7
+ readonly includeAttachedRisk: v.OptionalSchema<v.BooleanSchema<undefined>, true>;
8
+ readonly includeAttachedRiskState: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
9
+ readonly symbolId: v.OptionalSchema<v.ArraySchema<v.NumberSchema<undefined>, undefined>, undefined>;
10
+ readonly side: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<["buy", "sell"], undefined>, undefined>, v.TransformAction<"buy" | "sell" | undefined, Side.BUY | Side.SELL | undefined>]>;
11
+ readonly limit: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
12
+ readonly pageToken: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>;
13
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
14
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
15
+ }, undefined>], undefined>, undefined>;
16
+ }, undefined>, v.TransformAction<{
17
+ includeAttachedRisk: boolean;
18
+ includeAttachedRiskState: boolean;
19
+ symbolId?: number[] | undefined;
20
+ side?: Side.BUY | Side.SELL | undefined;
21
+ limit?: number | undefined;
22
+ pageToken?: string | undefined;
23
+ account?: "active" | "main" | {
24
+ subaccountId: string;
25
+ } | undefined;
26
+ }, {
27
+ subaccountId: bigint | undefined;
28
+ includeAttachedRisk: boolean;
29
+ includeAttachedRiskState: boolean;
30
+ symbolId?: number[] | undefined;
31
+ side?: Side.BUY | Side.SELL | undefined;
32
+ limit?: number | undefined;
33
+ pageToken?: string | undefined;
34
+ }>]>;
35
+ type OpenOrdersInput = v.InferInput<typeof OpenOrdersInputSchema>;
36
+ declare const OrderHistoryInputSchema: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
37
+ readonly includeAttachedRisk: v.OptionalSchema<v.BooleanSchema<undefined>, true>;
38
+ readonly includeAttachedRiskState: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
39
+ readonly status: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["FILLED", "CANCELED", "REJECTED"], undefined>, undefined>, v.TransformAction<"FILLED" | "CANCELED" | "REJECTED" | undefined, OrderStatus.FILLED | OrderStatus.CANCELED | OrderStatus.REJECTED | undefined>]>;
40
+ readonly startTsNs: v.SchemaWithPipe<readonly [v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>, v.TransformAction<string | undefined, bigint | undefined>]>;
41
+ readonly endTsNs: v.SchemaWithPipe<readonly [v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>, v.TransformAction<string | undefined, bigint | undefined>]>;
42
+ readonly symbolId: v.OptionalSchema<v.ArraySchema<v.NumberSchema<undefined>, undefined>, undefined>;
43
+ readonly side: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<["buy", "sell"], undefined>, undefined>, v.TransformAction<"buy" | "sell" | undefined, Side.BUY | Side.SELL | undefined>]>;
44
+ readonly limit: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
45
+ readonly pageToken: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>;
46
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
47
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
48
+ }, undefined>], undefined>, undefined>;
49
+ }, undefined>, v.TransformAction<{
50
+ includeAttachedRisk: boolean;
51
+ includeAttachedRiskState: boolean;
52
+ status?: OrderStatus.FILLED | OrderStatus.CANCELED | OrderStatus.REJECTED | undefined;
53
+ startTsNs?: bigint | undefined;
54
+ endTsNs?: bigint | undefined;
55
+ symbolId?: number[] | undefined;
56
+ side?: Side.BUY | Side.SELL | undefined;
57
+ limit?: number | undefined;
58
+ pageToken?: string | undefined;
59
+ account?: "active" | "main" | {
60
+ subaccountId: string;
61
+ } | undefined;
62
+ }, {
63
+ subaccountId: bigint | undefined;
64
+ includeAttachedRisk: boolean;
65
+ includeAttachedRiskState: boolean;
66
+ status?: OrderStatus.FILLED | OrderStatus.CANCELED | OrderStatus.REJECTED | undefined;
67
+ startTsNs?: bigint | undefined;
68
+ endTsNs?: bigint | undefined;
69
+ symbolId?: number[] | undefined;
70
+ side?: Side.BUY | Side.SELL | undefined;
71
+ limit?: number | undefined;
72
+ pageToken?: string | undefined;
73
+ }>]>;
74
+ type OrderHistoryInput = v.InferInput<typeof OrderHistoryInputSchema>;
75
+ declare function createOrderIntentInputSchema(scales: SdkScales): v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.UnionSchema<[v.StrictObjectSchema<{
76
+ readonly qty: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
77
+ readonly maxQuoteDebit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
78
+ readonly symbol: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
79
+ readonly side: v.SchemaWithPipe<readonly [v.PicklistSchema<["buy", "sell"], undefined>, v.TransformAction<"buy" | "sell", Side.BUY | Side.SELL>]>;
80
+ readonly execution: v.VariantSchema<"type", [v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
81
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
82
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
83
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
84
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
85
+ }, undefined>, v.StrictObjectSchema<{
86
+ readonly kind: v.LiteralSchema<"bps", undefined>;
87
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
88
+ }, undefined>, v.StrictObjectSchema<{
89
+ readonly kind: v.LiteralSchema<"none", undefined>;
90
+ }, undefined>], undefined>, undefined>;
91
+ readonly clientRefPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
92
+ }, undefined>, v.TransformAction<{
93
+ type: "market_ioc";
94
+ maxSlippage?: {
95
+ kind: "bps";
96
+ bps: string | number;
97
+ } | {
98
+ kind: "none";
99
+ } | {
100
+ kind: "slippage";
101
+ slippage: string;
102
+ } | undefined;
103
+ clientRefPrice?: string | undefined;
104
+ }, {
105
+ case: "marketIoc";
106
+ value: MarketIoc;
107
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
108
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
109
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
110
+ readonly postOnly: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
111
+ }, undefined>, v.TransformAction<{
112
+ type: "limit_gtc";
113
+ price: string;
114
+ postOnly: boolean;
115
+ }, {
116
+ case: "limitGtc";
117
+ value: LimitGtc;
118
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
119
+ readonly type: v.LiteralSchema<"limit_ioc", undefined>;
120
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
121
+ }, undefined>, v.TransformAction<{
122
+ type: "limit_ioc";
123
+ price: string;
124
+ }, {
125
+ case: "limitIoc";
126
+ value: LimitIoc;
127
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
128
+ readonly type: v.LiteralSchema<"limit_fok", undefined>;
129
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
130
+ }, undefined>, v.TransformAction<{
131
+ type: "limit_fok";
132
+ price: string;
133
+ }, {
134
+ case: "limitFok";
135
+ value: LimitFok;
136
+ }>]>], undefined>;
137
+ readonly clientOrderId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 36, undefined>, v.RegexAction<string, "clientOrderId has an invalid format">]>, undefined>;
138
+ readonly feeAsset: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["quote", "base"], undefined>, undefined>, v.TransformAction<"quote" | "base" | undefined, FeeAsset.QUOTE | FeeAsset.BASE | undefined>]>;
139
+ readonly selfTradePreventionMode: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["expire_taker", "expire_maker", "expire_both"], undefined>, undefined>, v.TransformAction<"expire_taker" | "expire_maker" | "expire_both" | undefined, SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined>]>;
140
+ readonly risk: v.SchemaWithPipe<readonly [v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
141
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
142
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
143
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
144
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
145
+ }, undefined>, v.StrictObjectSchema<{
146
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
147
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
148
+ }, undefined>], undefined>;
149
+ }, undefined>, v.TransformAction<{
150
+ triggerPrice: string;
151
+ execution: {
152
+ type: "market_ioc";
153
+ } | {
154
+ type: "limit_gtc";
155
+ price: string;
156
+ };
157
+ }, {
158
+ triggerPriceTicks: bigint;
159
+ child: {
160
+ execution: {
161
+ value: RiskMarketIoc;
162
+ case: "marketIoc";
163
+ } | {
164
+ value: RiskLimitGtc;
165
+ case: "limitGtc";
166
+ };
167
+ };
168
+ }>]>;
169
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
170
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
171
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
172
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
173
+ }, undefined>, v.StrictObjectSchema<{
174
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
175
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
176
+ }, undefined>], undefined>;
177
+ }, undefined>, v.TransformAction<{
178
+ triggerPrice: string;
179
+ execution: {
180
+ type: "market_ioc";
181
+ } | {
182
+ type: "limit_gtc";
183
+ price: string;
184
+ };
185
+ }, {
186
+ triggerPriceTicks: bigint;
187
+ child: {
188
+ execution: {
189
+ value: RiskMarketIoc;
190
+ case: "marketIoc";
191
+ } | {
192
+ value: RiskLimitGtc;
193
+ case: "limitGtc";
194
+ };
195
+ };
196
+ }>]>;
197
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
198
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
199
+ }, undefined>, v.StrictObjectSchema<{
200
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
201
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
202
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
203
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
204
+ }, undefined>, v.StrictObjectSchema<{
205
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
206
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
207
+ }, undefined>], undefined>;
208
+ }, undefined>, v.TransformAction<{
209
+ triggerPrice: string;
210
+ execution: {
211
+ type: "market_ioc";
212
+ } | {
213
+ type: "limit_gtc";
214
+ price: string;
215
+ };
216
+ }, {
217
+ triggerPriceTicks: bigint;
218
+ child: {
219
+ execution: {
220
+ value: RiskMarketIoc;
221
+ case: "marketIoc";
222
+ } | {
223
+ value: RiskLimitGtc;
224
+ case: "limitGtc";
225
+ };
226
+ };
227
+ }>]>;
228
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
229
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
230
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
231
+ readonly kind: v.LiteralSchema<"distance", undefined>;
232
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
233
+ }, undefined>, v.StrictObjectSchema<{
234
+ readonly kind: v.LiteralSchema<"bps", undefined>;
235
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
236
+ }, undefined>, v.StrictObjectSchema<{
237
+ readonly kind: v.LiteralSchema<"none", undefined>;
238
+ }, undefined>], undefined>;
239
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
240
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
241
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
242
+ }, undefined>, v.StrictObjectSchema<{
243
+ readonly kind: v.LiteralSchema<"bps", undefined>;
244
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
245
+ }, undefined>, v.StrictObjectSchema<{
246
+ readonly kind: v.LiteralSchema<"none", undefined>;
247
+ }, undefined>], undefined>, undefined>;
248
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
249
+ }, undefined>, v.TransformAction<{
250
+ trailingDistance: {
251
+ kind: "bps";
252
+ bps: string | number;
253
+ } | {
254
+ kind: "none";
255
+ } | {
256
+ kind: "distance";
257
+ distance: string;
258
+ };
259
+ maxSlippage?: {
260
+ kind: "bps";
261
+ bps: string | number;
262
+ } | {
263
+ kind: "none";
264
+ } | {
265
+ kind: "slippage";
266
+ slippage: string;
267
+ } | undefined;
268
+ activationPrice?: string | undefined;
269
+ }, {
270
+ trailingDistance: {
271
+ value: bigint;
272
+ case: "trailingDistanceTicks";
273
+ } | {
274
+ value: number;
275
+ case: "trailingDistanceBps";
276
+ } | {
277
+ case: undefined;
278
+ value?: undefined;
279
+ };
280
+ maxSlippage: {
281
+ value: number;
282
+ case: "maxSlippageTicks";
283
+ } | {
284
+ value: number;
285
+ case: "maxSlippageBps";
286
+ } | {
287
+ case: undefined;
288
+ value?: undefined;
289
+ };
290
+ activationPriceTicks: bigint;
291
+ }>]>;
292
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
293
+ }, undefined>, v.StrictObjectSchema<{
294
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
295
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
296
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
297
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
298
+ }, undefined>, v.StrictObjectSchema<{
299
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
300
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
301
+ }, undefined>], undefined>;
302
+ }, undefined>, v.TransformAction<{
303
+ triggerPrice: string;
304
+ execution: {
305
+ type: "market_ioc";
306
+ } | {
307
+ type: "limit_gtc";
308
+ price: string;
309
+ };
310
+ }, {
311
+ triggerPriceTicks: bigint;
312
+ child: {
313
+ execution: {
314
+ value: RiskMarketIoc;
315
+ case: "marketIoc";
316
+ } | {
317
+ value: RiskLimitGtc;
318
+ case: "limitGtc";
319
+ };
320
+ };
321
+ }>]>;
322
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
323
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
324
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
325
+ }, undefined>, v.StrictObjectSchema<{
326
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
327
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
328
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
329
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
330
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
331
+ }, undefined>, v.StrictObjectSchema<{
332
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
333
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
334
+ }, undefined>], undefined>;
335
+ }, undefined>, v.TransformAction<{
336
+ triggerPrice: string;
337
+ execution: {
338
+ type: "market_ioc";
339
+ } | {
340
+ type: "limit_gtc";
341
+ price: string;
342
+ };
343
+ }, {
344
+ triggerPriceTicks: bigint;
345
+ child: {
346
+ execution: {
347
+ value: RiskMarketIoc;
348
+ case: "marketIoc";
349
+ } | {
350
+ value: RiskLimitGtc;
351
+ case: "limitGtc";
352
+ };
353
+ };
354
+ }>]>;
355
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
356
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
357
+ }, undefined>, v.StrictObjectSchema<{
358
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
359
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
360
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
361
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
362
+ readonly kind: v.LiteralSchema<"distance", undefined>;
363
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
364
+ }, undefined>, v.StrictObjectSchema<{
365
+ readonly kind: v.LiteralSchema<"bps", undefined>;
366
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
367
+ }, undefined>, v.StrictObjectSchema<{
368
+ readonly kind: v.LiteralSchema<"none", undefined>;
369
+ }, undefined>], undefined>;
370
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
371
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
372
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
373
+ }, undefined>, v.StrictObjectSchema<{
374
+ readonly kind: v.LiteralSchema<"bps", undefined>;
375
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
376
+ }, undefined>, v.StrictObjectSchema<{
377
+ readonly kind: v.LiteralSchema<"none", undefined>;
378
+ }, undefined>], undefined>, undefined>;
379
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
380
+ }, undefined>, v.TransformAction<{
381
+ trailingDistance: {
382
+ kind: "bps";
383
+ bps: string | number;
384
+ } | {
385
+ kind: "none";
386
+ } | {
387
+ kind: "distance";
388
+ distance: string;
389
+ };
390
+ maxSlippage?: {
391
+ kind: "bps";
392
+ bps: string | number;
393
+ } | {
394
+ kind: "none";
395
+ } | {
396
+ kind: "slippage";
397
+ slippage: string;
398
+ } | undefined;
399
+ activationPrice?: string | undefined;
400
+ }, {
401
+ trailingDistance: {
402
+ value: bigint;
403
+ case: "trailingDistanceTicks";
404
+ } | {
405
+ value: number;
406
+ case: "trailingDistanceBps";
407
+ } | {
408
+ case: undefined;
409
+ value?: undefined;
410
+ };
411
+ maxSlippage: {
412
+ value: number;
413
+ case: "maxSlippageTicks";
414
+ } | {
415
+ value: number;
416
+ case: "maxSlippageBps";
417
+ } | {
418
+ case: undefined;
419
+ value?: undefined;
420
+ };
421
+ activationPriceTicks: bigint;
422
+ }>]>;
423
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
424
+ }, undefined>], undefined>, undefined>, v.TransformAction<{
425
+ takeProfit: {
426
+ triggerPriceTicks: bigint;
427
+ child: {
428
+ execution: {
429
+ value: RiskMarketIoc;
430
+ case: "marketIoc";
431
+ } | {
432
+ value: RiskLimitGtc;
433
+ case: "limitGtc";
434
+ };
435
+ };
436
+ };
437
+ stopLoss: {
438
+ triggerPriceTicks: bigint;
439
+ child: {
440
+ execution: {
441
+ value: RiskMarketIoc;
442
+ case: "marketIoc";
443
+ } | {
444
+ value: RiskLimitGtc;
445
+ case: "limitGtc";
446
+ };
447
+ };
448
+ };
449
+ trailingStop?: undefined;
450
+ oco?: boolean | undefined;
451
+ } | {
452
+ takeProfit: {
453
+ triggerPriceTicks: bigint;
454
+ child: {
455
+ execution: {
456
+ value: RiskMarketIoc;
457
+ case: "marketIoc";
458
+ } | {
459
+ value: RiskLimitGtc;
460
+ case: "limitGtc";
461
+ };
462
+ };
463
+ };
464
+ stopLoss?: undefined;
465
+ trailingStop: {
466
+ trailingDistance: {
467
+ value: bigint;
468
+ case: "trailingDistanceTicks";
469
+ } | {
470
+ value: number;
471
+ case: "trailingDistanceBps";
472
+ } | {
473
+ case: undefined;
474
+ value?: undefined;
475
+ };
476
+ maxSlippage: {
477
+ value: number;
478
+ case: "maxSlippageTicks";
479
+ } | {
480
+ value: number;
481
+ case: "maxSlippageBps";
482
+ } | {
483
+ case: undefined;
484
+ value?: undefined;
485
+ };
486
+ activationPriceTicks: bigint;
487
+ };
488
+ oco?: boolean | undefined;
489
+ } | {
490
+ takeProfit: {
491
+ triggerPriceTicks: bigint;
492
+ child: {
493
+ execution: {
494
+ value: RiskMarketIoc;
495
+ case: "marketIoc";
496
+ } | {
497
+ value: RiskLimitGtc;
498
+ case: "limitGtc";
499
+ };
500
+ };
501
+ };
502
+ stopLoss?: undefined;
503
+ trailingStop?: undefined;
504
+ oco?: boolean | undefined;
505
+ } | {
506
+ takeProfit?: undefined;
507
+ stopLoss: {
508
+ triggerPriceTicks: bigint;
509
+ child: {
510
+ execution: {
511
+ value: RiskMarketIoc;
512
+ case: "marketIoc";
513
+ } | {
514
+ value: RiskLimitGtc;
515
+ case: "limitGtc";
516
+ };
517
+ };
518
+ };
519
+ trailingStop?: undefined;
520
+ oco?: boolean | undefined;
521
+ } | {
522
+ takeProfit?: undefined;
523
+ stopLoss?: undefined;
524
+ trailingStop: {
525
+ trailingDistance: {
526
+ value: bigint;
527
+ case: "trailingDistanceTicks";
528
+ } | {
529
+ value: number;
530
+ case: "trailingDistanceBps";
531
+ } | {
532
+ case: undefined;
533
+ value?: undefined;
534
+ };
535
+ maxSlippage: {
536
+ value: number;
537
+ case: "maxSlippageTicks";
538
+ } | {
539
+ value: number;
540
+ case: "maxSlippageBps";
541
+ } | {
542
+ case: undefined;
543
+ value?: undefined;
544
+ };
545
+ activationPriceTicks: bigint;
546
+ };
547
+ oco?: boolean | undefined;
548
+ } | undefined, {
549
+ takeProfit: {
550
+ triggerPriceTicks: bigint;
551
+ child: {
552
+ execution: {
553
+ value: RiskMarketIoc;
554
+ case: "marketIoc";
555
+ } | {
556
+ value: RiskLimitGtc;
557
+ case: "limitGtc";
558
+ };
559
+ };
560
+ } | undefined;
561
+ stopLeg: {
562
+ readonly case: "stopLoss";
563
+ readonly value: {
564
+ triggerPriceTicks: bigint;
565
+ child: {
566
+ execution: {
567
+ value: RiskMarketIoc;
568
+ case: "marketIoc";
569
+ } | {
570
+ value: RiskLimitGtc;
571
+ case: "limitGtc";
572
+ };
573
+ };
574
+ };
575
+ } | {
576
+ readonly case: "trailingStop";
577
+ readonly value: {
578
+ trailingDistance: {
579
+ value: bigint;
580
+ case: "trailingDistanceTicks";
581
+ } | {
582
+ value: number;
583
+ case: "trailingDistanceBps";
584
+ } | {
585
+ case: undefined;
586
+ value?: undefined;
587
+ };
588
+ maxSlippage: {
589
+ value: number;
590
+ case: "maxSlippageTicks";
591
+ } | {
592
+ value: number;
593
+ case: "maxSlippageBps";
594
+ } | {
595
+ case: undefined;
596
+ value?: undefined;
597
+ };
598
+ activationPriceTicks: bigint;
599
+ };
600
+ } | {
601
+ readonly case: undefined;
602
+ readonly value: undefined;
603
+ };
604
+ oco: boolean;
605
+ } | undefined>]>;
606
+ }, undefined>, v.StrictObjectSchema<{
607
+ readonly qty: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
608
+ readonly maxQuoteDebit: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
609
+ readonly symbol: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
610
+ readonly side: v.SchemaWithPipe<readonly [v.PicklistSchema<["buy", "sell"], undefined>, v.TransformAction<"buy" | "sell", Side.BUY | Side.SELL>]>;
611
+ readonly execution: v.VariantSchema<"type", [v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
612
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
613
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
614
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
615
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
616
+ }, undefined>, v.StrictObjectSchema<{
617
+ readonly kind: v.LiteralSchema<"bps", undefined>;
618
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
619
+ }, undefined>, v.StrictObjectSchema<{
620
+ readonly kind: v.LiteralSchema<"none", undefined>;
621
+ }, undefined>], undefined>, undefined>;
622
+ readonly clientRefPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
623
+ }, undefined>, v.TransformAction<{
624
+ type: "market_ioc";
625
+ maxSlippage?: {
626
+ kind: "bps";
627
+ bps: string | number;
628
+ } | {
629
+ kind: "none";
630
+ } | {
631
+ kind: "slippage";
632
+ slippage: string;
633
+ } | undefined;
634
+ clientRefPrice?: string | undefined;
635
+ }, {
636
+ case: "marketIoc";
637
+ value: MarketIoc;
638
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
639
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
640
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
641
+ readonly postOnly: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
642
+ }, undefined>, v.TransformAction<{
643
+ type: "limit_gtc";
644
+ price: string;
645
+ postOnly: boolean;
646
+ }, {
647
+ case: "limitGtc";
648
+ value: LimitGtc;
649
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
650
+ readonly type: v.LiteralSchema<"limit_ioc", undefined>;
651
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
652
+ }, undefined>, v.TransformAction<{
653
+ type: "limit_ioc";
654
+ price: string;
655
+ }, {
656
+ case: "limitIoc";
657
+ value: LimitIoc;
658
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
659
+ readonly type: v.LiteralSchema<"limit_fok", undefined>;
660
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
661
+ }, undefined>, v.TransformAction<{
662
+ type: "limit_fok";
663
+ price: string;
664
+ }, {
665
+ case: "limitFok";
666
+ value: LimitFok;
667
+ }>]>], undefined>;
668
+ readonly clientOrderId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 36, undefined>, v.RegexAction<string, "clientOrderId has an invalid format">]>, undefined>;
669
+ readonly feeAsset: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["quote", "base"], undefined>, undefined>, v.TransformAction<"quote" | "base" | undefined, FeeAsset.QUOTE | FeeAsset.BASE | undefined>]>;
670
+ readonly selfTradePreventionMode: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["expire_taker", "expire_maker", "expire_both"], undefined>, undefined>, v.TransformAction<"expire_taker" | "expire_maker" | "expire_both" | undefined, SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined>]>;
671
+ readonly risk: v.SchemaWithPipe<readonly [v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
672
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
673
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
674
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
675
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
676
+ }, undefined>, v.StrictObjectSchema<{
677
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
678
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
679
+ }, undefined>], undefined>;
680
+ }, undefined>, v.TransformAction<{
681
+ triggerPrice: string;
682
+ execution: {
683
+ type: "market_ioc";
684
+ } | {
685
+ type: "limit_gtc";
686
+ price: string;
687
+ };
688
+ }, {
689
+ triggerPriceTicks: bigint;
690
+ child: {
691
+ execution: {
692
+ value: RiskMarketIoc;
693
+ case: "marketIoc";
694
+ } | {
695
+ value: RiskLimitGtc;
696
+ case: "limitGtc";
697
+ };
698
+ };
699
+ }>]>;
700
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
701
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
702
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
703
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
704
+ }, undefined>, v.StrictObjectSchema<{
705
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
706
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
707
+ }, undefined>], undefined>;
708
+ }, undefined>, v.TransformAction<{
709
+ triggerPrice: string;
710
+ execution: {
711
+ type: "market_ioc";
712
+ } | {
713
+ type: "limit_gtc";
714
+ price: string;
715
+ };
716
+ }, {
717
+ triggerPriceTicks: bigint;
718
+ child: {
719
+ execution: {
720
+ value: RiskMarketIoc;
721
+ case: "marketIoc";
722
+ } | {
723
+ value: RiskLimitGtc;
724
+ case: "limitGtc";
725
+ };
726
+ };
727
+ }>]>;
728
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
729
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
730
+ }, undefined>, v.StrictObjectSchema<{
731
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
732
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
733
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
734
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
735
+ }, undefined>, v.StrictObjectSchema<{
736
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
737
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
738
+ }, undefined>], undefined>;
739
+ }, undefined>, v.TransformAction<{
740
+ triggerPrice: string;
741
+ execution: {
742
+ type: "market_ioc";
743
+ } | {
744
+ type: "limit_gtc";
745
+ price: string;
746
+ };
747
+ }, {
748
+ triggerPriceTicks: bigint;
749
+ child: {
750
+ execution: {
751
+ value: RiskMarketIoc;
752
+ case: "marketIoc";
753
+ } | {
754
+ value: RiskLimitGtc;
755
+ case: "limitGtc";
756
+ };
757
+ };
758
+ }>]>;
759
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
760
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
761
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
762
+ readonly kind: v.LiteralSchema<"distance", undefined>;
763
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
764
+ }, undefined>, v.StrictObjectSchema<{
765
+ readonly kind: v.LiteralSchema<"bps", undefined>;
766
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
767
+ }, undefined>, v.StrictObjectSchema<{
768
+ readonly kind: v.LiteralSchema<"none", undefined>;
769
+ }, undefined>], undefined>;
770
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
771
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
772
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
773
+ }, undefined>, v.StrictObjectSchema<{
774
+ readonly kind: v.LiteralSchema<"bps", undefined>;
775
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
776
+ }, undefined>, v.StrictObjectSchema<{
777
+ readonly kind: v.LiteralSchema<"none", undefined>;
778
+ }, undefined>], undefined>, undefined>;
779
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
780
+ }, undefined>, v.TransformAction<{
781
+ trailingDistance: {
782
+ kind: "bps";
783
+ bps: string | number;
784
+ } | {
785
+ kind: "none";
786
+ } | {
787
+ kind: "distance";
788
+ distance: string;
789
+ };
790
+ maxSlippage?: {
791
+ kind: "bps";
792
+ bps: string | number;
793
+ } | {
794
+ kind: "none";
795
+ } | {
796
+ kind: "slippage";
797
+ slippage: string;
798
+ } | undefined;
799
+ activationPrice?: string | undefined;
800
+ }, {
801
+ trailingDistance: {
802
+ value: bigint;
803
+ case: "trailingDistanceTicks";
804
+ } | {
805
+ value: number;
806
+ case: "trailingDistanceBps";
807
+ } | {
808
+ case: undefined;
809
+ value?: undefined;
810
+ };
811
+ maxSlippage: {
812
+ value: number;
813
+ case: "maxSlippageTicks";
814
+ } | {
815
+ value: number;
816
+ case: "maxSlippageBps";
817
+ } | {
818
+ case: undefined;
819
+ value?: undefined;
820
+ };
821
+ activationPriceTicks: bigint;
822
+ }>]>;
823
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
824
+ }, undefined>, v.StrictObjectSchema<{
825
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
826
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
827
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
828
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
829
+ }, undefined>, v.StrictObjectSchema<{
830
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
831
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
832
+ }, undefined>], undefined>;
833
+ }, undefined>, v.TransformAction<{
834
+ triggerPrice: string;
835
+ execution: {
836
+ type: "market_ioc";
837
+ } | {
838
+ type: "limit_gtc";
839
+ price: string;
840
+ };
841
+ }, {
842
+ triggerPriceTicks: bigint;
843
+ child: {
844
+ execution: {
845
+ value: RiskMarketIoc;
846
+ case: "marketIoc";
847
+ } | {
848
+ value: RiskLimitGtc;
849
+ case: "limitGtc";
850
+ };
851
+ };
852
+ }>]>;
853
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
854
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
855
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
856
+ }, undefined>, v.StrictObjectSchema<{
857
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
858
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
859
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
860
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
861
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
862
+ }, undefined>, v.StrictObjectSchema<{
863
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
864
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
865
+ }, undefined>], undefined>;
866
+ }, undefined>, v.TransformAction<{
867
+ triggerPrice: string;
868
+ execution: {
869
+ type: "market_ioc";
870
+ } | {
871
+ type: "limit_gtc";
872
+ price: string;
873
+ };
874
+ }, {
875
+ triggerPriceTicks: bigint;
876
+ child: {
877
+ execution: {
878
+ value: RiskMarketIoc;
879
+ case: "marketIoc";
880
+ } | {
881
+ value: RiskLimitGtc;
882
+ case: "limitGtc";
883
+ };
884
+ };
885
+ }>]>;
886
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
887
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
888
+ }, undefined>, v.StrictObjectSchema<{
889
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
890
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
891
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
892
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
893
+ readonly kind: v.LiteralSchema<"distance", undefined>;
894
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
895
+ }, undefined>, v.StrictObjectSchema<{
896
+ readonly kind: v.LiteralSchema<"bps", undefined>;
897
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
898
+ }, undefined>, v.StrictObjectSchema<{
899
+ readonly kind: v.LiteralSchema<"none", undefined>;
900
+ }, undefined>], undefined>;
901
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
902
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
903
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
904
+ }, undefined>, v.StrictObjectSchema<{
905
+ readonly kind: v.LiteralSchema<"bps", undefined>;
906
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
907
+ }, undefined>, v.StrictObjectSchema<{
908
+ readonly kind: v.LiteralSchema<"none", undefined>;
909
+ }, undefined>], undefined>, undefined>;
910
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
911
+ }, undefined>, v.TransformAction<{
912
+ trailingDistance: {
913
+ kind: "bps";
914
+ bps: string | number;
915
+ } | {
916
+ kind: "none";
917
+ } | {
918
+ kind: "distance";
919
+ distance: string;
920
+ };
921
+ maxSlippage?: {
922
+ kind: "bps";
923
+ bps: string | number;
924
+ } | {
925
+ kind: "none";
926
+ } | {
927
+ kind: "slippage";
928
+ slippage: string;
929
+ } | undefined;
930
+ activationPrice?: string | undefined;
931
+ }, {
932
+ trailingDistance: {
933
+ value: bigint;
934
+ case: "trailingDistanceTicks";
935
+ } | {
936
+ value: number;
937
+ case: "trailingDistanceBps";
938
+ } | {
939
+ case: undefined;
940
+ value?: undefined;
941
+ };
942
+ maxSlippage: {
943
+ value: number;
944
+ case: "maxSlippageTicks";
945
+ } | {
946
+ value: number;
947
+ case: "maxSlippageBps";
948
+ } | {
949
+ case: undefined;
950
+ value?: undefined;
951
+ };
952
+ activationPriceTicks: bigint;
953
+ }>]>;
954
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
955
+ }, undefined>], undefined>, undefined>, v.TransformAction<{
956
+ takeProfit: {
957
+ triggerPriceTicks: bigint;
958
+ child: {
959
+ execution: {
960
+ value: RiskMarketIoc;
961
+ case: "marketIoc";
962
+ } | {
963
+ value: RiskLimitGtc;
964
+ case: "limitGtc";
965
+ };
966
+ };
967
+ };
968
+ stopLoss: {
969
+ triggerPriceTicks: bigint;
970
+ child: {
971
+ execution: {
972
+ value: RiskMarketIoc;
973
+ case: "marketIoc";
974
+ } | {
975
+ value: RiskLimitGtc;
976
+ case: "limitGtc";
977
+ };
978
+ };
979
+ };
980
+ trailingStop?: undefined;
981
+ oco?: boolean | undefined;
982
+ } | {
983
+ takeProfit: {
984
+ triggerPriceTicks: bigint;
985
+ child: {
986
+ execution: {
987
+ value: RiskMarketIoc;
988
+ case: "marketIoc";
989
+ } | {
990
+ value: RiskLimitGtc;
991
+ case: "limitGtc";
992
+ };
993
+ };
994
+ };
995
+ stopLoss?: undefined;
996
+ trailingStop: {
997
+ trailingDistance: {
998
+ value: bigint;
999
+ case: "trailingDistanceTicks";
1000
+ } | {
1001
+ value: number;
1002
+ case: "trailingDistanceBps";
1003
+ } | {
1004
+ case: undefined;
1005
+ value?: undefined;
1006
+ };
1007
+ maxSlippage: {
1008
+ value: number;
1009
+ case: "maxSlippageTicks";
1010
+ } | {
1011
+ value: number;
1012
+ case: "maxSlippageBps";
1013
+ } | {
1014
+ case: undefined;
1015
+ value?: undefined;
1016
+ };
1017
+ activationPriceTicks: bigint;
1018
+ };
1019
+ oco?: boolean | undefined;
1020
+ } | {
1021
+ takeProfit: {
1022
+ triggerPriceTicks: bigint;
1023
+ child: {
1024
+ execution: {
1025
+ value: RiskMarketIoc;
1026
+ case: "marketIoc";
1027
+ } | {
1028
+ value: RiskLimitGtc;
1029
+ case: "limitGtc";
1030
+ };
1031
+ };
1032
+ };
1033
+ stopLoss?: undefined;
1034
+ trailingStop?: undefined;
1035
+ oco?: boolean | undefined;
1036
+ } | {
1037
+ takeProfit?: undefined;
1038
+ stopLoss: {
1039
+ triggerPriceTicks: bigint;
1040
+ child: {
1041
+ execution: {
1042
+ value: RiskMarketIoc;
1043
+ case: "marketIoc";
1044
+ } | {
1045
+ value: RiskLimitGtc;
1046
+ case: "limitGtc";
1047
+ };
1048
+ };
1049
+ };
1050
+ trailingStop?: undefined;
1051
+ oco?: boolean | undefined;
1052
+ } | {
1053
+ takeProfit?: undefined;
1054
+ stopLoss?: undefined;
1055
+ trailingStop: {
1056
+ trailingDistance: {
1057
+ value: bigint;
1058
+ case: "trailingDistanceTicks";
1059
+ } | {
1060
+ value: number;
1061
+ case: "trailingDistanceBps";
1062
+ } | {
1063
+ case: undefined;
1064
+ value?: undefined;
1065
+ };
1066
+ maxSlippage: {
1067
+ value: number;
1068
+ case: "maxSlippageTicks";
1069
+ } | {
1070
+ value: number;
1071
+ case: "maxSlippageBps";
1072
+ } | {
1073
+ case: undefined;
1074
+ value?: undefined;
1075
+ };
1076
+ activationPriceTicks: bigint;
1077
+ };
1078
+ oco?: boolean | undefined;
1079
+ } | undefined, {
1080
+ takeProfit: {
1081
+ triggerPriceTicks: bigint;
1082
+ child: {
1083
+ execution: {
1084
+ value: RiskMarketIoc;
1085
+ case: "marketIoc";
1086
+ } | {
1087
+ value: RiskLimitGtc;
1088
+ case: "limitGtc";
1089
+ };
1090
+ };
1091
+ } | undefined;
1092
+ stopLeg: {
1093
+ readonly case: "stopLoss";
1094
+ readonly value: {
1095
+ triggerPriceTicks: bigint;
1096
+ child: {
1097
+ execution: {
1098
+ value: RiskMarketIoc;
1099
+ case: "marketIoc";
1100
+ } | {
1101
+ value: RiskLimitGtc;
1102
+ case: "limitGtc";
1103
+ };
1104
+ };
1105
+ };
1106
+ } | {
1107
+ readonly case: "trailingStop";
1108
+ readonly value: {
1109
+ trailingDistance: {
1110
+ value: bigint;
1111
+ case: "trailingDistanceTicks";
1112
+ } | {
1113
+ value: number;
1114
+ case: "trailingDistanceBps";
1115
+ } | {
1116
+ case: undefined;
1117
+ value?: undefined;
1118
+ };
1119
+ maxSlippage: {
1120
+ value: number;
1121
+ case: "maxSlippageTicks";
1122
+ } | {
1123
+ value: number;
1124
+ case: "maxSlippageBps";
1125
+ } | {
1126
+ case: undefined;
1127
+ value?: undefined;
1128
+ };
1129
+ activationPriceTicks: bigint;
1130
+ };
1131
+ } | {
1132
+ readonly case: undefined;
1133
+ readonly value: undefined;
1134
+ };
1135
+ oco: boolean;
1136
+ } | undefined>]>;
1137
+ }, undefined>], undefined>, v.CheckAction<{
1138
+ qty: string;
1139
+ maxQuoteDebit?: undefined;
1140
+ symbol: string;
1141
+ side: Side.BUY | Side.SELL;
1142
+ execution: {
1143
+ case: "marketIoc";
1144
+ value: MarketIoc;
1145
+ } | {
1146
+ case: "limitGtc";
1147
+ value: LimitGtc;
1148
+ } | {
1149
+ case: "limitIoc";
1150
+ value: LimitIoc;
1151
+ } | {
1152
+ case: "limitFok";
1153
+ value: LimitFok;
1154
+ };
1155
+ clientOrderId?: string | undefined;
1156
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
1157
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1158
+ risk?: {
1159
+ takeProfit: {
1160
+ triggerPriceTicks: bigint;
1161
+ child: {
1162
+ execution: {
1163
+ value: RiskMarketIoc;
1164
+ case: "marketIoc";
1165
+ } | {
1166
+ value: RiskLimitGtc;
1167
+ case: "limitGtc";
1168
+ };
1169
+ };
1170
+ } | undefined;
1171
+ stopLeg: {
1172
+ readonly case: "stopLoss";
1173
+ readonly value: {
1174
+ triggerPriceTicks: bigint;
1175
+ child: {
1176
+ execution: {
1177
+ value: RiskMarketIoc;
1178
+ case: "marketIoc";
1179
+ } | {
1180
+ value: RiskLimitGtc;
1181
+ case: "limitGtc";
1182
+ };
1183
+ };
1184
+ };
1185
+ } | {
1186
+ readonly case: "trailingStop";
1187
+ readonly value: {
1188
+ trailingDistance: {
1189
+ value: bigint;
1190
+ case: "trailingDistanceTicks";
1191
+ } | {
1192
+ value: number;
1193
+ case: "trailingDistanceBps";
1194
+ } | {
1195
+ case: undefined;
1196
+ value?: undefined;
1197
+ };
1198
+ maxSlippage: {
1199
+ value: number;
1200
+ case: "maxSlippageTicks";
1201
+ } | {
1202
+ value: number;
1203
+ case: "maxSlippageBps";
1204
+ } | {
1205
+ case: undefined;
1206
+ value?: undefined;
1207
+ };
1208
+ activationPriceTicks: bigint;
1209
+ };
1210
+ } | {
1211
+ readonly case: undefined;
1212
+ readonly value: undefined;
1213
+ };
1214
+ oco: boolean;
1215
+ } | undefined;
1216
+ } | {
1217
+ qty?: undefined;
1218
+ maxQuoteDebit: string;
1219
+ symbol: string;
1220
+ side: Side.BUY | Side.SELL;
1221
+ execution: {
1222
+ case: "marketIoc";
1223
+ value: MarketIoc;
1224
+ } | {
1225
+ case: "limitGtc";
1226
+ value: LimitGtc;
1227
+ } | {
1228
+ case: "limitIoc";
1229
+ value: LimitIoc;
1230
+ } | {
1231
+ case: "limitFok";
1232
+ value: LimitFok;
1233
+ };
1234
+ clientOrderId?: string | undefined;
1235
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
1236
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1237
+ risk?: {
1238
+ takeProfit: {
1239
+ triggerPriceTicks: bigint;
1240
+ child: {
1241
+ execution: {
1242
+ value: RiskMarketIoc;
1243
+ case: "marketIoc";
1244
+ } | {
1245
+ value: RiskLimitGtc;
1246
+ case: "limitGtc";
1247
+ };
1248
+ };
1249
+ } | undefined;
1250
+ stopLeg: {
1251
+ readonly case: "stopLoss";
1252
+ readonly value: {
1253
+ triggerPriceTicks: bigint;
1254
+ child: {
1255
+ execution: {
1256
+ value: RiskMarketIoc;
1257
+ case: "marketIoc";
1258
+ } | {
1259
+ value: RiskLimitGtc;
1260
+ case: "limitGtc";
1261
+ };
1262
+ };
1263
+ };
1264
+ } | {
1265
+ readonly case: "trailingStop";
1266
+ readonly value: {
1267
+ trailingDistance: {
1268
+ value: bigint;
1269
+ case: "trailingDistanceTicks";
1270
+ } | {
1271
+ value: number;
1272
+ case: "trailingDistanceBps";
1273
+ } | {
1274
+ case: undefined;
1275
+ value?: undefined;
1276
+ };
1277
+ maxSlippage: {
1278
+ value: number;
1279
+ case: "maxSlippageTicks";
1280
+ } | {
1281
+ value: number;
1282
+ case: "maxSlippageBps";
1283
+ } | {
1284
+ case: undefined;
1285
+ value?: undefined;
1286
+ };
1287
+ activationPriceTicks: bigint;
1288
+ };
1289
+ } | {
1290
+ readonly case: undefined;
1291
+ readonly value: undefined;
1292
+ };
1293
+ oco: boolean;
1294
+ } | undefined;
1295
+ }, "maxQuoteDebit is supported only for BUY market IOC and BUY limit IOC orders">, v.CheckAction<{
1296
+ qty: string;
1297
+ maxQuoteDebit?: undefined;
1298
+ symbol: string;
1299
+ side: Side.BUY | Side.SELL;
1300
+ execution: {
1301
+ case: "marketIoc";
1302
+ value: MarketIoc;
1303
+ } | {
1304
+ case: "limitGtc";
1305
+ value: LimitGtc;
1306
+ } | {
1307
+ case: "limitIoc";
1308
+ value: LimitIoc;
1309
+ } | {
1310
+ case: "limitFok";
1311
+ value: LimitFok;
1312
+ };
1313
+ clientOrderId?: string | undefined;
1314
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
1315
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1316
+ risk?: {
1317
+ takeProfit: {
1318
+ triggerPriceTicks: bigint;
1319
+ child: {
1320
+ execution: {
1321
+ value: RiskMarketIoc;
1322
+ case: "marketIoc";
1323
+ } | {
1324
+ value: RiskLimitGtc;
1325
+ case: "limitGtc";
1326
+ };
1327
+ };
1328
+ } | undefined;
1329
+ stopLeg: {
1330
+ readonly case: "stopLoss";
1331
+ readonly value: {
1332
+ triggerPriceTicks: bigint;
1333
+ child: {
1334
+ execution: {
1335
+ value: RiskMarketIoc;
1336
+ case: "marketIoc";
1337
+ } | {
1338
+ value: RiskLimitGtc;
1339
+ case: "limitGtc";
1340
+ };
1341
+ };
1342
+ };
1343
+ } | {
1344
+ readonly case: "trailingStop";
1345
+ readonly value: {
1346
+ trailingDistance: {
1347
+ value: bigint;
1348
+ case: "trailingDistanceTicks";
1349
+ } | {
1350
+ value: number;
1351
+ case: "trailingDistanceBps";
1352
+ } | {
1353
+ case: undefined;
1354
+ value?: undefined;
1355
+ };
1356
+ maxSlippage: {
1357
+ value: number;
1358
+ case: "maxSlippageTicks";
1359
+ } | {
1360
+ value: number;
1361
+ case: "maxSlippageBps";
1362
+ } | {
1363
+ case: undefined;
1364
+ value?: undefined;
1365
+ };
1366
+ activationPriceTicks: bigint;
1367
+ };
1368
+ } | {
1369
+ readonly case: undefined;
1370
+ readonly value: undefined;
1371
+ };
1372
+ oco: boolean;
1373
+ } | undefined;
1374
+ } | {
1375
+ qty?: undefined;
1376
+ maxQuoteDebit: string;
1377
+ symbol: string;
1378
+ side: Side.BUY | Side.SELL;
1379
+ execution: {
1380
+ case: "marketIoc";
1381
+ value: MarketIoc;
1382
+ } | {
1383
+ case: "limitGtc";
1384
+ value: LimitGtc;
1385
+ } | {
1386
+ case: "limitIoc";
1387
+ value: LimitIoc;
1388
+ } | {
1389
+ case: "limitFok";
1390
+ value: LimitFok;
1391
+ };
1392
+ clientOrderId?: string | undefined;
1393
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
1394
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1395
+ risk?: {
1396
+ takeProfit: {
1397
+ triggerPriceTicks: bigint;
1398
+ child: {
1399
+ execution: {
1400
+ value: RiskMarketIoc;
1401
+ case: "marketIoc";
1402
+ } | {
1403
+ value: RiskLimitGtc;
1404
+ case: "limitGtc";
1405
+ };
1406
+ };
1407
+ } | undefined;
1408
+ stopLeg: {
1409
+ readonly case: "stopLoss";
1410
+ readonly value: {
1411
+ triggerPriceTicks: bigint;
1412
+ child: {
1413
+ execution: {
1414
+ value: RiskMarketIoc;
1415
+ case: "marketIoc";
1416
+ } | {
1417
+ value: RiskLimitGtc;
1418
+ case: "limitGtc";
1419
+ };
1420
+ };
1421
+ };
1422
+ } | {
1423
+ readonly case: "trailingStop";
1424
+ readonly value: {
1425
+ trailingDistance: {
1426
+ value: bigint;
1427
+ case: "trailingDistanceTicks";
1428
+ } | {
1429
+ value: number;
1430
+ case: "trailingDistanceBps";
1431
+ } | {
1432
+ case: undefined;
1433
+ value?: undefined;
1434
+ };
1435
+ maxSlippage: {
1436
+ value: number;
1437
+ case: "maxSlippageTicks";
1438
+ } | {
1439
+ value: number;
1440
+ case: "maxSlippageBps";
1441
+ } | {
1442
+ case: undefined;
1443
+ value?: undefined;
1444
+ };
1445
+ activationPriceTicks: bigint;
1446
+ };
1447
+ } | {
1448
+ readonly case: undefined;
1449
+ readonly value: undefined;
1450
+ };
1451
+ oco: boolean;
1452
+ } | undefined;
1453
+ }, "SELL orders must use the quote fee asset">]>, v.TransformAction<{
1454
+ qty: string;
1455
+ maxQuoteDebit?: undefined;
1456
+ symbol: string;
1457
+ side: Side.BUY | Side.SELL;
1458
+ execution: {
1459
+ case: "marketIoc";
1460
+ value: MarketIoc;
1461
+ } | {
1462
+ case: "limitGtc";
1463
+ value: LimitGtc;
1464
+ } | {
1465
+ case: "limitIoc";
1466
+ value: LimitIoc;
1467
+ } | {
1468
+ case: "limitFok";
1469
+ value: LimitFok;
1470
+ };
1471
+ clientOrderId?: string | undefined;
1472
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
1473
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1474
+ risk?: {
1475
+ takeProfit: {
1476
+ triggerPriceTicks: bigint;
1477
+ child: {
1478
+ execution: {
1479
+ value: RiskMarketIoc;
1480
+ case: "marketIoc";
1481
+ } | {
1482
+ value: RiskLimitGtc;
1483
+ case: "limitGtc";
1484
+ };
1485
+ };
1486
+ } | undefined;
1487
+ stopLeg: {
1488
+ readonly case: "stopLoss";
1489
+ readonly value: {
1490
+ triggerPriceTicks: bigint;
1491
+ child: {
1492
+ execution: {
1493
+ value: RiskMarketIoc;
1494
+ case: "marketIoc";
1495
+ } | {
1496
+ value: RiskLimitGtc;
1497
+ case: "limitGtc";
1498
+ };
1499
+ };
1500
+ };
1501
+ } | {
1502
+ readonly case: "trailingStop";
1503
+ readonly value: {
1504
+ trailingDistance: {
1505
+ value: bigint;
1506
+ case: "trailingDistanceTicks";
1507
+ } | {
1508
+ value: number;
1509
+ case: "trailingDistanceBps";
1510
+ } | {
1511
+ case: undefined;
1512
+ value?: undefined;
1513
+ };
1514
+ maxSlippage: {
1515
+ value: number;
1516
+ case: "maxSlippageTicks";
1517
+ } | {
1518
+ value: number;
1519
+ case: "maxSlippageBps";
1520
+ } | {
1521
+ case: undefined;
1522
+ value?: undefined;
1523
+ };
1524
+ activationPriceTicks: bigint;
1525
+ };
1526
+ } | {
1527
+ readonly case: undefined;
1528
+ readonly value: undefined;
1529
+ };
1530
+ oco: boolean;
1531
+ } | undefined;
1532
+ } | {
1533
+ qty?: undefined;
1534
+ maxQuoteDebit: string;
1535
+ symbol: string;
1536
+ side: Side.BUY | Side.SELL;
1537
+ execution: {
1538
+ case: "marketIoc";
1539
+ value: MarketIoc;
1540
+ } | {
1541
+ case: "limitGtc";
1542
+ value: LimitGtc;
1543
+ } | {
1544
+ case: "limitIoc";
1545
+ value: LimitIoc;
1546
+ } | {
1547
+ case: "limitFok";
1548
+ value: LimitFok;
1549
+ };
1550
+ clientOrderId?: string | undefined;
1551
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
1552
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1553
+ risk?: {
1554
+ takeProfit: {
1555
+ triggerPriceTicks: bigint;
1556
+ child: {
1557
+ execution: {
1558
+ value: RiskMarketIoc;
1559
+ case: "marketIoc";
1560
+ } | {
1561
+ value: RiskLimitGtc;
1562
+ case: "limitGtc";
1563
+ };
1564
+ };
1565
+ } | undefined;
1566
+ stopLeg: {
1567
+ readonly case: "stopLoss";
1568
+ readonly value: {
1569
+ triggerPriceTicks: bigint;
1570
+ child: {
1571
+ execution: {
1572
+ value: RiskMarketIoc;
1573
+ case: "marketIoc";
1574
+ } | {
1575
+ value: RiskLimitGtc;
1576
+ case: "limitGtc";
1577
+ };
1578
+ };
1579
+ };
1580
+ } | {
1581
+ readonly case: "trailingStop";
1582
+ readonly value: {
1583
+ trailingDistance: {
1584
+ value: bigint;
1585
+ case: "trailingDistanceTicks";
1586
+ } | {
1587
+ value: number;
1588
+ case: "trailingDistanceBps";
1589
+ } | {
1590
+ case: undefined;
1591
+ value?: undefined;
1592
+ };
1593
+ maxSlippage: {
1594
+ value: number;
1595
+ case: "maxSlippageTicks";
1596
+ } | {
1597
+ value: number;
1598
+ case: "maxSlippageBps";
1599
+ } | {
1600
+ case: undefined;
1601
+ value?: undefined;
1602
+ };
1603
+ activationPriceTicks: bigint;
1604
+ };
1605
+ } | {
1606
+ readonly case: undefined;
1607
+ readonly value: undefined;
1608
+ };
1609
+ oco: boolean;
1610
+ } | undefined;
1611
+ }, {
1612
+ sizing: {
1613
+ readonly case: "baseQtyScaled";
1614
+ readonly value: bigint;
1615
+ } | {
1616
+ readonly case: "maxQuoteDebitScaled";
1617
+ readonly value: bigint;
1618
+ };
1619
+ feeAsset: FeeAsset.QUOTE | FeeAsset.BASE;
1620
+ attachedRisk: {
1621
+ takeProfit: {
1622
+ triggerPriceTicks: bigint;
1623
+ child: {
1624
+ execution: {
1625
+ value: RiskMarketIoc;
1626
+ case: "marketIoc";
1627
+ } | {
1628
+ value: RiskLimitGtc;
1629
+ case: "limitGtc";
1630
+ };
1631
+ };
1632
+ } | undefined;
1633
+ stopLeg: {
1634
+ readonly case: "stopLoss";
1635
+ readonly value: {
1636
+ triggerPriceTicks: bigint;
1637
+ child: {
1638
+ execution: {
1639
+ value: RiskMarketIoc;
1640
+ case: "marketIoc";
1641
+ } | {
1642
+ value: RiskLimitGtc;
1643
+ case: "limitGtc";
1644
+ };
1645
+ };
1646
+ };
1647
+ } | {
1648
+ readonly case: "trailingStop";
1649
+ readonly value: {
1650
+ trailingDistance: {
1651
+ value: bigint;
1652
+ case: "trailingDistanceTicks";
1653
+ } | {
1654
+ value: number;
1655
+ case: "trailingDistanceBps";
1656
+ } | {
1657
+ case: undefined;
1658
+ value?: undefined;
1659
+ };
1660
+ maxSlippage: {
1661
+ value: number;
1662
+ case: "maxSlippageTicks";
1663
+ } | {
1664
+ value: number;
1665
+ case: "maxSlippageBps";
1666
+ } | {
1667
+ case: undefined;
1668
+ value?: undefined;
1669
+ };
1670
+ activationPriceTicks: bigint;
1671
+ };
1672
+ } | {
1673
+ readonly case: undefined;
1674
+ readonly value: undefined;
1675
+ };
1676
+ oco: boolean;
1677
+ } | undefined;
1678
+ symbol: string;
1679
+ side: Side.BUY | Side.SELL;
1680
+ execution: {
1681
+ case: "marketIoc";
1682
+ value: MarketIoc;
1683
+ } | {
1684
+ case: "limitGtc";
1685
+ value: LimitGtc;
1686
+ } | {
1687
+ case: "limitIoc";
1688
+ value: LimitIoc;
1689
+ } | {
1690
+ case: "limitFok";
1691
+ value: LimitFok;
1692
+ };
1693
+ clientOrderId?: string | undefined;
1694
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1695
+ } | {
1696
+ sizing: {
1697
+ readonly case: "baseQtyScaled";
1698
+ readonly value: bigint;
1699
+ } | {
1700
+ readonly case: "maxQuoteDebitScaled";
1701
+ readonly value: bigint;
1702
+ };
1703
+ feeAsset: FeeAsset.QUOTE | FeeAsset.BASE;
1704
+ attachedRisk: {
1705
+ takeProfit: {
1706
+ triggerPriceTicks: bigint;
1707
+ child: {
1708
+ execution: {
1709
+ value: RiskMarketIoc;
1710
+ case: "marketIoc";
1711
+ } | {
1712
+ value: RiskLimitGtc;
1713
+ case: "limitGtc";
1714
+ };
1715
+ };
1716
+ } | undefined;
1717
+ stopLeg: {
1718
+ readonly case: "stopLoss";
1719
+ readonly value: {
1720
+ triggerPriceTicks: bigint;
1721
+ child: {
1722
+ execution: {
1723
+ value: RiskMarketIoc;
1724
+ case: "marketIoc";
1725
+ } | {
1726
+ value: RiskLimitGtc;
1727
+ case: "limitGtc";
1728
+ };
1729
+ };
1730
+ };
1731
+ } | {
1732
+ readonly case: "trailingStop";
1733
+ readonly value: {
1734
+ trailingDistance: {
1735
+ value: bigint;
1736
+ case: "trailingDistanceTicks";
1737
+ } | {
1738
+ value: number;
1739
+ case: "trailingDistanceBps";
1740
+ } | {
1741
+ case: undefined;
1742
+ value?: undefined;
1743
+ };
1744
+ maxSlippage: {
1745
+ value: number;
1746
+ case: "maxSlippageTicks";
1747
+ } | {
1748
+ value: number;
1749
+ case: "maxSlippageBps";
1750
+ } | {
1751
+ case: undefined;
1752
+ value?: undefined;
1753
+ };
1754
+ activationPriceTicks: bigint;
1755
+ };
1756
+ } | {
1757
+ readonly case: undefined;
1758
+ readonly value: undefined;
1759
+ };
1760
+ oco: boolean;
1761
+ } | undefined;
1762
+ symbol: string;
1763
+ side: Side.BUY | Side.SELL;
1764
+ execution: {
1765
+ case: "marketIoc";
1766
+ value: MarketIoc;
1767
+ } | {
1768
+ case: "limitGtc";
1769
+ value: LimitGtc;
1770
+ } | {
1771
+ case: "limitIoc";
1772
+ value: LimitIoc;
1773
+ } | {
1774
+ case: "limitFok";
1775
+ value: LimitFok;
1776
+ };
1777
+ clientOrderId?: string | undefined;
1778
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
1779
+ }>]>;
1780
+ type OrderIntentInput = v.InferInput<ReturnType<typeof createOrderIntentInputSchema>>;
1781
+ declare function createNewOrderInputSchema(scales: SdkScales): v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.UnionSchema<[v.StrictObjectSchema<{
1782
+ readonly qty: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1783
+ readonly maxQuoteDebit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
1784
+ readonly symbol: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1785
+ readonly side: v.SchemaWithPipe<readonly [v.PicklistSchema<["buy", "sell"], undefined>, v.TransformAction<"buy" | "sell", Side.BUY | Side.SELL>]>;
1786
+ readonly execution: v.VariantSchema<"type", [v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1787
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
1788
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
1789
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
1790
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1791
+ }, undefined>, v.StrictObjectSchema<{
1792
+ readonly kind: v.LiteralSchema<"bps", undefined>;
1793
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
1794
+ }, undefined>, v.StrictObjectSchema<{
1795
+ readonly kind: v.LiteralSchema<"none", undefined>;
1796
+ }, undefined>], undefined>, undefined>;
1797
+ readonly clientRefPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
1798
+ }, undefined>, v.TransformAction<{
1799
+ type: "market_ioc";
1800
+ maxSlippage?: {
1801
+ kind: "bps";
1802
+ bps: string | number;
1803
+ } | {
1804
+ kind: "none";
1805
+ } | {
1806
+ kind: "slippage";
1807
+ slippage: string;
1808
+ } | undefined;
1809
+ clientRefPrice?: string | undefined;
1810
+ }, {
1811
+ case: "marketIoc";
1812
+ value: MarketIoc;
1813
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1814
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
1815
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1816
+ readonly postOnly: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
1817
+ }, undefined>, v.TransformAction<{
1818
+ type: "limit_gtc";
1819
+ price: string;
1820
+ postOnly: boolean;
1821
+ }, {
1822
+ case: "limitGtc";
1823
+ value: LimitGtc;
1824
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1825
+ readonly type: v.LiteralSchema<"limit_ioc", undefined>;
1826
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1827
+ }, undefined>, v.TransformAction<{
1828
+ type: "limit_ioc";
1829
+ price: string;
1830
+ }, {
1831
+ case: "limitIoc";
1832
+ value: LimitIoc;
1833
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1834
+ readonly type: v.LiteralSchema<"limit_fok", undefined>;
1835
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1836
+ }, undefined>, v.TransformAction<{
1837
+ type: "limit_fok";
1838
+ price: string;
1839
+ }, {
1840
+ case: "limitFok";
1841
+ value: LimitFok;
1842
+ }>]>], undefined>;
1843
+ readonly clientOrderId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 36, undefined>, v.RegexAction<string, "clientOrderId has an invalid format">]>, undefined>;
1844
+ readonly feeAsset: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["quote", "base"], undefined>, undefined>, v.TransformAction<"quote" | "base" | undefined, FeeAsset.QUOTE | FeeAsset.BASE | undefined>]>;
1845
+ readonly selfTradePreventionMode: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["expire_taker", "expire_maker", "expire_both"], undefined>, undefined>, v.TransformAction<"expire_taker" | "expire_maker" | "expire_both" | undefined, SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined>]>;
1846
+ readonly risk: v.SchemaWithPipe<readonly [v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
1847
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1848
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1849
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
1850
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
1851
+ }, undefined>, v.StrictObjectSchema<{
1852
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
1853
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1854
+ }, undefined>], undefined>;
1855
+ }, undefined>, v.TransformAction<{
1856
+ triggerPrice: string;
1857
+ execution: {
1858
+ type: "market_ioc";
1859
+ } | {
1860
+ type: "limit_gtc";
1861
+ price: string;
1862
+ };
1863
+ }, {
1864
+ triggerPriceTicks: bigint;
1865
+ child: {
1866
+ execution: {
1867
+ value: RiskMarketIoc;
1868
+ case: "marketIoc";
1869
+ } | {
1870
+ value: RiskLimitGtc;
1871
+ case: "limitGtc";
1872
+ };
1873
+ };
1874
+ }>]>;
1875
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1876
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1877
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
1878
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
1879
+ }, undefined>, v.StrictObjectSchema<{
1880
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
1881
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1882
+ }, undefined>], undefined>;
1883
+ }, undefined>, v.TransformAction<{
1884
+ triggerPrice: string;
1885
+ execution: {
1886
+ type: "market_ioc";
1887
+ } | {
1888
+ type: "limit_gtc";
1889
+ price: string;
1890
+ };
1891
+ }, {
1892
+ triggerPriceTicks: bigint;
1893
+ child: {
1894
+ execution: {
1895
+ value: RiskMarketIoc;
1896
+ case: "marketIoc";
1897
+ } | {
1898
+ value: RiskLimitGtc;
1899
+ case: "limitGtc";
1900
+ };
1901
+ };
1902
+ }>]>;
1903
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
1904
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
1905
+ }, undefined>, v.StrictObjectSchema<{
1906
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1907
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1908
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
1909
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
1910
+ }, undefined>, v.StrictObjectSchema<{
1911
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
1912
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1913
+ }, undefined>], undefined>;
1914
+ }, undefined>, v.TransformAction<{
1915
+ triggerPrice: string;
1916
+ execution: {
1917
+ type: "market_ioc";
1918
+ } | {
1919
+ type: "limit_gtc";
1920
+ price: string;
1921
+ };
1922
+ }, {
1923
+ triggerPriceTicks: bigint;
1924
+ child: {
1925
+ execution: {
1926
+ value: RiskMarketIoc;
1927
+ case: "marketIoc";
1928
+ } | {
1929
+ value: RiskLimitGtc;
1930
+ case: "limitGtc";
1931
+ };
1932
+ };
1933
+ }>]>;
1934
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
1935
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1936
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
1937
+ readonly kind: v.LiteralSchema<"distance", undefined>;
1938
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1939
+ }, undefined>, v.StrictObjectSchema<{
1940
+ readonly kind: v.LiteralSchema<"bps", undefined>;
1941
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
1942
+ }, undefined>, v.StrictObjectSchema<{
1943
+ readonly kind: v.LiteralSchema<"none", undefined>;
1944
+ }, undefined>], undefined>;
1945
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
1946
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
1947
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1948
+ }, undefined>, v.StrictObjectSchema<{
1949
+ readonly kind: v.LiteralSchema<"bps", undefined>;
1950
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
1951
+ }, undefined>, v.StrictObjectSchema<{
1952
+ readonly kind: v.LiteralSchema<"none", undefined>;
1953
+ }, undefined>], undefined>, undefined>;
1954
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
1955
+ }, undefined>, v.TransformAction<{
1956
+ trailingDistance: {
1957
+ kind: "bps";
1958
+ bps: string | number;
1959
+ } | {
1960
+ kind: "none";
1961
+ } | {
1962
+ kind: "distance";
1963
+ distance: string;
1964
+ };
1965
+ maxSlippage?: {
1966
+ kind: "bps";
1967
+ bps: string | number;
1968
+ } | {
1969
+ kind: "none";
1970
+ } | {
1971
+ kind: "slippage";
1972
+ slippage: string;
1973
+ } | undefined;
1974
+ activationPrice?: string | undefined;
1975
+ }, {
1976
+ trailingDistance: {
1977
+ value: bigint;
1978
+ case: "trailingDistanceTicks";
1979
+ } | {
1980
+ value: number;
1981
+ case: "trailingDistanceBps";
1982
+ } | {
1983
+ case: undefined;
1984
+ value?: undefined;
1985
+ };
1986
+ maxSlippage: {
1987
+ value: number;
1988
+ case: "maxSlippageTicks";
1989
+ } | {
1990
+ value: number;
1991
+ case: "maxSlippageBps";
1992
+ } | {
1993
+ case: undefined;
1994
+ value?: undefined;
1995
+ };
1996
+ activationPriceTicks: bigint;
1997
+ }>]>;
1998
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
1999
+ }, undefined>, v.StrictObjectSchema<{
2000
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2001
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2002
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
2003
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2004
+ }, undefined>, v.StrictObjectSchema<{
2005
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2006
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2007
+ }, undefined>], undefined>;
2008
+ }, undefined>, v.TransformAction<{
2009
+ triggerPrice: string;
2010
+ execution: {
2011
+ type: "market_ioc";
2012
+ } | {
2013
+ type: "limit_gtc";
2014
+ price: string;
2015
+ };
2016
+ }, {
2017
+ triggerPriceTicks: bigint;
2018
+ child: {
2019
+ execution: {
2020
+ value: RiskMarketIoc;
2021
+ case: "marketIoc";
2022
+ } | {
2023
+ value: RiskLimitGtc;
2024
+ case: "limitGtc";
2025
+ };
2026
+ };
2027
+ }>]>;
2028
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2029
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2030
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2031
+ }, undefined>, v.StrictObjectSchema<{
2032
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2033
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2034
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2035
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
2036
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2037
+ }, undefined>, v.StrictObjectSchema<{
2038
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2039
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2040
+ }, undefined>], undefined>;
2041
+ }, undefined>, v.TransformAction<{
2042
+ triggerPrice: string;
2043
+ execution: {
2044
+ type: "market_ioc";
2045
+ } | {
2046
+ type: "limit_gtc";
2047
+ price: string;
2048
+ };
2049
+ }, {
2050
+ triggerPriceTicks: bigint;
2051
+ child: {
2052
+ execution: {
2053
+ value: RiskMarketIoc;
2054
+ case: "marketIoc";
2055
+ } | {
2056
+ value: RiskLimitGtc;
2057
+ case: "limitGtc";
2058
+ };
2059
+ };
2060
+ }>]>;
2061
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2062
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2063
+ }, undefined>, v.StrictObjectSchema<{
2064
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2065
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2066
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2067
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
2068
+ readonly kind: v.LiteralSchema<"distance", undefined>;
2069
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2070
+ }, undefined>, v.StrictObjectSchema<{
2071
+ readonly kind: v.LiteralSchema<"bps", undefined>;
2072
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
2073
+ }, undefined>, v.StrictObjectSchema<{
2074
+ readonly kind: v.LiteralSchema<"none", undefined>;
2075
+ }, undefined>], undefined>;
2076
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
2077
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
2078
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2079
+ }, undefined>, v.StrictObjectSchema<{
2080
+ readonly kind: v.LiteralSchema<"bps", undefined>;
2081
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
2082
+ }, undefined>, v.StrictObjectSchema<{
2083
+ readonly kind: v.LiteralSchema<"none", undefined>;
2084
+ }, undefined>], undefined>, undefined>;
2085
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2086
+ }, undefined>, v.TransformAction<{
2087
+ trailingDistance: {
2088
+ kind: "bps";
2089
+ bps: string | number;
2090
+ } | {
2091
+ kind: "none";
2092
+ } | {
2093
+ kind: "distance";
2094
+ distance: string;
2095
+ };
2096
+ maxSlippage?: {
2097
+ kind: "bps";
2098
+ bps: string | number;
2099
+ } | {
2100
+ kind: "none";
2101
+ } | {
2102
+ kind: "slippage";
2103
+ slippage: string;
2104
+ } | undefined;
2105
+ activationPrice?: string | undefined;
2106
+ }, {
2107
+ trailingDistance: {
2108
+ value: bigint;
2109
+ case: "trailingDistanceTicks";
2110
+ } | {
2111
+ value: number;
2112
+ case: "trailingDistanceBps";
2113
+ } | {
2114
+ case: undefined;
2115
+ value?: undefined;
2116
+ };
2117
+ maxSlippage: {
2118
+ value: number;
2119
+ case: "maxSlippageTicks";
2120
+ } | {
2121
+ value: number;
2122
+ case: "maxSlippageBps";
2123
+ } | {
2124
+ case: undefined;
2125
+ value?: undefined;
2126
+ };
2127
+ activationPriceTicks: bigint;
2128
+ }>]>;
2129
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2130
+ }, undefined>], undefined>, undefined>, v.TransformAction<{
2131
+ takeProfit: {
2132
+ triggerPriceTicks: bigint;
2133
+ child: {
2134
+ execution: {
2135
+ value: RiskMarketIoc;
2136
+ case: "marketIoc";
2137
+ } | {
2138
+ value: RiskLimitGtc;
2139
+ case: "limitGtc";
2140
+ };
2141
+ };
2142
+ };
2143
+ stopLoss: {
2144
+ triggerPriceTicks: bigint;
2145
+ child: {
2146
+ execution: {
2147
+ value: RiskMarketIoc;
2148
+ case: "marketIoc";
2149
+ } | {
2150
+ value: RiskLimitGtc;
2151
+ case: "limitGtc";
2152
+ };
2153
+ };
2154
+ };
2155
+ trailingStop?: undefined;
2156
+ oco?: boolean | undefined;
2157
+ } | {
2158
+ takeProfit: {
2159
+ triggerPriceTicks: bigint;
2160
+ child: {
2161
+ execution: {
2162
+ value: RiskMarketIoc;
2163
+ case: "marketIoc";
2164
+ } | {
2165
+ value: RiskLimitGtc;
2166
+ case: "limitGtc";
2167
+ };
2168
+ };
2169
+ };
2170
+ stopLoss?: undefined;
2171
+ trailingStop: {
2172
+ trailingDistance: {
2173
+ value: bigint;
2174
+ case: "trailingDistanceTicks";
2175
+ } | {
2176
+ value: number;
2177
+ case: "trailingDistanceBps";
2178
+ } | {
2179
+ case: undefined;
2180
+ value?: undefined;
2181
+ };
2182
+ maxSlippage: {
2183
+ value: number;
2184
+ case: "maxSlippageTicks";
2185
+ } | {
2186
+ value: number;
2187
+ case: "maxSlippageBps";
2188
+ } | {
2189
+ case: undefined;
2190
+ value?: undefined;
2191
+ };
2192
+ activationPriceTicks: bigint;
2193
+ };
2194
+ oco?: boolean | undefined;
2195
+ } | {
2196
+ takeProfit: {
2197
+ triggerPriceTicks: bigint;
2198
+ child: {
2199
+ execution: {
2200
+ value: RiskMarketIoc;
2201
+ case: "marketIoc";
2202
+ } | {
2203
+ value: RiskLimitGtc;
2204
+ case: "limitGtc";
2205
+ };
2206
+ };
2207
+ };
2208
+ stopLoss?: undefined;
2209
+ trailingStop?: undefined;
2210
+ oco?: boolean | undefined;
2211
+ } | {
2212
+ takeProfit?: undefined;
2213
+ stopLoss: {
2214
+ triggerPriceTicks: bigint;
2215
+ child: {
2216
+ execution: {
2217
+ value: RiskMarketIoc;
2218
+ case: "marketIoc";
2219
+ } | {
2220
+ value: RiskLimitGtc;
2221
+ case: "limitGtc";
2222
+ };
2223
+ };
2224
+ };
2225
+ trailingStop?: undefined;
2226
+ oco?: boolean | undefined;
2227
+ } | {
2228
+ takeProfit?: undefined;
2229
+ stopLoss?: undefined;
2230
+ trailingStop: {
2231
+ trailingDistance: {
2232
+ value: bigint;
2233
+ case: "trailingDistanceTicks";
2234
+ } | {
2235
+ value: number;
2236
+ case: "trailingDistanceBps";
2237
+ } | {
2238
+ case: undefined;
2239
+ value?: undefined;
2240
+ };
2241
+ maxSlippage: {
2242
+ value: number;
2243
+ case: "maxSlippageTicks";
2244
+ } | {
2245
+ value: number;
2246
+ case: "maxSlippageBps";
2247
+ } | {
2248
+ case: undefined;
2249
+ value?: undefined;
2250
+ };
2251
+ activationPriceTicks: bigint;
2252
+ };
2253
+ oco?: boolean | undefined;
2254
+ } | undefined, {
2255
+ takeProfit: {
2256
+ triggerPriceTicks: bigint;
2257
+ child: {
2258
+ execution: {
2259
+ value: RiskMarketIoc;
2260
+ case: "marketIoc";
2261
+ } | {
2262
+ value: RiskLimitGtc;
2263
+ case: "limitGtc";
2264
+ };
2265
+ };
2266
+ } | undefined;
2267
+ stopLeg: {
2268
+ readonly case: "stopLoss";
2269
+ readonly value: {
2270
+ triggerPriceTicks: bigint;
2271
+ child: {
2272
+ execution: {
2273
+ value: RiskMarketIoc;
2274
+ case: "marketIoc";
2275
+ } | {
2276
+ value: RiskLimitGtc;
2277
+ case: "limitGtc";
2278
+ };
2279
+ };
2280
+ };
2281
+ } | {
2282
+ readonly case: "trailingStop";
2283
+ readonly value: {
2284
+ trailingDistance: {
2285
+ value: bigint;
2286
+ case: "trailingDistanceTicks";
2287
+ } | {
2288
+ value: number;
2289
+ case: "trailingDistanceBps";
2290
+ } | {
2291
+ case: undefined;
2292
+ value?: undefined;
2293
+ };
2294
+ maxSlippage: {
2295
+ value: number;
2296
+ case: "maxSlippageTicks";
2297
+ } | {
2298
+ value: number;
2299
+ case: "maxSlippageBps";
2300
+ } | {
2301
+ case: undefined;
2302
+ value?: undefined;
2303
+ };
2304
+ activationPriceTicks: bigint;
2305
+ };
2306
+ } | {
2307
+ readonly case: undefined;
2308
+ readonly value: undefined;
2309
+ };
2310
+ oco: boolean;
2311
+ } | undefined>]>;
2312
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
2313
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2314
+ }, undefined>], undefined>, undefined>;
2315
+ }, undefined>, v.StrictObjectSchema<{
2316
+ readonly qty: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2317
+ readonly maxQuoteDebit: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2318
+ readonly symbol: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2319
+ readonly side: v.SchemaWithPipe<readonly [v.PicklistSchema<["buy", "sell"], undefined>, v.TransformAction<"buy" | "sell", Side.BUY | Side.SELL>]>;
2320
+ readonly execution: v.VariantSchema<"type", [v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2321
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2322
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
2323
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
2324
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2325
+ }, undefined>, v.StrictObjectSchema<{
2326
+ readonly kind: v.LiteralSchema<"bps", undefined>;
2327
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
2328
+ }, undefined>, v.StrictObjectSchema<{
2329
+ readonly kind: v.LiteralSchema<"none", undefined>;
2330
+ }, undefined>], undefined>, undefined>;
2331
+ readonly clientRefPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2332
+ }, undefined>, v.TransformAction<{
2333
+ type: "market_ioc";
2334
+ maxSlippage?: {
2335
+ kind: "bps";
2336
+ bps: string | number;
2337
+ } | {
2338
+ kind: "none";
2339
+ } | {
2340
+ kind: "slippage";
2341
+ slippage: string;
2342
+ } | undefined;
2343
+ clientRefPrice?: string | undefined;
2344
+ }, {
2345
+ case: "marketIoc";
2346
+ value: MarketIoc;
2347
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2348
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2349
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2350
+ readonly postOnly: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
2351
+ }, undefined>, v.TransformAction<{
2352
+ type: "limit_gtc";
2353
+ price: string;
2354
+ postOnly: boolean;
2355
+ }, {
2356
+ case: "limitGtc";
2357
+ value: LimitGtc;
2358
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2359
+ readonly type: v.LiteralSchema<"limit_ioc", undefined>;
2360
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2361
+ }, undefined>, v.TransformAction<{
2362
+ type: "limit_ioc";
2363
+ price: string;
2364
+ }, {
2365
+ case: "limitIoc";
2366
+ value: LimitIoc;
2367
+ }>]>, v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2368
+ readonly type: v.LiteralSchema<"limit_fok", undefined>;
2369
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2370
+ }, undefined>, v.TransformAction<{
2371
+ type: "limit_fok";
2372
+ price: string;
2373
+ }, {
2374
+ case: "limitFok";
2375
+ value: LimitFok;
2376
+ }>]>], undefined>;
2377
+ readonly clientOrderId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 36, undefined>, v.RegexAction<string, "clientOrderId has an invalid format">]>, undefined>;
2378
+ readonly feeAsset: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["quote", "base"], undefined>, undefined>, v.TransformAction<"quote" | "base" | undefined, FeeAsset.QUOTE | FeeAsset.BASE | undefined>]>;
2379
+ readonly selfTradePreventionMode: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<readonly ["expire_taker", "expire_maker", "expire_both"], undefined>, undefined>, v.TransformAction<"expire_taker" | "expire_maker" | "expire_both" | undefined, SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined>]>;
2380
+ readonly risk: v.SchemaWithPipe<readonly [v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
2381
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2382
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2383
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
2384
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2385
+ }, undefined>, v.StrictObjectSchema<{
2386
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2387
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2388
+ }, undefined>], undefined>;
2389
+ }, undefined>, v.TransformAction<{
2390
+ triggerPrice: string;
2391
+ execution: {
2392
+ type: "market_ioc";
2393
+ } | {
2394
+ type: "limit_gtc";
2395
+ price: string;
2396
+ };
2397
+ }, {
2398
+ triggerPriceTicks: bigint;
2399
+ child: {
2400
+ execution: {
2401
+ value: RiskMarketIoc;
2402
+ case: "marketIoc";
2403
+ } | {
2404
+ value: RiskLimitGtc;
2405
+ case: "limitGtc";
2406
+ };
2407
+ };
2408
+ }>]>;
2409
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2410
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2411
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
2412
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2413
+ }, undefined>, v.StrictObjectSchema<{
2414
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2415
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2416
+ }, undefined>], undefined>;
2417
+ }, undefined>, v.TransformAction<{
2418
+ triggerPrice: string;
2419
+ execution: {
2420
+ type: "market_ioc";
2421
+ } | {
2422
+ type: "limit_gtc";
2423
+ price: string;
2424
+ };
2425
+ }, {
2426
+ triggerPriceTicks: bigint;
2427
+ child: {
2428
+ execution: {
2429
+ value: RiskMarketIoc;
2430
+ case: "marketIoc";
2431
+ } | {
2432
+ value: RiskLimitGtc;
2433
+ case: "limitGtc";
2434
+ };
2435
+ };
2436
+ }>]>;
2437
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2438
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2439
+ }, undefined>, v.StrictObjectSchema<{
2440
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2441
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2442
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
2443
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2444
+ }, undefined>, v.StrictObjectSchema<{
2445
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2446
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2447
+ }, undefined>], undefined>;
2448
+ }, undefined>, v.TransformAction<{
2449
+ triggerPrice: string;
2450
+ execution: {
2451
+ type: "market_ioc";
2452
+ } | {
2453
+ type: "limit_gtc";
2454
+ price: string;
2455
+ };
2456
+ }, {
2457
+ triggerPriceTicks: bigint;
2458
+ child: {
2459
+ execution: {
2460
+ value: RiskMarketIoc;
2461
+ case: "marketIoc";
2462
+ } | {
2463
+ value: RiskLimitGtc;
2464
+ case: "limitGtc";
2465
+ };
2466
+ };
2467
+ }>]>;
2468
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2469
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2470
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
2471
+ readonly kind: v.LiteralSchema<"distance", undefined>;
2472
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2473
+ }, undefined>, v.StrictObjectSchema<{
2474
+ readonly kind: v.LiteralSchema<"bps", undefined>;
2475
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
2476
+ }, undefined>, v.StrictObjectSchema<{
2477
+ readonly kind: v.LiteralSchema<"none", undefined>;
2478
+ }, undefined>], undefined>;
2479
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
2480
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
2481
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2482
+ }, undefined>, v.StrictObjectSchema<{
2483
+ readonly kind: v.LiteralSchema<"bps", undefined>;
2484
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
2485
+ }, undefined>, v.StrictObjectSchema<{
2486
+ readonly kind: v.LiteralSchema<"none", undefined>;
2487
+ }, undefined>], undefined>, undefined>;
2488
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2489
+ }, undefined>, v.TransformAction<{
2490
+ trailingDistance: {
2491
+ kind: "bps";
2492
+ bps: string | number;
2493
+ } | {
2494
+ kind: "none";
2495
+ } | {
2496
+ kind: "distance";
2497
+ distance: string;
2498
+ };
2499
+ maxSlippage?: {
2500
+ kind: "bps";
2501
+ bps: string | number;
2502
+ } | {
2503
+ kind: "none";
2504
+ } | {
2505
+ kind: "slippage";
2506
+ slippage: string;
2507
+ } | undefined;
2508
+ activationPrice?: string | undefined;
2509
+ }, {
2510
+ trailingDistance: {
2511
+ value: bigint;
2512
+ case: "trailingDistanceTicks";
2513
+ } | {
2514
+ value: number;
2515
+ case: "trailingDistanceBps";
2516
+ } | {
2517
+ case: undefined;
2518
+ value?: undefined;
2519
+ };
2520
+ maxSlippage: {
2521
+ value: number;
2522
+ case: "maxSlippageTicks";
2523
+ } | {
2524
+ value: number;
2525
+ case: "maxSlippageBps";
2526
+ } | {
2527
+ case: undefined;
2528
+ value?: undefined;
2529
+ };
2530
+ activationPriceTicks: bigint;
2531
+ }>]>;
2532
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2533
+ }, undefined>, v.StrictObjectSchema<{
2534
+ readonly takeProfit: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2535
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2536
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
2537
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2538
+ }, undefined>, v.StrictObjectSchema<{
2539
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2540
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2541
+ }, undefined>], undefined>;
2542
+ }, undefined>, v.TransformAction<{
2543
+ triggerPrice: string;
2544
+ execution: {
2545
+ type: "market_ioc";
2546
+ } | {
2547
+ type: "limit_gtc";
2548
+ price: string;
2549
+ };
2550
+ }, {
2551
+ triggerPriceTicks: bigint;
2552
+ child: {
2553
+ execution: {
2554
+ value: RiskMarketIoc;
2555
+ case: "marketIoc";
2556
+ } | {
2557
+ value: RiskLimitGtc;
2558
+ case: "limitGtc";
2559
+ };
2560
+ };
2561
+ }>]>;
2562
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2563
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2564
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2565
+ }, undefined>, v.StrictObjectSchema<{
2566
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2567
+ readonly stopLoss: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2568
+ readonly triggerPrice: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2569
+ readonly execution: v.VariantSchema<"type", [v.StrictObjectSchema<{
2570
+ readonly type: v.LiteralSchema<"market_ioc", undefined>;
2571
+ }, undefined>, v.StrictObjectSchema<{
2572
+ readonly type: v.LiteralSchema<"limit_gtc", undefined>;
2573
+ readonly price: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2574
+ }, undefined>], undefined>;
2575
+ }, undefined>, v.TransformAction<{
2576
+ triggerPrice: string;
2577
+ execution: {
2578
+ type: "market_ioc";
2579
+ } | {
2580
+ type: "limit_gtc";
2581
+ price: string;
2582
+ };
2583
+ }, {
2584
+ triggerPriceTicks: bigint;
2585
+ child: {
2586
+ execution: {
2587
+ value: RiskMarketIoc;
2588
+ case: "marketIoc";
2589
+ } | {
2590
+ value: RiskLimitGtc;
2591
+ case: "limitGtc";
2592
+ };
2593
+ };
2594
+ }>]>;
2595
+ readonly trailingStop: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2596
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2597
+ }, undefined>, v.StrictObjectSchema<{
2598
+ readonly takeProfit: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2599
+ readonly stopLoss: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
2600
+ readonly trailingStop: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
2601
+ readonly trailingDistance: v.UnionSchema<[v.StrictObjectSchema<{
2602
+ readonly kind: v.LiteralSchema<"distance", undefined>;
2603
+ readonly distance: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2604
+ }, undefined>, v.StrictObjectSchema<{
2605
+ readonly kind: v.LiteralSchema<"bps", undefined>;
2606
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
2607
+ }, undefined>, v.StrictObjectSchema<{
2608
+ readonly kind: v.LiteralSchema<"none", undefined>;
2609
+ }, undefined>], undefined>;
2610
+ readonly maxSlippage: v.OptionalSchema<v.UnionSchema<[v.StrictObjectSchema<{
2611
+ readonly kind: v.LiteralSchema<"slippage", undefined>;
2612
+ readonly slippage: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2613
+ }, undefined>, v.StrictObjectSchema<{
2614
+ readonly kind: v.LiteralSchema<"bps", undefined>;
2615
+ readonly bps: v.UnionSchema<[v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.GtValueAction<number, 0, undefined>]>], undefined>;
2616
+ }, undefined>, v.StrictObjectSchema<{
2617
+ readonly kind: v.LiteralSchema<"none", undefined>;
2618
+ }, undefined>], undefined>, undefined>;
2619
+ readonly activationPrice: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2620
+ }, undefined>, v.TransformAction<{
2621
+ trailingDistance: {
2622
+ kind: "bps";
2623
+ bps: string | number;
2624
+ } | {
2625
+ kind: "none";
2626
+ } | {
2627
+ kind: "distance";
2628
+ distance: string;
2629
+ };
2630
+ maxSlippage?: {
2631
+ kind: "bps";
2632
+ bps: string | number;
2633
+ } | {
2634
+ kind: "none";
2635
+ } | {
2636
+ kind: "slippage";
2637
+ slippage: string;
2638
+ } | undefined;
2639
+ activationPrice?: string | undefined;
2640
+ }, {
2641
+ trailingDistance: {
2642
+ value: bigint;
2643
+ case: "trailingDistanceTicks";
2644
+ } | {
2645
+ value: number;
2646
+ case: "trailingDistanceBps";
2647
+ } | {
2648
+ case: undefined;
2649
+ value?: undefined;
2650
+ };
2651
+ maxSlippage: {
2652
+ value: number;
2653
+ case: "maxSlippageTicks";
2654
+ } | {
2655
+ value: number;
2656
+ case: "maxSlippageBps";
2657
+ } | {
2658
+ case: undefined;
2659
+ value?: undefined;
2660
+ };
2661
+ activationPriceTicks: bigint;
2662
+ }>]>;
2663
+ readonly oco: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2664
+ }, undefined>], undefined>, undefined>, v.TransformAction<{
2665
+ takeProfit: {
2666
+ triggerPriceTicks: bigint;
2667
+ child: {
2668
+ execution: {
2669
+ value: RiskMarketIoc;
2670
+ case: "marketIoc";
2671
+ } | {
2672
+ value: RiskLimitGtc;
2673
+ case: "limitGtc";
2674
+ };
2675
+ };
2676
+ };
2677
+ stopLoss: {
2678
+ triggerPriceTicks: bigint;
2679
+ child: {
2680
+ execution: {
2681
+ value: RiskMarketIoc;
2682
+ case: "marketIoc";
2683
+ } | {
2684
+ value: RiskLimitGtc;
2685
+ case: "limitGtc";
2686
+ };
2687
+ };
2688
+ };
2689
+ trailingStop?: undefined;
2690
+ oco?: boolean | undefined;
2691
+ } | {
2692
+ takeProfit: {
2693
+ triggerPriceTicks: bigint;
2694
+ child: {
2695
+ execution: {
2696
+ value: RiskMarketIoc;
2697
+ case: "marketIoc";
2698
+ } | {
2699
+ value: RiskLimitGtc;
2700
+ case: "limitGtc";
2701
+ };
2702
+ };
2703
+ };
2704
+ stopLoss?: undefined;
2705
+ trailingStop: {
2706
+ trailingDistance: {
2707
+ value: bigint;
2708
+ case: "trailingDistanceTicks";
2709
+ } | {
2710
+ value: number;
2711
+ case: "trailingDistanceBps";
2712
+ } | {
2713
+ case: undefined;
2714
+ value?: undefined;
2715
+ };
2716
+ maxSlippage: {
2717
+ value: number;
2718
+ case: "maxSlippageTicks";
2719
+ } | {
2720
+ value: number;
2721
+ case: "maxSlippageBps";
2722
+ } | {
2723
+ case: undefined;
2724
+ value?: undefined;
2725
+ };
2726
+ activationPriceTicks: bigint;
2727
+ };
2728
+ oco?: boolean | undefined;
2729
+ } | {
2730
+ takeProfit: {
2731
+ triggerPriceTicks: bigint;
2732
+ child: {
2733
+ execution: {
2734
+ value: RiskMarketIoc;
2735
+ case: "marketIoc";
2736
+ } | {
2737
+ value: RiskLimitGtc;
2738
+ case: "limitGtc";
2739
+ };
2740
+ };
2741
+ };
2742
+ stopLoss?: undefined;
2743
+ trailingStop?: undefined;
2744
+ oco?: boolean | undefined;
2745
+ } | {
2746
+ takeProfit?: undefined;
2747
+ stopLoss: {
2748
+ triggerPriceTicks: bigint;
2749
+ child: {
2750
+ execution: {
2751
+ value: RiskMarketIoc;
2752
+ case: "marketIoc";
2753
+ } | {
2754
+ value: RiskLimitGtc;
2755
+ case: "limitGtc";
2756
+ };
2757
+ };
2758
+ };
2759
+ trailingStop?: undefined;
2760
+ oco?: boolean | undefined;
2761
+ } | {
2762
+ takeProfit?: undefined;
2763
+ stopLoss?: undefined;
2764
+ trailingStop: {
2765
+ trailingDistance: {
2766
+ value: bigint;
2767
+ case: "trailingDistanceTicks";
2768
+ } | {
2769
+ value: number;
2770
+ case: "trailingDistanceBps";
2771
+ } | {
2772
+ case: undefined;
2773
+ value?: undefined;
2774
+ };
2775
+ maxSlippage: {
2776
+ value: number;
2777
+ case: "maxSlippageTicks";
2778
+ } | {
2779
+ value: number;
2780
+ case: "maxSlippageBps";
2781
+ } | {
2782
+ case: undefined;
2783
+ value?: undefined;
2784
+ };
2785
+ activationPriceTicks: bigint;
2786
+ };
2787
+ oco?: boolean | undefined;
2788
+ } | undefined, {
2789
+ takeProfit: {
2790
+ triggerPriceTicks: bigint;
2791
+ child: {
2792
+ execution: {
2793
+ value: RiskMarketIoc;
2794
+ case: "marketIoc";
2795
+ } | {
2796
+ value: RiskLimitGtc;
2797
+ case: "limitGtc";
2798
+ };
2799
+ };
2800
+ } | undefined;
2801
+ stopLeg: {
2802
+ readonly case: "stopLoss";
2803
+ readonly value: {
2804
+ triggerPriceTicks: bigint;
2805
+ child: {
2806
+ execution: {
2807
+ value: RiskMarketIoc;
2808
+ case: "marketIoc";
2809
+ } | {
2810
+ value: RiskLimitGtc;
2811
+ case: "limitGtc";
2812
+ };
2813
+ };
2814
+ };
2815
+ } | {
2816
+ readonly case: "trailingStop";
2817
+ readonly value: {
2818
+ trailingDistance: {
2819
+ value: bigint;
2820
+ case: "trailingDistanceTicks";
2821
+ } | {
2822
+ value: number;
2823
+ case: "trailingDistanceBps";
2824
+ } | {
2825
+ case: undefined;
2826
+ value?: undefined;
2827
+ };
2828
+ maxSlippage: {
2829
+ value: number;
2830
+ case: "maxSlippageTicks";
2831
+ } | {
2832
+ value: number;
2833
+ case: "maxSlippageBps";
2834
+ } | {
2835
+ case: undefined;
2836
+ value?: undefined;
2837
+ };
2838
+ activationPriceTicks: bigint;
2839
+ };
2840
+ } | {
2841
+ readonly case: undefined;
2842
+ readonly value: undefined;
2843
+ };
2844
+ oco: boolean;
2845
+ } | undefined>]>;
2846
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
2847
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
2848
+ }, undefined>], undefined>, undefined>;
2849
+ }, undefined>], undefined>, v.CheckAction<{
2850
+ qty: string;
2851
+ maxQuoteDebit?: undefined;
2852
+ symbol: string;
2853
+ side: Side.BUY | Side.SELL;
2854
+ execution: {
2855
+ case: "marketIoc";
2856
+ value: MarketIoc;
2857
+ } | {
2858
+ case: "limitGtc";
2859
+ value: LimitGtc;
2860
+ } | {
2861
+ case: "limitIoc";
2862
+ value: LimitIoc;
2863
+ } | {
2864
+ case: "limitFok";
2865
+ value: LimitFok;
2866
+ };
2867
+ clientOrderId?: string | undefined;
2868
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
2869
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
2870
+ risk?: {
2871
+ takeProfit: {
2872
+ triggerPriceTicks: bigint;
2873
+ child: {
2874
+ execution: {
2875
+ value: RiskMarketIoc;
2876
+ case: "marketIoc";
2877
+ } | {
2878
+ value: RiskLimitGtc;
2879
+ case: "limitGtc";
2880
+ };
2881
+ };
2882
+ } | undefined;
2883
+ stopLeg: {
2884
+ readonly case: "stopLoss";
2885
+ readonly value: {
2886
+ triggerPriceTicks: bigint;
2887
+ child: {
2888
+ execution: {
2889
+ value: RiskMarketIoc;
2890
+ case: "marketIoc";
2891
+ } | {
2892
+ value: RiskLimitGtc;
2893
+ case: "limitGtc";
2894
+ };
2895
+ };
2896
+ };
2897
+ } | {
2898
+ readonly case: "trailingStop";
2899
+ readonly value: {
2900
+ trailingDistance: {
2901
+ value: bigint;
2902
+ case: "trailingDistanceTicks";
2903
+ } | {
2904
+ value: number;
2905
+ case: "trailingDistanceBps";
2906
+ } | {
2907
+ case: undefined;
2908
+ value?: undefined;
2909
+ };
2910
+ maxSlippage: {
2911
+ value: number;
2912
+ case: "maxSlippageTicks";
2913
+ } | {
2914
+ value: number;
2915
+ case: "maxSlippageBps";
2916
+ } | {
2917
+ case: undefined;
2918
+ value?: undefined;
2919
+ };
2920
+ activationPriceTicks: bigint;
2921
+ };
2922
+ } | {
2923
+ readonly case: undefined;
2924
+ readonly value: undefined;
2925
+ };
2926
+ oco: boolean;
2927
+ } | undefined;
2928
+ account?: "active" | "main" | {
2929
+ subaccountId: string;
2930
+ } | undefined;
2931
+ } | {
2932
+ qty?: undefined;
2933
+ maxQuoteDebit: string;
2934
+ symbol: string;
2935
+ side: Side.BUY | Side.SELL;
2936
+ execution: {
2937
+ case: "marketIoc";
2938
+ value: MarketIoc;
2939
+ } | {
2940
+ case: "limitGtc";
2941
+ value: LimitGtc;
2942
+ } | {
2943
+ case: "limitIoc";
2944
+ value: LimitIoc;
2945
+ } | {
2946
+ case: "limitFok";
2947
+ value: LimitFok;
2948
+ };
2949
+ clientOrderId?: string | undefined;
2950
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
2951
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
2952
+ risk?: {
2953
+ takeProfit: {
2954
+ triggerPriceTicks: bigint;
2955
+ child: {
2956
+ execution: {
2957
+ value: RiskMarketIoc;
2958
+ case: "marketIoc";
2959
+ } | {
2960
+ value: RiskLimitGtc;
2961
+ case: "limitGtc";
2962
+ };
2963
+ };
2964
+ } | undefined;
2965
+ stopLeg: {
2966
+ readonly case: "stopLoss";
2967
+ readonly value: {
2968
+ triggerPriceTicks: bigint;
2969
+ child: {
2970
+ execution: {
2971
+ value: RiskMarketIoc;
2972
+ case: "marketIoc";
2973
+ } | {
2974
+ value: RiskLimitGtc;
2975
+ case: "limitGtc";
2976
+ };
2977
+ };
2978
+ };
2979
+ } | {
2980
+ readonly case: "trailingStop";
2981
+ readonly value: {
2982
+ trailingDistance: {
2983
+ value: bigint;
2984
+ case: "trailingDistanceTicks";
2985
+ } | {
2986
+ value: number;
2987
+ case: "trailingDistanceBps";
2988
+ } | {
2989
+ case: undefined;
2990
+ value?: undefined;
2991
+ };
2992
+ maxSlippage: {
2993
+ value: number;
2994
+ case: "maxSlippageTicks";
2995
+ } | {
2996
+ value: number;
2997
+ case: "maxSlippageBps";
2998
+ } | {
2999
+ case: undefined;
3000
+ value?: undefined;
3001
+ };
3002
+ activationPriceTicks: bigint;
3003
+ };
3004
+ } | {
3005
+ readonly case: undefined;
3006
+ readonly value: undefined;
3007
+ };
3008
+ oco: boolean;
3009
+ } | undefined;
3010
+ account?: "active" | "main" | {
3011
+ subaccountId: string;
3012
+ } | undefined;
3013
+ }, "maxQuoteDebit is supported only for BUY market IOC and BUY limit IOC orders">, v.CheckAction<{
3014
+ qty: string;
3015
+ maxQuoteDebit?: undefined;
3016
+ symbol: string;
3017
+ side: Side.BUY | Side.SELL;
3018
+ execution: {
3019
+ case: "marketIoc";
3020
+ value: MarketIoc;
3021
+ } | {
3022
+ case: "limitGtc";
3023
+ value: LimitGtc;
3024
+ } | {
3025
+ case: "limitIoc";
3026
+ value: LimitIoc;
3027
+ } | {
3028
+ case: "limitFok";
3029
+ value: LimitFok;
3030
+ };
3031
+ clientOrderId?: string | undefined;
3032
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
3033
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
3034
+ risk?: {
3035
+ takeProfit: {
3036
+ triggerPriceTicks: bigint;
3037
+ child: {
3038
+ execution: {
3039
+ value: RiskMarketIoc;
3040
+ case: "marketIoc";
3041
+ } | {
3042
+ value: RiskLimitGtc;
3043
+ case: "limitGtc";
3044
+ };
3045
+ };
3046
+ } | undefined;
3047
+ stopLeg: {
3048
+ readonly case: "stopLoss";
3049
+ readonly value: {
3050
+ triggerPriceTicks: bigint;
3051
+ child: {
3052
+ execution: {
3053
+ value: RiskMarketIoc;
3054
+ case: "marketIoc";
3055
+ } | {
3056
+ value: RiskLimitGtc;
3057
+ case: "limitGtc";
3058
+ };
3059
+ };
3060
+ };
3061
+ } | {
3062
+ readonly case: "trailingStop";
3063
+ readonly value: {
3064
+ trailingDistance: {
3065
+ value: bigint;
3066
+ case: "trailingDistanceTicks";
3067
+ } | {
3068
+ value: number;
3069
+ case: "trailingDistanceBps";
3070
+ } | {
3071
+ case: undefined;
3072
+ value?: undefined;
3073
+ };
3074
+ maxSlippage: {
3075
+ value: number;
3076
+ case: "maxSlippageTicks";
3077
+ } | {
3078
+ value: number;
3079
+ case: "maxSlippageBps";
3080
+ } | {
3081
+ case: undefined;
3082
+ value?: undefined;
3083
+ };
3084
+ activationPriceTicks: bigint;
3085
+ };
3086
+ } | {
3087
+ readonly case: undefined;
3088
+ readonly value: undefined;
3089
+ };
3090
+ oco: boolean;
3091
+ } | undefined;
3092
+ account?: "active" | "main" | {
3093
+ subaccountId: string;
3094
+ } | undefined;
3095
+ } | {
3096
+ qty?: undefined;
3097
+ maxQuoteDebit: string;
3098
+ symbol: string;
3099
+ side: Side.BUY | Side.SELL;
3100
+ execution: {
3101
+ case: "marketIoc";
3102
+ value: MarketIoc;
3103
+ } | {
3104
+ case: "limitGtc";
3105
+ value: LimitGtc;
3106
+ } | {
3107
+ case: "limitIoc";
3108
+ value: LimitIoc;
3109
+ } | {
3110
+ case: "limitFok";
3111
+ value: LimitFok;
3112
+ };
3113
+ clientOrderId?: string | undefined;
3114
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
3115
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
3116
+ risk?: {
3117
+ takeProfit: {
3118
+ triggerPriceTicks: bigint;
3119
+ child: {
3120
+ execution: {
3121
+ value: RiskMarketIoc;
3122
+ case: "marketIoc";
3123
+ } | {
3124
+ value: RiskLimitGtc;
3125
+ case: "limitGtc";
3126
+ };
3127
+ };
3128
+ } | undefined;
3129
+ stopLeg: {
3130
+ readonly case: "stopLoss";
3131
+ readonly value: {
3132
+ triggerPriceTicks: bigint;
3133
+ child: {
3134
+ execution: {
3135
+ value: RiskMarketIoc;
3136
+ case: "marketIoc";
3137
+ } | {
3138
+ value: RiskLimitGtc;
3139
+ case: "limitGtc";
3140
+ };
3141
+ };
3142
+ };
3143
+ } | {
3144
+ readonly case: "trailingStop";
3145
+ readonly value: {
3146
+ trailingDistance: {
3147
+ value: bigint;
3148
+ case: "trailingDistanceTicks";
3149
+ } | {
3150
+ value: number;
3151
+ case: "trailingDistanceBps";
3152
+ } | {
3153
+ case: undefined;
3154
+ value?: undefined;
3155
+ };
3156
+ maxSlippage: {
3157
+ value: number;
3158
+ case: "maxSlippageTicks";
3159
+ } | {
3160
+ value: number;
3161
+ case: "maxSlippageBps";
3162
+ } | {
3163
+ case: undefined;
3164
+ value?: undefined;
3165
+ };
3166
+ activationPriceTicks: bigint;
3167
+ };
3168
+ } | {
3169
+ readonly case: undefined;
3170
+ readonly value: undefined;
3171
+ };
3172
+ oco: boolean;
3173
+ } | undefined;
3174
+ account?: "active" | "main" | {
3175
+ subaccountId: string;
3176
+ } | undefined;
3177
+ }, "SELL orders must use the quote fee asset">]>, v.TransformAction<{
3178
+ qty: string;
3179
+ maxQuoteDebit?: undefined;
3180
+ symbol: string;
3181
+ side: Side.BUY | Side.SELL;
3182
+ execution: {
3183
+ case: "marketIoc";
3184
+ value: MarketIoc;
3185
+ } | {
3186
+ case: "limitGtc";
3187
+ value: LimitGtc;
3188
+ } | {
3189
+ case: "limitIoc";
3190
+ value: LimitIoc;
3191
+ } | {
3192
+ case: "limitFok";
3193
+ value: LimitFok;
3194
+ };
3195
+ clientOrderId?: string | undefined;
3196
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
3197
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
3198
+ risk?: {
3199
+ takeProfit: {
3200
+ triggerPriceTicks: bigint;
3201
+ child: {
3202
+ execution: {
3203
+ value: RiskMarketIoc;
3204
+ case: "marketIoc";
3205
+ } | {
3206
+ value: RiskLimitGtc;
3207
+ case: "limitGtc";
3208
+ };
3209
+ };
3210
+ } | undefined;
3211
+ stopLeg: {
3212
+ readonly case: "stopLoss";
3213
+ readonly value: {
3214
+ triggerPriceTicks: bigint;
3215
+ child: {
3216
+ execution: {
3217
+ value: RiskMarketIoc;
3218
+ case: "marketIoc";
3219
+ } | {
3220
+ value: RiskLimitGtc;
3221
+ case: "limitGtc";
3222
+ };
3223
+ };
3224
+ };
3225
+ } | {
3226
+ readonly case: "trailingStop";
3227
+ readonly value: {
3228
+ trailingDistance: {
3229
+ value: bigint;
3230
+ case: "trailingDistanceTicks";
3231
+ } | {
3232
+ value: number;
3233
+ case: "trailingDistanceBps";
3234
+ } | {
3235
+ case: undefined;
3236
+ value?: undefined;
3237
+ };
3238
+ maxSlippage: {
3239
+ value: number;
3240
+ case: "maxSlippageTicks";
3241
+ } | {
3242
+ value: number;
3243
+ case: "maxSlippageBps";
3244
+ } | {
3245
+ case: undefined;
3246
+ value?: undefined;
3247
+ };
3248
+ activationPriceTicks: bigint;
3249
+ };
3250
+ } | {
3251
+ readonly case: undefined;
3252
+ readonly value: undefined;
3253
+ };
3254
+ oco: boolean;
3255
+ } | undefined;
3256
+ account?: "active" | "main" | {
3257
+ subaccountId: string;
3258
+ } | undefined;
3259
+ } | {
3260
+ qty?: undefined;
3261
+ maxQuoteDebit: string;
3262
+ symbol: string;
3263
+ side: Side.BUY | Side.SELL;
3264
+ execution: {
3265
+ case: "marketIoc";
3266
+ value: MarketIoc;
3267
+ } | {
3268
+ case: "limitGtc";
3269
+ value: LimitGtc;
3270
+ } | {
3271
+ case: "limitIoc";
3272
+ value: LimitIoc;
3273
+ } | {
3274
+ case: "limitFok";
3275
+ value: LimitFok;
3276
+ };
3277
+ clientOrderId?: string | undefined;
3278
+ feeAsset?: FeeAsset.QUOTE | FeeAsset.BASE | undefined;
3279
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
3280
+ risk?: {
3281
+ takeProfit: {
3282
+ triggerPriceTicks: bigint;
3283
+ child: {
3284
+ execution: {
3285
+ value: RiskMarketIoc;
3286
+ case: "marketIoc";
3287
+ } | {
3288
+ value: RiskLimitGtc;
3289
+ case: "limitGtc";
3290
+ };
3291
+ };
3292
+ } | undefined;
3293
+ stopLeg: {
3294
+ readonly case: "stopLoss";
3295
+ readonly value: {
3296
+ triggerPriceTicks: bigint;
3297
+ child: {
3298
+ execution: {
3299
+ value: RiskMarketIoc;
3300
+ case: "marketIoc";
3301
+ } | {
3302
+ value: RiskLimitGtc;
3303
+ case: "limitGtc";
3304
+ };
3305
+ };
3306
+ };
3307
+ } | {
3308
+ readonly case: "trailingStop";
3309
+ readonly value: {
3310
+ trailingDistance: {
3311
+ value: bigint;
3312
+ case: "trailingDistanceTicks";
3313
+ } | {
3314
+ value: number;
3315
+ case: "trailingDistanceBps";
3316
+ } | {
3317
+ case: undefined;
3318
+ value?: undefined;
3319
+ };
3320
+ maxSlippage: {
3321
+ value: number;
3322
+ case: "maxSlippageTicks";
3323
+ } | {
3324
+ value: number;
3325
+ case: "maxSlippageBps";
3326
+ } | {
3327
+ case: undefined;
3328
+ value?: undefined;
3329
+ };
3330
+ activationPriceTicks: bigint;
3331
+ };
3332
+ } | {
3333
+ readonly case: undefined;
3334
+ readonly value: undefined;
3335
+ };
3336
+ oco: boolean;
3337
+ } | undefined;
3338
+ account?: "active" | "main" | {
3339
+ subaccountId: string;
3340
+ } | undefined;
3341
+ }, {
3342
+ subaccountId: bigint | undefined;
3343
+ order: {
3344
+ sizing: {
3345
+ readonly case: "baseQtyScaled";
3346
+ readonly value: bigint;
3347
+ } | {
3348
+ readonly case: "maxQuoteDebitScaled";
3349
+ readonly value: bigint;
3350
+ };
3351
+ feeAsset: FeeAsset.QUOTE | FeeAsset.BASE;
3352
+ attachedRisk: {
3353
+ takeProfit: {
3354
+ triggerPriceTicks: bigint;
3355
+ child: {
3356
+ execution: {
3357
+ value: RiskMarketIoc;
3358
+ case: "marketIoc";
3359
+ } | {
3360
+ value: RiskLimitGtc;
3361
+ case: "limitGtc";
3362
+ };
3363
+ };
3364
+ } | undefined;
3365
+ stopLeg: {
3366
+ readonly case: "stopLoss";
3367
+ readonly value: {
3368
+ triggerPriceTicks: bigint;
3369
+ child: {
3370
+ execution: {
3371
+ value: RiskMarketIoc;
3372
+ case: "marketIoc";
3373
+ } | {
3374
+ value: RiskLimitGtc;
3375
+ case: "limitGtc";
3376
+ };
3377
+ };
3378
+ };
3379
+ } | {
3380
+ readonly case: "trailingStop";
3381
+ readonly value: {
3382
+ trailingDistance: {
3383
+ value: bigint;
3384
+ case: "trailingDistanceTicks";
3385
+ } | {
3386
+ value: number;
3387
+ case: "trailingDistanceBps";
3388
+ } | {
3389
+ case: undefined;
3390
+ value?: undefined;
3391
+ };
3392
+ maxSlippage: {
3393
+ value: number;
3394
+ case: "maxSlippageTicks";
3395
+ } | {
3396
+ value: number;
3397
+ case: "maxSlippageBps";
3398
+ } | {
3399
+ case: undefined;
3400
+ value?: undefined;
3401
+ };
3402
+ activationPriceTicks: bigint;
3403
+ };
3404
+ } | {
3405
+ readonly case: undefined;
3406
+ readonly value: undefined;
3407
+ };
3408
+ oco: boolean;
3409
+ } | undefined;
3410
+ symbol: string;
3411
+ side: Side.BUY | Side.SELL;
3412
+ execution: {
3413
+ case: "marketIoc";
3414
+ value: MarketIoc;
3415
+ } | {
3416
+ case: "limitGtc";
3417
+ value: LimitGtc;
3418
+ } | {
3419
+ case: "limitIoc";
3420
+ value: LimitIoc;
3421
+ } | {
3422
+ case: "limitFok";
3423
+ value: LimitFok;
3424
+ };
3425
+ clientOrderId?: string | undefined;
3426
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
3427
+ } | {
3428
+ sizing: {
3429
+ readonly case: "baseQtyScaled";
3430
+ readonly value: bigint;
3431
+ } | {
3432
+ readonly case: "maxQuoteDebitScaled";
3433
+ readonly value: bigint;
3434
+ };
3435
+ feeAsset: FeeAsset.QUOTE | FeeAsset.BASE;
3436
+ attachedRisk: {
3437
+ takeProfit: {
3438
+ triggerPriceTicks: bigint;
3439
+ child: {
3440
+ execution: {
3441
+ value: RiskMarketIoc;
3442
+ case: "marketIoc";
3443
+ } | {
3444
+ value: RiskLimitGtc;
3445
+ case: "limitGtc";
3446
+ };
3447
+ };
3448
+ } | undefined;
3449
+ stopLeg: {
3450
+ readonly case: "stopLoss";
3451
+ readonly value: {
3452
+ triggerPriceTicks: bigint;
3453
+ child: {
3454
+ execution: {
3455
+ value: RiskMarketIoc;
3456
+ case: "marketIoc";
3457
+ } | {
3458
+ value: RiskLimitGtc;
3459
+ case: "limitGtc";
3460
+ };
3461
+ };
3462
+ };
3463
+ } | {
3464
+ readonly case: "trailingStop";
3465
+ readonly value: {
3466
+ trailingDistance: {
3467
+ value: bigint;
3468
+ case: "trailingDistanceTicks";
3469
+ } | {
3470
+ value: number;
3471
+ case: "trailingDistanceBps";
3472
+ } | {
3473
+ case: undefined;
3474
+ value?: undefined;
3475
+ };
3476
+ maxSlippage: {
3477
+ value: number;
3478
+ case: "maxSlippageTicks";
3479
+ } | {
3480
+ value: number;
3481
+ case: "maxSlippageBps";
3482
+ } | {
3483
+ case: undefined;
3484
+ value?: undefined;
3485
+ };
3486
+ activationPriceTicks: bigint;
3487
+ };
3488
+ } | {
3489
+ readonly case: undefined;
3490
+ readonly value: undefined;
3491
+ };
3492
+ oco: boolean;
3493
+ } | undefined;
3494
+ symbol: string;
3495
+ side: Side.BUY | Side.SELL;
3496
+ execution: {
3497
+ case: "marketIoc";
3498
+ value: MarketIoc;
3499
+ } | {
3500
+ case: "limitGtc";
3501
+ value: LimitGtc;
3502
+ } | {
3503
+ case: "limitIoc";
3504
+ value: LimitIoc;
3505
+ } | {
3506
+ case: "limitFok";
3507
+ value: LimitFok;
3508
+ };
3509
+ clientOrderId?: string | undefined;
3510
+ selfTradePreventionMode?: SelfTradePreventionMode.EXPIRE_MAKER | SelfTradePreventionMode.EXPIRE_TAKER | SelfTradePreventionMode.EXPIRE_BOTH | undefined;
3511
+ };
3512
+ }>]>;
3513
+ type NewOrderInput = v.InferInput<ReturnType<typeof createNewOrderInputSchema>>;
3514
+ declare const CancelOrderInputSchema: v.SchemaWithPipe<readonly [v.UnionSchema<[v.StrictObjectSchema<{
3515
+ readonly orderId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.TransformAction<string, bigint>]>;
3516
+ readonly clientOrderId: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
3517
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
3518
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
3519
+ }, undefined>], undefined>, undefined>;
3520
+ readonly symbolId: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
3521
+ }, undefined>, v.StrictObjectSchema<{
3522
+ readonly orderId: v.OptionalSchema<v.NeverSchema<undefined>, undefined>;
3523
+ readonly clientOrderId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
3524
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
3525
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
3526
+ }, undefined>], undefined>, undefined>;
3527
+ readonly symbolId: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
3528
+ }, undefined>], undefined>, v.TransformAction<{
3529
+ orderId: bigint;
3530
+ clientOrderId?: undefined;
3531
+ account?: "active" | "main" | {
3532
+ subaccountId: string;
3533
+ } | undefined;
3534
+ symbolId?: number | undefined;
3535
+ } | {
3536
+ orderId?: undefined;
3537
+ clientOrderId: string;
3538
+ account?: "active" | "main" | {
3539
+ subaccountId: string;
3540
+ } | undefined;
3541
+ symbolId?: number | undefined;
3542
+ }, {
3543
+ subaccountId: bigint | undefined;
3544
+ key: {
3545
+ readonly case: "orderId";
3546
+ readonly value: bigint;
3547
+ } | {
3548
+ readonly case: "clientOrderId";
3549
+ readonly value: string;
3550
+ };
3551
+ symbolId?: number | undefined;
3552
+ } | {
3553
+ subaccountId: bigint | undefined;
3554
+ key: {
3555
+ readonly case: "orderId";
3556
+ readonly value: bigint;
3557
+ } | {
3558
+ readonly case: "clientOrderId";
3559
+ readonly value: string;
3560
+ };
3561
+ symbolId?: number | undefined;
3562
+ }>]>;
3563
+ type CancelOrderInput = v.InferInput<typeof CancelOrderInputSchema>;
3564
+ declare const CancelOrderResultSchema: v.ObjectSchema<{
3565
+ readonly status: v.StringSchema<undefined>;
3566
+ readonly orderId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
3567
+ readonly tsNs: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, number>]>;
3568
+ }, undefined>;
3569
+ type CancelOrderResult = v.InferOutput<typeof CancelOrderResultSchema>;
3570
+ declare const CancelAllOrdersInputSchema: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
3571
+ readonly symbol: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>;
3572
+ readonly side: v.SchemaWithPipe<readonly [v.OptionalSchema<v.PicklistSchema<["buy", "sell"], undefined>, undefined>, v.TransformAction<"buy" | "sell" | undefined, Side.BUY | Side.SELL | undefined>]>;
3573
+ readonly dryRun: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
3574
+ readonly requestId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>, undefined>;
3575
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
3576
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
3577
+ }, undefined>], undefined>, undefined>;
3578
+ }, undefined>, v.TransformAction<{
3579
+ symbol?: string | undefined;
3580
+ side?: Side.BUY | Side.SELL | undefined;
3581
+ dryRun: boolean;
3582
+ requestId?: string | undefined;
3583
+ account?: "active" | "main" | {
3584
+ subaccountId: string;
3585
+ } | undefined;
3586
+ }, {
3587
+ subaccountId: bigint | undefined;
3588
+ symbol?: string | undefined;
3589
+ side?: Side.BUY | Side.SELL | undefined;
3590
+ dryRun: boolean;
3591
+ requestId?: string | undefined;
3592
+ }>]>;
3593
+ type CancelAllOrdersInput = v.InferInput<typeof CancelAllOrdersInputSchema>;
3594
+ declare const CancelAllOrdersResponseSchema: v.SchemaWithPipe<readonly [v.ObjectSchema<{
3595
+ readonly status: v.StringSchema<undefined>;
3596
+ readonly matchedOrders: v.NumberSchema<undefined>;
3597
+ readonly submittedCancels: v.NumberSchema<undefined>;
3598
+ readonly failedCancels: v.NumberSchema<undefined>;
3599
+ readonly tsNs: v.BigintSchema<undefined>;
3600
+ }, undefined>, v.TransformAction<{
3601
+ status: string;
3602
+ matchedOrders: number;
3603
+ submittedCancels: number;
3604
+ failedCancels: number;
3605
+ tsNs: bigint;
3606
+ }, {
3607
+ status: string;
3608
+ matchedOrders: number;
3609
+ submittedCancels: number;
3610
+ failedCancels: number;
3611
+ ts: number;
3612
+ }>]>;
3613
+ type CancelAllOrdersResponse = v.InferOutput<typeof CancelAllOrdersResponseSchema>;
3614
+ declare const GetOrderDetailsInputSchema: v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
3615
+ readonly includeAttachedRisk: v.OptionalSchema<v.BooleanSchema<undefined>, true>;
3616
+ readonly includeAttachedRiskState: v.OptionalSchema<v.BooleanSchema<undefined>, true>;
3617
+ readonly account: v.OptionalSchema<v.UnionSchema<[v.PicklistSchema<["active", "main"], undefined>, v.StrictObjectSchema<{
3618
+ readonly subaccountId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
3619
+ }, undefined>], undefined>, undefined>;
3620
+ readonly orderId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>;
3621
+ readonly clientOrderId: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction]>, undefined>;
3622
+ }, undefined>, v.CheckAction<{
3623
+ includeAttachedRisk: boolean;
3624
+ includeAttachedRiskState: boolean;
3625
+ account?: "active" | "main" | {
3626
+ subaccountId: string;
3627
+ } | undefined;
3628
+ orderId?: string | undefined;
3629
+ clientOrderId?: string | undefined;
3630
+ }, "Provide exactly one of orderId or clientOrderId">, v.TransformAction<{
3631
+ includeAttachedRisk: boolean;
3632
+ includeAttachedRiskState: boolean;
3633
+ account?: "active" | "main" | {
3634
+ subaccountId: string;
3635
+ } | undefined;
3636
+ orderId?: string | undefined;
3637
+ clientOrderId?: string | undefined;
3638
+ }, {
3639
+ subaccountId: bigint | undefined;
3640
+ key: {
3641
+ readonly case: "orderId";
3642
+ readonly value: bigint;
3643
+ } | {
3644
+ readonly case: "clientOrderId";
3645
+ readonly value: string;
3646
+ };
3647
+ includeAttachedRisk: boolean;
3648
+ includeAttachedRiskState: boolean;
3649
+ }>]>;
3650
+ type GetOrderDetailsInput = v.InferInput<typeof GetOrderDetailsInputSchema>;
3651
+ declare function createCreateOrderResultSchema(scales: SdkScales, symbol: string): v.SchemaWithPipe<readonly [v.ObjectSchema<{
3652
+ readonly orderId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
3653
+ readonly clientOrderId: v.StringSchema<undefined>;
3654
+ readonly acceptedAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
3655
+ readonly seconds: v.BigintSchema<undefined>;
3656
+ readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
3657
+ }, undefined>, undefined>, v.TransformAction<{
3658
+ seconds: bigint;
3659
+ nanos: number;
3660
+ } | undefined, number | undefined>]>;
3661
+ readonly acceptedAtTsNs: v.BigintSchema<undefined>;
3662
+ readonly resolvedBaseQtyScaled: v.BigintSchema<undefined>;
3663
+ readonly submittedMaxQuoteDebitScaled: v.OptionalSchema<v.BigintSchema<undefined>, undefined>;
3664
+ readonly takeProfitTriggerId: v.SchemaWithPipe<readonly [v.OptionalSchema<v.BigintSchema<undefined>, undefined>, v.TransformAction<bigint | undefined, string | undefined>]>;
3665
+ readonly stopLossTriggerId: v.SchemaWithPipe<readonly [v.OptionalSchema<v.BigintSchema<undefined>, undefined>, v.TransformAction<bigint | undefined, string | undefined>]>;
3666
+ readonly trailingStopTriggerId: v.SchemaWithPipe<readonly [v.OptionalSchema<v.BigintSchema<undefined>, undefined>, v.TransformAction<bigint | undefined, string | undefined>]>;
3667
+ }, undefined>, v.TransformAction<{
3668
+ orderId: string;
3669
+ clientOrderId: string;
3670
+ acceptedAt?: number | undefined;
3671
+ acceptedAtTsNs: bigint;
3672
+ resolvedBaseQtyScaled: bigint;
3673
+ submittedMaxQuoteDebitScaled?: bigint | undefined;
3674
+ takeProfitTriggerId?: string | undefined;
3675
+ stopLossTriggerId?: string | undefined;
3676
+ trailingStopTriggerId?: string | undefined;
3677
+ }, {
3678
+ submittedMaxQuoteDebit?: string | undefined;
3679
+ acceptedAt: number;
3680
+ acceptedAtNs: string;
3681
+ resolvedBaseQty: string;
3682
+ orderId: string;
3683
+ clientOrderId: string;
3684
+ takeProfitTriggerId?: string | undefined;
3685
+ stopLossTriggerId?: string | undefined;
3686
+ trailingStopTriggerId?: string | undefined;
3687
+ }>]>;
3688
+ type CreateOrderResult = v.InferOutput<ReturnType<typeof createCreateOrderResultSchema>>;
3689
+ declare function createPreviewOrderResultSchema(scales: SdkScales, symbol: string): v.SchemaWithPipe<readonly [v.ObjectSchema<{
3690
+ readonly admissible: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
3691
+ readonly rejection: v.OptionalSchema<v.ObjectSchema<{
3692
+ readonly code: v.SchemaWithPipe<readonly [v.EnumSchema<typeof ErrorCode, undefined>, v.TransformAction<ErrorCode, "STALE_QUOTE" | "UNSPECIFIED" | "BAD_REQUEST" | "INVALID_ARGUMENT" | "INSUFFICIENT_FUNDS" | "UNKNOWN_SYMBOL" | "BAD_PRICE" | "BAD_QTY" | "MIN_NOTIONAL" | "QTY_STEP_SIZE" | "CONFLICT_DUPLICATE_CLIENT_ORDER_ID" | "UNAVAILABLE" | "UNAUTHENTICATED" | "PERMISSION_DENIED" | "NOT_FOUND" | "UPSTREAM_ERROR" | "FEE_ASSET_NOT_ALLOWED" | "PAIR_DISABLED" | "ORDER_UNKNOWN" | "INTERNAL_ERROR" | "SUBACCOUNT_INACTIVE" | "POLICY_MARKET_DENY" | "POLICY_MAX_NOTIONAL" | "POLICY_TRADING_HALTED" | "POLICY_SPOT_TRADE_DENY" | "API_KEY_ROOT_SCOPE_ONLY" | "API_KEY_SUB_SCOPE_ONLY" | "API_KEY_SUBACCOUNT_MISMATCH" | "API_KEY_POLICY_REQUIRED" | "API_KEY_UNKNOWN" | "API_KEY_MARKET_DENY" | "PRICE_TICK_SIZE" | "MIN_QTY" | "POST_ONLY_LIMIT_ONLY" | "BATCH_TOO_LARGE" | "MODIFICATION_REQUIRES_REPLACE" | "CONFLICT_IDEMPOTENCY_KEY_REUSE" | "MARKET_PRICE_UNAVAILABLE" | "PAIR_NOT_LISTED_YET" | "PAIR_DELISTED" | "PAIR_CANCEL_ONLY" | "PAIR_POST_ONLY" | "PAIR_REDUCE_ONLY" | "RISK_LIMIT" | "MARKET_HALTED" | "ACCOUNT_UNKNOWN" | "POST_ONLY_CROSS" | "REDUCE_ONLY_BLOCKED" | "PRICE_BAND_VIOLATION" | "MARKET_CAP_VIOLATION" | "EMPTY_BOOK" | "FOK_INSUFFICIENT_LIQUIDITY" | "ORDER_ALREADY_TERMINAL" | "TRIGGER_PRICE_INVALID" | "TRIGGER_PRICE_SOURCE_UNSUPPORTED" | "TRAILING_DISTANCE_INVALID" | "TRIGGER_NOT_FOUND" | "TRIGGER_CANCEL_REJECTED" | "TRIGGER_STATUS_INVALID" | "TRIGGER_NOT_MODIFIABLE" | "CONFLICT_DUPLICATE_CLIENT_TRIGGER_ID" | "MAX_SLIPPAGE_INVALID" | "VALIDATION_ERROR" | "OVERLOADED" | "MAX_QUOTE_DEBIT_TOO_SMALL">]>;
3693
+ readonly violations: v.ArraySchema<v.ObjectSchema<{
3694
+ readonly fieldPath: v.StringSchema<undefined>;
3695
+ readonly ruleId: v.StringSchema<undefined>;
3696
+ readonly message: v.StringSchema<undefined>;
3697
+ }, undefined>, undefined>;
3698
+ }, undefined>, undefined>;
3699
+ readonly resolvedBaseQtyScaled: v.OptionalSchema<v.BigintSchema<undefined>, undefined>;
3700
+ readonly protectedPriceBoundTicks: v.OptionalSchema<v.BigintSchema<undefined>, undefined>;
3701
+ readonly evaluatedAt: v.SchemaWithPipe<readonly [v.ObjectSchema<{
3702
+ readonly seconds: v.BigintSchema<undefined>;
3703
+ readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
3704
+ }, undefined>, v.TransformAction<{
3705
+ seconds: bigint;
3706
+ nanos: number;
3707
+ }, number>]>;
3708
+ }, undefined>, v.TransformAction<{
3709
+ admissible?: boolean | undefined;
3710
+ rejection?: {
3711
+ code: "STALE_QUOTE" | "UNSPECIFIED" | "BAD_REQUEST" | "INVALID_ARGUMENT" | "INSUFFICIENT_FUNDS" | "UNKNOWN_SYMBOL" | "BAD_PRICE" | "BAD_QTY" | "MIN_NOTIONAL" | "QTY_STEP_SIZE" | "CONFLICT_DUPLICATE_CLIENT_ORDER_ID" | "UNAVAILABLE" | "UNAUTHENTICATED" | "PERMISSION_DENIED" | "NOT_FOUND" | "UPSTREAM_ERROR" | "FEE_ASSET_NOT_ALLOWED" | "PAIR_DISABLED" | "ORDER_UNKNOWN" | "INTERNAL_ERROR" | "SUBACCOUNT_INACTIVE" | "POLICY_MARKET_DENY" | "POLICY_MAX_NOTIONAL" | "POLICY_TRADING_HALTED" | "POLICY_SPOT_TRADE_DENY" | "API_KEY_ROOT_SCOPE_ONLY" | "API_KEY_SUB_SCOPE_ONLY" | "API_KEY_SUBACCOUNT_MISMATCH" | "API_KEY_POLICY_REQUIRED" | "API_KEY_UNKNOWN" | "API_KEY_MARKET_DENY" | "PRICE_TICK_SIZE" | "MIN_QTY" | "POST_ONLY_LIMIT_ONLY" | "BATCH_TOO_LARGE" | "MODIFICATION_REQUIRES_REPLACE" | "CONFLICT_IDEMPOTENCY_KEY_REUSE" | "MARKET_PRICE_UNAVAILABLE" | "PAIR_NOT_LISTED_YET" | "PAIR_DELISTED" | "PAIR_CANCEL_ONLY" | "PAIR_POST_ONLY" | "PAIR_REDUCE_ONLY" | "RISK_LIMIT" | "MARKET_HALTED" | "ACCOUNT_UNKNOWN" | "POST_ONLY_CROSS" | "REDUCE_ONLY_BLOCKED" | "PRICE_BAND_VIOLATION" | "MARKET_CAP_VIOLATION" | "EMPTY_BOOK" | "FOK_INSUFFICIENT_LIQUIDITY" | "ORDER_ALREADY_TERMINAL" | "TRIGGER_PRICE_INVALID" | "TRIGGER_PRICE_SOURCE_UNSUPPORTED" | "TRAILING_DISTANCE_INVALID" | "TRIGGER_NOT_FOUND" | "TRIGGER_CANCEL_REJECTED" | "TRIGGER_STATUS_INVALID" | "TRIGGER_NOT_MODIFIABLE" | "CONFLICT_DUPLICATE_CLIENT_TRIGGER_ID" | "MAX_SLIPPAGE_INVALID" | "VALIDATION_ERROR" | "OVERLOADED" | "MAX_QUOTE_DEBIT_TOO_SMALL";
3712
+ violations: {
3713
+ fieldPath: string;
3714
+ ruleId: string;
3715
+ message: string;
3716
+ }[];
3717
+ } | undefined;
3718
+ resolvedBaseQtyScaled?: bigint | undefined;
3719
+ protectedPriceBoundTicks?: bigint | undefined;
3720
+ evaluatedAt: number;
3721
+ }, {
3722
+ protectedPriceBound?: string | undefined;
3723
+ resolvedBaseQty?: string | undefined;
3724
+ admissible?: boolean | undefined;
3725
+ rejection?: {
3726
+ code: "STALE_QUOTE" | "UNSPECIFIED" | "BAD_REQUEST" | "INVALID_ARGUMENT" | "INSUFFICIENT_FUNDS" | "UNKNOWN_SYMBOL" | "BAD_PRICE" | "BAD_QTY" | "MIN_NOTIONAL" | "QTY_STEP_SIZE" | "CONFLICT_DUPLICATE_CLIENT_ORDER_ID" | "UNAVAILABLE" | "UNAUTHENTICATED" | "PERMISSION_DENIED" | "NOT_FOUND" | "UPSTREAM_ERROR" | "FEE_ASSET_NOT_ALLOWED" | "PAIR_DISABLED" | "ORDER_UNKNOWN" | "INTERNAL_ERROR" | "SUBACCOUNT_INACTIVE" | "POLICY_MARKET_DENY" | "POLICY_MAX_NOTIONAL" | "POLICY_TRADING_HALTED" | "POLICY_SPOT_TRADE_DENY" | "API_KEY_ROOT_SCOPE_ONLY" | "API_KEY_SUB_SCOPE_ONLY" | "API_KEY_SUBACCOUNT_MISMATCH" | "API_KEY_POLICY_REQUIRED" | "API_KEY_UNKNOWN" | "API_KEY_MARKET_DENY" | "PRICE_TICK_SIZE" | "MIN_QTY" | "POST_ONLY_LIMIT_ONLY" | "BATCH_TOO_LARGE" | "MODIFICATION_REQUIRES_REPLACE" | "CONFLICT_IDEMPOTENCY_KEY_REUSE" | "MARKET_PRICE_UNAVAILABLE" | "PAIR_NOT_LISTED_YET" | "PAIR_DELISTED" | "PAIR_CANCEL_ONLY" | "PAIR_POST_ONLY" | "PAIR_REDUCE_ONLY" | "RISK_LIMIT" | "MARKET_HALTED" | "ACCOUNT_UNKNOWN" | "POST_ONLY_CROSS" | "REDUCE_ONLY_BLOCKED" | "PRICE_BAND_VIOLATION" | "MARKET_CAP_VIOLATION" | "EMPTY_BOOK" | "FOK_INSUFFICIENT_LIQUIDITY" | "ORDER_ALREADY_TERMINAL" | "TRIGGER_PRICE_INVALID" | "TRIGGER_PRICE_SOURCE_UNSUPPORTED" | "TRAILING_DISTANCE_INVALID" | "TRIGGER_NOT_FOUND" | "TRIGGER_CANCEL_REJECTED" | "TRIGGER_STATUS_INVALID" | "TRIGGER_NOT_MODIFIABLE" | "CONFLICT_DUPLICATE_CLIENT_TRIGGER_ID" | "MAX_SLIPPAGE_INVALID" | "VALIDATION_ERROR" | "OVERLOADED" | "MAX_QUOTE_DEBIT_TOO_SMALL";
3727
+ violations: {
3728
+ fieldPath: string;
3729
+ ruleId: string;
3730
+ message: string;
3731
+ }[];
3732
+ } | undefined;
3733
+ evaluatedAt: number;
3734
+ }>]>;
3735
+ type PreviewOrderResult = v.InferOutput<ReturnType<typeof createPreviewOrderResultSchema>>;
3736
+ //#endregion
3737
+ export { CancelAllOrdersInput, CancelAllOrdersInputSchema, CancelAllOrdersResponse, CancelAllOrdersResponseSchema, CancelOrderInput, CancelOrderInputSchema, CancelOrderResult, CancelOrderResultSchema, CreateOrderResult, GetOrderDetailsInput, GetOrderDetailsInputSchema, NewOrderInput, OpenOrdersInput, OpenOrdersInputSchema, OrderHistoryInput, OrderHistoryInputSchema, OrderIntentInput, PreviewOrderResult, createCreateOrderResultSchema, createNewOrderInputSchema, createOrderIntentInputSchema, createPreviewOrderResultSchema };
3738
+ //# sourceMappingURL=orders-input.schemas.d.ts.map