@nktkas/hyperliquid 0.24.3 → 0.25.0-beta.2
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.
- package/README.md +141 -32
- package/esm/mod.d.ts +11 -11
- package/esm/mod.d.ts.map +1 -1
- package/esm/mod.js +2 -1
- package/esm/mod.js.map +1 -0
- package/esm/src/clients/exchange.d.ts +29 -25
- package/esm/src/clients/exchange.d.ts.map +1 -1
- package/esm/src/clients/exchange.js +54 -53
- package/esm/src/clients/exchange.js.map +1 -0
- package/esm/src/clients/info.d.ts +80 -20
- package/esm/src/clients/info.d.ts.map +1 -1
- package/esm/src/clients/info.js +312 -73
- package/esm/src/clients/info.js.map +1 -0
- package/esm/src/clients/multiSign.d.ts +11 -7
- package/esm/src/clients/multiSign.d.ts.map +1 -1
- package/esm/src/clients/multiSign.js +2 -1
- package/esm/src/clients/multiSign.js.map +1 -0
- package/esm/src/clients/subscription.d.ts +9 -9
- package/esm/src/clients/subscription.d.ts.map +1 -1
- package/esm/src/clients/subscription.js +29 -27
- package/esm/src/clients/subscription.js.map +1 -0
- package/esm/src/{base.d.ts → errors.d.ts} +1 -1
- package/esm/src/errors.d.ts.map +1 -0
- package/esm/src/{base.js → errors.js} +1 -0
- package/esm/src/errors.js.map +1 -0
- package/esm/src/schemas/_base.d.ts +14 -0
- package/esm/src/schemas/_base.d.ts.map +1 -0
- package/esm/src/schemas/_base.js +15 -0
- package/esm/src/schemas/_base.js.map +1 -0
- package/esm/src/schemas/exchange/requests.d.ts +8953 -0
- package/esm/src/schemas/exchange/requests.d.ts.map +1 -0
- package/esm/src/schemas/exchange/requests.js +1414 -0
- package/esm/src/schemas/exchange/requests.js.map +1 -0
- package/esm/src/schemas/exchange/responses.d.ts +567 -0
- package/esm/src/schemas/exchange/responses.d.ts.map +1 -0
- package/esm/src/schemas/exchange/responses.js +244 -0
- package/esm/src/schemas/exchange/responses.js.map +1 -0
- package/esm/src/schemas/explorer/requests.d.ts +44 -0
- package/esm/src/schemas/explorer/requests.d.ts.map +1 -0
- package/esm/src/schemas/explorer/requests.js +33 -0
- package/esm/src/schemas/explorer/requests.js.map +1 -0
- package/esm/src/schemas/explorer/responses.d.ts +360 -0
- package/esm/src/schemas/explorer/responses.d.ts.map +1 -0
- package/esm/src/schemas/explorer/responses.js +57 -0
- package/esm/src/schemas/explorer/responses.js.map +1 -0
- package/esm/src/schemas/info/accounts.d.ts +2159 -0
- package/esm/src/schemas/info/accounts.d.ts.map +1 -0
- package/esm/src/schemas/info/accounts.js +623 -0
- package/esm/src/schemas/info/accounts.js.map +1 -0
- package/esm/src/schemas/info/assets.d.ts +974 -0
- package/esm/src/schemas/info/assets.d.ts.map +1 -0
- package/esm/src/schemas/info/assets.js +285 -0
- package/esm/src/schemas/info/assets.js.map +1 -0
- package/esm/src/schemas/info/markets.d.ts +155 -0
- package/esm/src/schemas/info/markets.d.ts.map +1 -0
- package/esm/src/schemas/info/markets.js +70 -0
- package/esm/src/schemas/info/markets.js.map +1 -0
- package/esm/src/schemas/info/orders.d.ts +957 -0
- package/esm/src/schemas/info/orders.d.ts.map +1 -0
- package/esm/src/schemas/info/orders.js +298 -0
- package/esm/src/schemas/info/orders.js.map +1 -0
- package/esm/src/schemas/info/requests.d.ts +924 -0
- package/esm/src/schemas/info/requests.d.ts.map +1 -0
- package/esm/src/schemas/info/requests.js +687 -0
- package/esm/src/schemas/info/requests.js.map +1 -0
- package/esm/src/schemas/info/validators.d.ts +326 -0
- package/esm/src/schemas/info/validators.d.ts.map +1 -0
- package/esm/src/schemas/info/validators.js +126 -0
- package/esm/src/schemas/info/validators.js.map +1 -0
- package/esm/src/schemas/info/vaults.d.ts +447 -0
- package/esm/src/schemas/info/vaults.d.ts.map +1 -0
- package/esm/src/schemas/info/vaults.js +111 -0
- package/esm/src/schemas/info/vaults.js.map +1 -0
- package/esm/src/schemas/mod.d.ts +101 -0
- package/esm/src/schemas/mod.d.ts.map +1 -0
- package/esm/src/schemas/mod.js +115 -0
- package/esm/src/schemas/mod.js.map +1 -0
- package/esm/src/schemas/subscriptions/requests.d.ts +332 -0
- package/esm/src/schemas/subscriptions/requests.d.ts.map +1 -0
- package/esm/src/schemas/subscriptions/requests.js +259 -0
- package/esm/src/schemas/subscriptions/requests.js.map +1 -0
- package/esm/src/schemas/subscriptions/responses.d.ts +3643 -0
- package/esm/src/schemas/subscriptions/responses.d.ts.map +1 -0
- package/esm/src/schemas/subscriptions/responses.js +234 -0
- package/esm/src/schemas/subscriptions/responses.js.map +1 -0
- package/esm/src/signing/_signTypedData/ethers.js +1 -0
- package/esm/src/signing/_signTypedData/ethers.js.map +1 -0
- package/esm/src/signing/_signTypedData/mod.js +1 -0
- package/esm/src/signing/_signTypedData/mod.js.map +1 -0
- package/esm/src/signing/_signTypedData/private_key.js +1 -0
- package/esm/src/signing/_signTypedData/private_key.js.map +1 -0
- package/esm/src/signing/_signTypedData/viem.js +1 -0
- package/esm/src/signing/_signTypedData/viem.js.map +1 -0
- package/esm/src/signing/mod.d.ts +109 -29
- package/esm/src/signing/mod.d.ts.map +1 -1
- package/esm/src/signing/mod.js +136 -29
- package/esm/src/signing/mod.js.map +1 -0
- package/esm/src/transports/base.d.ts +4 -4
- package/esm/src/transports/base.d.ts.map +1 -1
- package/esm/src/transports/base.js +3 -2
- package/esm/src/transports/base.js.map +1 -0
- package/esm/src/transports/http/http_transport.d.ts +3 -2
- package/esm/src/transports/http/http_transport.d.ts.map +1 -1
- package/esm/src/transports/http/http_transport.js +1 -0
- package/esm/src/transports/http/http_transport.js.map +1 -0
- package/esm/src/transports/websocket/_hyperliquid_event_target.d.ts +1 -1
- package/esm/src/transports/websocket/_hyperliquid_event_target.d.ts.map +1 -1
- package/esm/src/transports/websocket/_hyperliquid_event_target.js +1 -0
- package/esm/src/transports/websocket/_hyperliquid_event_target.js.map +1 -0
- package/esm/src/transports/websocket/_reconnecting_websocket.js +1 -0
- package/esm/src/transports/websocket/_reconnecting_websocket.js.map +1 -0
- package/esm/src/transports/websocket/_websocket_async_request.js +1 -0
- package/esm/src/transports/websocket/_websocket_async_request.js.map +1 -0
- package/esm/src/transports/websocket/websocket_transport.d.ts +9 -1
- package/esm/src/transports/websocket/websocket_transport.d.ts.map +1 -1
- package/esm/src/transports/websocket/websocket_transport.js +4 -0
- package/esm/src/transports/websocket/websocket_transport.js.map +1 -0
- package/package.json +6 -5
- package/script/mod.d.ts +11 -11
- package/script/mod.d.ts.map +1 -1
- package/script/mod.js +2 -1
- package/script/mod.js.map +1 -0
- package/script/src/clients/exchange.d.ts +29 -25
- package/script/src/clients/exchange.d.ts.map +1 -1
- package/script/src/clients/exchange.js +60 -59
- package/script/src/clients/exchange.js.map +1 -0
- package/script/src/clients/info.d.ts +80 -20
- package/script/src/clients/info.d.ts.map +1 -1
- package/script/src/clients/info.js +312 -73
- package/script/src/clients/info.js.map +1 -0
- package/script/src/clients/multiSign.d.ts +11 -7
- package/script/src/clients/multiSign.d.ts.map +1 -1
- package/script/src/clients/multiSign.js +2 -1
- package/script/src/clients/multiSign.js.map +1 -0
- package/script/src/clients/subscription.d.ts +9 -9
- package/script/src/clients/subscription.d.ts.map +1 -1
- package/script/src/clients/subscription.js +29 -27
- package/script/src/clients/subscription.js.map +1 -0
- package/script/src/{base.d.ts → errors.d.ts} +1 -1
- package/script/src/errors.d.ts.map +1 -0
- package/script/src/{base.js → errors.js} +1 -0
- package/script/src/errors.js.map +1 -0
- package/script/src/schemas/_base.d.ts +14 -0
- package/script/src/schemas/_base.d.ts.map +1 -0
- package/script/src/schemas/_base.js +51 -0
- package/script/src/schemas/_base.js.map +1 -0
- package/script/src/schemas/exchange/requests.d.ts +8953 -0
- package/script/src/schemas/exchange/requests.d.ts.map +1 -0
- package/script/src/schemas/exchange/requests.js +1450 -0
- package/script/src/schemas/exchange/requests.js.map +1 -0
- package/script/src/schemas/exchange/responses.d.ts +567 -0
- package/script/src/schemas/exchange/responses.d.ts.map +1 -0
- package/script/src/schemas/exchange/responses.js +280 -0
- package/script/src/schemas/exchange/responses.js.map +1 -0
- package/script/src/schemas/explorer/requests.d.ts +44 -0
- package/script/src/schemas/explorer/requests.d.ts.map +1 -0
- package/script/src/schemas/explorer/requests.js +69 -0
- package/script/src/schemas/explorer/requests.js.map +1 -0
- package/script/src/schemas/explorer/responses.d.ts +360 -0
- package/script/src/schemas/explorer/responses.d.ts.map +1 -0
- package/script/src/schemas/explorer/responses.js +93 -0
- package/script/src/schemas/explorer/responses.js.map +1 -0
- package/script/src/schemas/info/accounts.d.ts +2159 -0
- package/script/src/schemas/info/accounts.d.ts.map +1 -0
- package/script/src/schemas/info/accounts.js +659 -0
- package/script/src/schemas/info/accounts.js.map +1 -0
- package/script/src/schemas/info/assets.d.ts +974 -0
- package/script/src/schemas/info/assets.d.ts.map +1 -0
- package/script/src/schemas/info/assets.js +321 -0
- package/script/src/schemas/info/assets.js.map +1 -0
- package/script/src/schemas/info/markets.d.ts +155 -0
- package/script/src/schemas/info/markets.d.ts.map +1 -0
- package/script/src/schemas/info/markets.js +106 -0
- package/script/src/schemas/info/markets.js.map +1 -0
- package/script/src/schemas/info/orders.d.ts +957 -0
- package/script/src/schemas/info/orders.d.ts.map +1 -0
- package/script/src/schemas/info/orders.js +334 -0
- package/script/src/schemas/info/orders.js.map +1 -0
- package/script/src/schemas/info/requests.d.ts +924 -0
- package/script/src/schemas/info/requests.d.ts.map +1 -0
- package/script/src/schemas/info/requests.js +724 -0
- package/script/src/schemas/info/requests.js.map +1 -0
- package/script/src/schemas/info/validators.d.ts +326 -0
- package/script/src/schemas/info/validators.d.ts.map +1 -0
- package/script/src/schemas/info/validators.js +162 -0
- package/script/src/schemas/info/validators.js.map +1 -0
- package/script/src/schemas/info/vaults.d.ts +447 -0
- package/script/src/schemas/info/vaults.d.ts.map +1 -0
- package/script/src/schemas/info/vaults.js +147 -0
- package/script/src/schemas/info/vaults.js.map +1 -0
- package/script/src/schemas/mod.d.ts +101 -0
- package/script/src/schemas/mod.d.ts.map +1 -0
- package/script/src/schemas/mod.js +157 -0
- package/script/src/schemas/mod.js.map +1 -0
- package/script/src/schemas/subscriptions/requests.d.ts +332 -0
- package/script/src/schemas/subscriptions/requests.d.ts.map +1 -0
- package/script/src/schemas/subscriptions/requests.js +295 -0
- package/script/src/schemas/subscriptions/requests.js.map +1 -0
- package/script/src/schemas/subscriptions/responses.d.ts +3643 -0
- package/script/src/schemas/subscriptions/responses.d.ts.map +1 -0
- package/script/src/schemas/subscriptions/responses.js +270 -0
- package/script/src/schemas/subscriptions/responses.js.map +1 -0
- package/script/src/signing/_signTypedData/ethers.js +1 -0
- package/script/src/signing/_signTypedData/ethers.js.map +1 -0
- package/script/src/signing/_signTypedData/mod.js +1 -0
- package/script/src/signing/_signTypedData/mod.js.map +1 -0
- package/script/src/signing/_signTypedData/private_key.js +1 -0
- package/script/src/signing/_signTypedData/private_key.js.map +1 -0
- package/script/src/signing/_signTypedData/viem.js +1 -0
- package/script/src/signing/_signTypedData/viem.js.map +1 -0
- package/script/src/signing/mod.d.ts +109 -29
- package/script/src/signing/mod.d.ts.map +1 -1
- package/script/src/signing/mod.js +138 -33
- package/script/src/signing/mod.js.map +1 -0
- package/script/src/transports/base.d.ts +4 -4
- package/script/src/transports/base.d.ts.map +1 -1
- package/script/src/transports/base.js +4 -3
- package/script/src/transports/base.js.map +1 -0
- package/script/src/transports/http/http_transport.d.ts +3 -2
- package/script/src/transports/http/http_transport.d.ts.map +1 -1
- package/script/src/transports/http/http_transport.js +1 -0
- package/script/src/transports/http/http_transport.js.map +1 -0
- package/script/src/transports/websocket/_hyperliquid_event_target.d.ts +1 -1
- package/script/src/transports/websocket/_hyperliquid_event_target.d.ts.map +1 -1
- package/script/src/transports/websocket/_hyperliquid_event_target.js +1 -0
- package/script/src/transports/websocket/_hyperliquid_event_target.js.map +1 -0
- package/script/src/transports/websocket/_reconnecting_websocket.js +1 -0
- package/script/src/transports/websocket/_reconnecting_websocket.js.map +1 -0
- package/script/src/transports/websocket/_websocket_async_request.js +1 -0
- package/script/src/transports/websocket/_websocket_async_request.js.map +1 -0
- package/script/src/transports/websocket/websocket_transport.d.ts +9 -1
- package/script/src/transports/websocket/websocket_transport.d.ts.map +1 -1
- package/script/src/transports/websocket/websocket_transport.js +4 -0
- package/script/src/transports/websocket/websocket_transport.js.map +1 -0
- package/src/mod.ts +28 -0
- package/src/src/clients/exchange.ts +2246 -0
- package/src/src/clients/info.ts +2076 -0
- package/src/src/clients/multiSign.ts +183 -0
- package/src/src/clients/subscription.ts +841 -0
- package/src/src/errors.ts +7 -0
- package/src/src/schemas/_base.ts +43 -0
- package/src/src/schemas/exchange/requests.ts +3057 -0
- package/src/src/schemas/exchange/responses.ts +540 -0
- package/src/src/schemas/explorer/requests.ts +65 -0
- package/src/src/schemas/explorer/responses.ts +138 -0
- package/src/src/schemas/info/accounts.ts +1490 -0
- package/src/src/schemas/info/assets.ts +693 -0
- package/src/src/schemas/info/markets.ts +171 -0
- package/src/src/schemas/info/orders.ts +597 -0
- package/src/src/schemas/info/requests.ts +1369 -0
- package/src/src/schemas/info/validators.ts +299 -0
- package/src/src/schemas/info/vaults.ts +262 -0
- package/src/src/schemas/mod.ts +121 -0
- package/src/src/schemas/subscriptions/requests.ts +504 -0
- package/src/src/schemas/subscriptions/responses.ts +576 -0
- package/src/src/signing/_signTypedData/ethers.ts +59 -0
- package/src/src/signing/_signTypedData/mod.ts +121 -0
- package/src/src/signing/_signTypedData/private_key.ts +229 -0
- package/src/src/signing/_signTypedData/viem.ts +55 -0
- package/src/src/signing/mod.ts +572 -0
- package/src/src/transports/base.ts +54 -0
- package/src/src/transports/http/http_transport.ts +208 -0
- package/src/src/transports/websocket/_hyperliquid_event_target.ts +118 -0
- package/src/src/transports/websocket/_reconnecting_websocket.ts +404 -0
- package/src/src/transports/websocket/_websocket_async_request.ts +229 -0
- package/src/src/transports/websocket/websocket_transport.ts +394 -0
- package/esm/src/base.d.ts.map +0 -1
- package/esm/src/signing/_sorter.d.ts +0 -127
- package/esm/src/signing/_sorter.d.ts.map +0 -1
- package/esm/src/signing/_sorter.js +0 -693
- package/esm/src/types/exchange/requests.d.ts +0 -1345
- package/esm/src/types/exchange/requests.d.ts.map +0 -1
- package/esm/src/types/exchange/requests.js +0 -1
- package/esm/src/types/exchange/responses.d.ts +0 -233
- package/esm/src/types/exchange/responses.d.ts.map +0 -1
- package/esm/src/types/exchange/responses.js +0 -1
- package/esm/src/types/explorer/requests.d.ts +0 -32
- package/esm/src/types/explorer/requests.d.ts.map +0 -1
- package/esm/src/types/explorer/requests.js +0 -1
- package/esm/src/types/explorer/responses.d.ts +0 -58
- package/esm/src/types/explorer/responses.d.ts.map +0 -1
- package/esm/src/types/explorer/responses.js +0 -1
- package/esm/src/types/info/accounts.d.ts +0 -864
- package/esm/src/types/info/accounts.d.ts.map +0 -1
- package/esm/src/types/info/accounts.js +0 -1
- package/esm/src/types/info/assets.d.ts +0 -354
- package/esm/src/types/info/assets.d.ts.map +0 -1
- package/esm/src/types/info/assets.js +0 -1
- package/esm/src/types/info/markets.d.ts +0 -79
- package/esm/src/types/info/markets.d.ts.map +0 -1
- package/esm/src/types/info/markets.js +0 -1
- package/esm/src/types/info/orders.d.ts +0 -266
- package/esm/src/types/info/orders.d.ts.map +0 -1
- package/esm/src/types/info/orders.js +0 -1
- package/esm/src/types/info/requests.d.ts +0 -640
- package/esm/src/types/info/requests.d.ts.map +0 -1
- package/esm/src/types/info/requests.js +0 -1
- package/esm/src/types/info/validators.d.ts +0 -147
- package/esm/src/types/info/validators.d.ts.map +0 -1
- package/esm/src/types/info/validators.js +0 -1
- package/esm/src/types/info/vaults.d.ts +0 -119
- package/esm/src/types/info/vaults.d.ts.map +0 -1
- package/esm/src/types/info/vaults.js +0 -1
- package/esm/src/types/mod.d.ts +0 -38
- package/esm/src/types/mod.d.ts.map +0 -1
- package/esm/src/types/mod.js +0 -24
- package/esm/src/types/subscriptions/requests.d.ts +0 -154
- package/esm/src/types/subscriptions/requests.d.ts.map +0 -1
- package/esm/src/types/subscriptions/requests.js +0 -1
- package/esm/src/types/subscriptions/responses.d.ts +0 -238
- package/esm/src/types/subscriptions/responses.d.ts.map +0 -1
- package/esm/src/types/subscriptions/responses.js +0 -1
- package/script/src/base.d.ts.map +0 -1
- package/script/src/signing/_sorter.d.ts +0 -127
- package/script/src/signing/_sorter.d.ts.map +0 -1
- package/script/src/signing/_sorter.js +0 -696
- package/script/src/types/exchange/requests.d.ts +0 -1345
- package/script/src/types/exchange/requests.d.ts.map +0 -1
- package/script/src/types/exchange/requests.js +0 -2
- package/script/src/types/exchange/responses.d.ts +0 -233
- package/script/src/types/exchange/responses.d.ts.map +0 -1
- package/script/src/types/exchange/responses.js +0 -2
- package/script/src/types/explorer/requests.d.ts +0 -32
- package/script/src/types/explorer/requests.d.ts.map +0 -1
- package/script/src/types/explorer/requests.js +0 -2
- package/script/src/types/explorer/responses.d.ts +0 -58
- package/script/src/types/explorer/responses.d.ts.map +0 -1
- package/script/src/types/explorer/responses.js +0 -2
- package/script/src/types/info/accounts.d.ts +0 -864
- package/script/src/types/info/accounts.d.ts.map +0 -1
- package/script/src/types/info/accounts.js +0 -2
- package/script/src/types/info/assets.d.ts +0 -354
- package/script/src/types/info/assets.d.ts.map +0 -1
- package/script/src/types/info/assets.js +0 -2
- package/script/src/types/info/markets.d.ts +0 -79
- package/script/src/types/info/markets.d.ts.map +0 -1
- package/script/src/types/info/markets.js +0 -2
- package/script/src/types/info/orders.d.ts +0 -266
- package/script/src/types/info/orders.d.ts.map +0 -1
- package/script/src/types/info/orders.js +0 -2
- package/script/src/types/info/requests.d.ts +0 -640
- package/script/src/types/info/requests.d.ts.map +0 -1
- package/script/src/types/info/requests.js +0 -2
- package/script/src/types/info/validators.d.ts +0 -147
- package/script/src/types/info/validators.d.ts.map +0 -1
- package/script/src/types/info/validators.js +0 -2
- package/script/src/types/info/vaults.d.ts +0 -119
- package/script/src/types/info/vaults.d.ts.map +0 -1
- package/script/src/types/info/vaults.js +0 -2
- package/script/src/types/mod.d.ts +0 -38
- package/script/src/types/mod.d.ts.map +0 -1
- package/script/src/types/mod.js +0 -25
- package/script/src/types/subscriptions/requests.d.ts +0 -154
- package/script/src/types/subscriptions/requests.d.ts.map +0 -1
- package/script/src/types/subscriptions/requests.js +0 -2
- package/script/src/types/subscriptions/responses.d.ts +0 -238
- package/script/src/types/subscriptions/responses.d.ts.map +0 -1
- package/script/src/types/subscriptions/responses.js +0 -2
|
@@ -0,0 +1,567 @@
|
|
|
1
|
+
import * as v from "valibot";
|
|
2
|
+
/** Response for order cancellation. */
|
|
3
|
+
export declare const CancelResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
4
|
+
/** Successful status. */
|
|
5
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
6
|
+
/** Response details. */
|
|
7
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
8
|
+
/** Type of response. */
|
|
9
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"cancel", undefined>, v.DescriptionAction<"cancel", "Type of response.">]>;
|
|
10
|
+
/** Specific data. */
|
|
11
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
12
|
+
/** Array of statuses or error messages. */
|
|
13
|
+
readonly statuses: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.LiteralSchema<"success", undefined>, v.ObjectSchema<{
|
|
14
|
+
/** Error message. */
|
|
15
|
+
readonly error: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.DescriptionAction<string, "Error message.">]>;
|
|
16
|
+
}, undefined>], undefined>, undefined>, v.DescriptionAction<("success" | {
|
|
17
|
+
error: string;
|
|
18
|
+
})[], "Array of statuses or error messages.">]>;
|
|
19
|
+
}, undefined>, v.DescriptionAction<{
|
|
20
|
+
statuses: ("success" | {
|
|
21
|
+
error: string;
|
|
22
|
+
})[];
|
|
23
|
+
}, "Specific data.">]>;
|
|
24
|
+
}, undefined>, v.DescriptionAction<{
|
|
25
|
+
type: "cancel";
|
|
26
|
+
data: {
|
|
27
|
+
statuses: ("success" | {
|
|
28
|
+
error: string;
|
|
29
|
+
})[];
|
|
30
|
+
};
|
|
31
|
+
}, "Response details.">]>;
|
|
32
|
+
}, undefined>, v.DescriptionAction<{
|
|
33
|
+
status: "ok";
|
|
34
|
+
response: {
|
|
35
|
+
type: "cancel";
|
|
36
|
+
data: {
|
|
37
|
+
statuses: ("success" | {
|
|
38
|
+
error: string;
|
|
39
|
+
})[];
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
}, "Response for order cancellation.">]>;
|
|
43
|
+
export type CancelResponse = v.InferOutput<typeof CancelResponse>;
|
|
44
|
+
/** Successful variant of {@linkcode CancelResponse} without errors. */
|
|
45
|
+
export declare const CancelSuccessResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
46
|
+
/** Successful status. */
|
|
47
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
48
|
+
/** Response details. */
|
|
49
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
50
|
+
/** Type of response. */
|
|
51
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"cancel", undefined>, v.DescriptionAction<"cancel", "Type of response.">]>;
|
|
52
|
+
/** Specific data. */
|
|
53
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
54
|
+
/** Array of success statuses. */
|
|
55
|
+
readonly statuses: v.SchemaWithPipe<readonly [v.ArraySchema<v.LiteralSchema<"success", undefined>, undefined>, v.DescriptionAction<"success"[], "Array of success statuses.">]>;
|
|
56
|
+
}, undefined>, v.DescriptionAction<{
|
|
57
|
+
statuses: "success"[];
|
|
58
|
+
}, "Specific data.">]>;
|
|
59
|
+
}, undefined>, v.DescriptionAction<{
|
|
60
|
+
type: "cancel";
|
|
61
|
+
data: {
|
|
62
|
+
statuses: "success"[];
|
|
63
|
+
};
|
|
64
|
+
}, "Response details.">]>;
|
|
65
|
+
}, undefined>, v.DescriptionAction<{
|
|
66
|
+
status: "ok";
|
|
67
|
+
response: {
|
|
68
|
+
type: "cancel";
|
|
69
|
+
data: {
|
|
70
|
+
statuses: "success"[];
|
|
71
|
+
};
|
|
72
|
+
};
|
|
73
|
+
}, "Successful variant of `CancelResponse` without errors.">]>;
|
|
74
|
+
export type CancelSuccessResponse = v.InferOutput<typeof CancelSuccessResponse>;
|
|
75
|
+
/** Response for creating a sub-account. */
|
|
76
|
+
export declare const CreateSubAccountResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
77
|
+
/** Successful status. */
|
|
78
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
79
|
+
/** Response details. */
|
|
80
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
81
|
+
/** Type of response. */
|
|
82
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"createSubAccount", undefined>, v.DescriptionAction<"createSubAccount", "Type of response.">]>;
|
|
83
|
+
/** Sub-account address. */
|
|
84
|
+
readonly data: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, `0x${string}`>]>, v.LengthAction<`0x${string}`, 42, undefined>]>, v.DescriptionAction<`0x${string}`, "Sub-account address.">]>;
|
|
85
|
+
}, undefined>, v.DescriptionAction<{
|
|
86
|
+
type: "createSubAccount";
|
|
87
|
+
data: `0x${string}`;
|
|
88
|
+
}, "Response details.">]>;
|
|
89
|
+
}, undefined>, v.DescriptionAction<{
|
|
90
|
+
status: "ok";
|
|
91
|
+
response: {
|
|
92
|
+
type: "createSubAccount";
|
|
93
|
+
data: `0x${string}`;
|
|
94
|
+
};
|
|
95
|
+
}, "Response for creating a sub-account.">]>;
|
|
96
|
+
export type CreateSubAccountResponse = v.InferOutput<typeof CreateSubAccountResponse>;
|
|
97
|
+
/** Response for creating a vault. */
|
|
98
|
+
export declare const CreateVaultResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
99
|
+
/** Successful status. */
|
|
100
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
101
|
+
/** Response details. */
|
|
102
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
103
|
+
/** Type of response. */
|
|
104
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"createVault", undefined>, v.DescriptionAction<"createVault", "Type of response.">]>;
|
|
105
|
+
/** Vault address. */
|
|
106
|
+
readonly data: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, `0x${string}`>]>, v.LengthAction<`0x${string}`, 42, undefined>]>, v.DescriptionAction<`0x${string}`, "Vault address.">]>;
|
|
107
|
+
}, undefined>, v.DescriptionAction<{
|
|
108
|
+
type: "createVault";
|
|
109
|
+
data: `0x${string}`;
|
|
110
|
+
}, "Response details.">]>;
|
|
111
|
+
}, undefined>, v.DescriptionAction<{
|
|
112
|
+
status: "ok";
|
|
113
|
+
response: {
|
|
114
|
+
type: "createVault";
|
|
115
|
+
data: `0x${string}`;
|
|
116
|
+
};
|
|
117
|
+
}, "Response for creating a vault.">]>;
|
|
118
|
+
export type CreateVaultResponse = v.InferOutput<typeof CreateVaultResponse>;
|
|
119
|
+
/** Error response for failed operations. */
|
|
120
|
+
export declare const ErrorResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
121
|
+
/** Error status. */
|
|
122
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"err", undefined>, v.DescriptionAction<"err", "Error status.">]>;
|
|
123
|
+
/** Error message. */
|
|
124
|
+
readonly response: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.DescriptionAction<string, "Error message.">]>;
|
|
125
|
+
}, undefined>, v.DescriptionAction<{
|
|
126
|
+
status: "err";
|
|
127
|
+
response: string;
|
|
128
|
+
}, "Error response for failed operations.">]>;
|
|
129
|
+
export type ErrorResponse = v.InferOutput<typeof ErrorResponse>;
|
|
130
|
+
/** Response for order placement and batch modifications. */
|
|
131
|
+
export declare const OrderResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
132
|
+
/** Successful status. */
|
|
133
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
134
|
+
/** Response details. */
|
|
135
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
136
|
+
/** Type of response. */
|
|
137
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"order", undefined>, v.DescriptionAction<"order", "Type of response.">]>;
|
|
138
|
+
/** Specific data. */
|
|
139
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
140
|
+
/** Array of statuses or error messages. */
|
|
141
|
+
readonly statuses: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.ObjectSchema<{
|
|
142
|
+
/** Resting order status. */
|
|
143
|
+
readonly resting: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
144
|
+
/** Order ID. */
|
|
145
|
+
readonly oid: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.SafeIntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, v.DescriptionAction<number, "Order ID.">]>;
|
|
146
|
+
/** Client Order ID. */
|
|
147
|
+
readonly cloid: v.SchemaWithPipe<readonly [v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, `0x${string}`>]>, v.LengthAction<`0x${string}`, 34, undefined>]>, undefined>, v.DescriptionAction<`0x${string}` | undefined, "Client Order ID.">]>;
|
|
148
|
+
}, undefined>, v.DescriptionAction<{
|
|
149
|
+
oid: number;
|
|
150
|
+
cloid?: `0x${string}` | undefined;
|
|
151
|
+
}, "Resting order status.">]>;
|
|
152
|
+
}, undefined>, v.ObjectSchema<{
|
|
153
|
+
/** Filled order status. */
|
|
154
|
+
readonly filled: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
155
|
+
/** Total size filled. */
|
|
156
|
+
readonly totalSz: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, string>]>, v.DescriptionAction<string, "Total size filled.">]>;
|
|
157
|
+
/** Average price of fill. */
|
|
158
|
+
readonly avgPx: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, string>]>, v.DescriptionAction<string, "Average price of fill.">]>;
|
|
159
|
+
/** Order ID. */
|
|
160
|
+
readonly oid: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.SafeIntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, v.DescriptionAction<number, "Order ID.">]>;
|
|
161
|
+
/** Client Order ID. */
|
|
162
|
+
readonly cloid: v.SchemaWithPipe<readonly [v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, `0x${string}`>]>, v.LengthAction<`0x${string}`, 34, undefined>]>, undefined>, v.DescriptionAction<`0x${string}` | undefined, "Client Order ID.">]>;
|
|
163
|
+
}, undefined>, v.DescriptionAction<{
|
|
164
|
+
totalSz: string;
|
|
165
|
+
avgPx: string;
|
|
166
|
+
oid: number;
|
|
167
|
+
cloid?: `0x${string}` | undefined;
|
|
168
|
+
}, "Filled order status.">]>;
|
|
169
|
+
}, undefined>, v.ObjectSchema<{
|
|
170
|
+
/** Error message. */
|
|
171
|
+
readonly error: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.DescriptionAction<string, "Error message.">]>;
|
|
172
|
+
}, undefined>], undefined>, undefined>, v.DescriptionAction<({
|
|
173
|
+
resting: {
|
|
174
|
+
oid: number;
|
|
175
|
+
cloid?: `0x${string}` | undefined;
|
|
176
|
+
};
|
|
177
|
+
} | {
|
|
178
|
+
filled: {
|
|
179
|
+
totalSz: string;
|
|
180
|
+
avgPx: string;
|
|
181
|
+
oid: number;
|
|
182
|
+
cloid?: `0x${string}` | undefined;
|
|
183
|
+
};
|
|
184
|
+
} | {
|
|
185
|
+
error: string;
|
|
186
|
+
})[], "Array of statuses or error messages.">]>;
|
|
187
|
+
}, undefined>, v.DescriptionAction<{
|
|
188
|
+
statuses: ({
|
|
189
|
+
resting: {
|
|
190
|
+
oid: number;
|
|
191
|
+
cloid?: `0x${string}` | undefined;
|
|
192
|
+
};
|
|
193
|
+
} | {
|
|
194
|
+
filled: {
|
|
195
|
+
totalSz: string;
|
|
196
|
+
avgPx: string;
|
|
197
|
+
oid: number;
|
|
198
|
+
cloid?: `0x${string}` | undefined;
|
|
199
|
+
};
|
|
200
|
+
} | {
|
|
201
|
+
error: string;
|
|
202
|
+
})[];
|
|
203
|
+
}, "Specific data.">]>;
|
|
204
|
+
}, undefined>, v.DescriptionAction<{
|
|
205
|
+
type: "order";
|
|
206
|
+
data: {
|
|
207
|
+
statuses: ({
|
|
208
|
+
resting: {
|
|
209
|
+
oid: number;
|
|
210
|
+
cloid?: `0x${string}` | undefined;
|
|
211
|
+
};
|
|
212
|
+
} | {
|
|
213
|
+
filled: {
|
|
214
|
+
totalSz: string;
|
|
215
|
+
avgPx: string;
|
|
216
|
+
oid: number;
|
|
217
|
+
cloid?: `0x${string}` | undefined;
|
|
218
|
+
};
|
|
219
|
+
} | {
|
|
220
|
+
error: string;
|
|
221
|
+
})[];
|
|
222
|
+
};
|
|
223
|
+
}, "Response details.">]>;
|
|
224
|
+
}, undefined>, v.DescriptionAction<{
|
|
225
|
+
status: "ok";
|
|
226
|
+
response: {
|
|
227
|
+
type: "order";
|
|
228
|
+
data: {
|
|
229
|
+
statuses: ({
|
|
230
|
+
resting: {
|
|
231
|
+
oid: number;
|
|
232
|
+
cloid?: `0x${string}` | undefined;
|
|
233
|
+
};
|
|
234
|
+
} | {
|
|
235
|
+
filled: {
|
|
236
|
+
totalSz: string;
|
|
237
|
+
avgPx: string;
|
|
238
|
+
oid: number;
|
|
239
|
+
cloid?: `0x${string}` | undefined;
|
|
240
|
+
};
|
|
241
|
+
} | {
|
|
242
|
+
error: string;
|
|
243
|
+
})[];
|
|
244
|
+
};
|
|
245
|
+
};
|
|
246
|
+
}, "Response for order placement and batch modifications.">]>;
|
|
247
|
+
export type OrderResponse = v.InferOutput<typeof OrderResponse>;
|
|
248
|
+
/** Successful variant of {@linkcode OrderResponse} without errors. */
|
|
249
|
+
export declare const OrderSuccessResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
250
|
+
/** Successful status. */
|
|
251
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
252
|
+
/** Response details. */
|
|
253
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
254
|
+
/** Type of response. */
|
|
255
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"order", undefined>, v.DescriptionAction<"order", "Type of response.">]>;
|
|
256
|
+
/** Specific data. */
|
|
257
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
258
|
+
/** Array of successful order statuses. */
|
|
259
|
+
readonly statuses: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.ObjectSchema<{
|
|
260
|
+
/** Resting order status. */
|
|
261
|
+
readonly resting: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
262
|
+
/** Order ID. */
|
|
263
|
+
readonly oid: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.SafeIntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, v.DescriptionAction<number, "Order ID.">]>;
|
|
264
|
+
/** Client Order ID. */
|
|
265
|
+
readonly cloid: v.SchemaWithPipe<readonly [v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, `0x${string}`>]>, v.LengthAction<`0x${string}`, 34, undefined>]>, undefined>, v.DescriptionAction<`0x${string}` | undefined, "Client Order ID.">]>;
|
|
266
|
+
}, undefined>, v.DescriptionAction<{
|
|
267
|
+
oid: number;
|
|
268
|
+
cloid?: `0x${string}` | undefined;
|
|
269
|
+
}, "Resting order status.">]>;
|
|
270
|
+
}, undefined>, v.ObjectSchema<{
|
|
271
|
+
/** Filled order status. */
|
|
272
|
+
readonly filled: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
273
|
+
/** Total size filled. */
|
|
274
|
+
readonly totalSz: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, string>]>, v.DescriptionAction<string, "Total size filled.">]>;
|
|
275
|
+
/** Average price of fill. */
|
|
276
|
+
readonly avgPx: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, string>]>, v.DescriptionAction<string, "Average price of fill.">]>;
|
|
277
|
+
/** Order ID. */
|
|
278
|
+
readonly oid: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.SafeIntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, v.DescriptionAction<number, "Order ID.">]>;
|
|
279
|
+
/** Client Order ID. */
|
|
280
|
+
readonly cloid: v.SchemaWithPipe<readonly [v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.TransformAction<string, `0x${string}`>]>, v.LengthAction<`0x${string}`, 34, undefined>]>, undefined>, v.DescriptionAction<`0x${string}` | undefined, "Client Order ID.">]>;
|
|
281
|
+
}, undefined>, v.DescriptionAction<{
|
|
282
|
+
totalSz: string;
|
|
283
|
+
avgPx: string;
|
|
284
|
+
oid: number;
|
|
285
|
+
cloid?: `0x${string}` | undefined;
|
|
286
|
+
}, "Filled order status.">]>;
|
|
287
|
+
}, undefined>], undefined>, undefined>, v.DescriptionAction<({
|
|
288
|
+
resting: {
|
|
289
|
+
oid: number;
|
|
290
|
+
cloid?: `0x${string}` | undefined;
|
|
291
|
+
};
|
|
292
|
+
} | {
|
|
293
|
+
filled: {
|
|
294
|
+
totalSz: string;
|
|
295
|
+
avgPx: string;
|
|
296
|
+
oid: number;
|
|
297
|
+
cloid?: `0x${string}` | undefined;
|
|
298
|
+
};
|
|
299
|
+
})[], "Array of successful order statuses.">]>;
|
|
300
|
+
}, undefined>, v.DescriptionAction<{
|
|
301
|
+
statuses: ({
|
|
302
|
+
resting: {
|
|
303
|
+
oid: number;
|
|
304
|
+
cloid?: `0x${string}` | undefined;
|
|
305
|
+
};
|
|
306
|
+
} | {
|
|
307
|
+
filled: {
|
|
308
|
+
totalSz: string;
|
|
309
|
+
avgPx: string;
|
|
310
|
+
oid: number;
|
|
311
|
+
cloid?: `0x${string}` | undefined;
|
|
312
|
+
};
|
|
313
|
+
})[];
|
|
314
|
+
}, "Specific data.">]>;
|
|
315
|
+
}, undefined>, v.DescriptionAction<{
|
|
316
|
+
type: "order";
|
|
317
|
+
data: {
|
|
318
|
+
statuses: ({
|
|
319
|
+
resting: {
|
|
320
|
+
oid: number;
|
|
321
|
+
cloid?: `0x${string}` | undefined;
|
|
322
|
+
};
|
|
323
|
+
} | {
|
|
324
|
+
filled: {
|
|
325
|
+
totalSz: string;
|
|
326
|
+
avgPx: string;
|
|
327
|
+
oid: number;
|
|
328
|
+
cloid?: `0x${string}` | undefined;
|
|
329
|
+
};
|
|
330
|
+
})[];
|
|
331
|
+
};
|
|
332
|
+
}, "Response details.">]>;
|
|
333
|
+
}, undefined>, v.DescriptionAction<{
|
|
334
|
+
status: "ok";
|
|
335
|
+
response: {
|
|
336
|
+
type: "order";
|
|
337
|
+
data: {
|
|
338
|
+
statuses: ({
|
|
339
|
+
resting: {
|
|
340
|
+
oid: number;
|
|
341
|
+
cloid?: `0x${string}` | undefined;
|
|
342
|
+
};
|
|
343
|
+
} | {
|
|
344
|
+
filled: {
|
|
345
|
+
totalSz: string;
|
|
346
|
+
avgPx: string;
|
|
347
|
+
oid: number;
|
|
348
|
+
cloid?: `0x${string}` | undefined;
|
|
349
|
+
};
|
|
350
|
+
})[];
|
|
351
|
+
};
|
|
352
|
+
};
|
|
353
|
+
}, "Successful variant of `OrderResponse` without errors.">]>;
|
|
354
|
+
export type OrderSuccessResponse = v.InferOutput<typeof OrderSuccessResponse>;
|
|
355
|
+
/** Successful response without specific data. */
|
|
356
|
+
export declare const SuccessResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
357
|
+
/** Successful status. */
|
|
358
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
359
|
+
/** Response details. */
|
|
360
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
361
|
+
/** Type of response. */
|
|
362
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"default", undefined>, v.DescriptionAction<"default", "Type of response.">]>;
|
|
363
|
+
}, undefined>, v.DescriptionAction<{
|
|
364
|
+
type: "default";
|
|
365
|
+
}, "Response details.">]>;
|
|
366
|
+
}, undefined>, v.DescriptionAction<{
|
|
367
|
+
status: "ok";
|
|
368
|
+
response: {
|
|
369
|
+
type: "default";
|
|
370
|
+
};
|
|
371
|
+
}, "Successful response without specific data.">]>;
|
|
372
|
+
export type SuccessResponse = v.InferOutput<typeof SuccessResponse>;
|
|
373
|
+
/** Response for canceling a TWAP order. */
|
|
374
|
+
export declare const TwapCancelResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
375
|
+
/** Successful status. */
|
|
376
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
377
|
+
/** Response details. */
|
|
378
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
379
|
+
/** Type of response. */
|
|
380
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"twapCancel", undefined>, v.DescriptionAction<"twapCancel", "Type of response.">]>;
|
|
381
|
+
/** Specific data. */
|
|
382
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
383
|
+
/** Status of the operation or error message. */
|
|
384
|
+
readonly status: v.SchemaWithPipe<readonly [v.UnionSchema<[v.StringSchema<undefined>, v.ObjectSchema<{
|
|
385
|
+
/** Error message. */
|
|
386
|
+
readonly error: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.DescriptionAction<string, "Error message.">]>;
|
|
387
|
+
}, undefined>], undefined>, v.DescriptionAction<string | {
|
|
388
|
+
error: string;
|
|
389
|
+
}, "Status of the operation or error message.">]>;
|
|
390
|
+
}, undefined>, v.DescriptionAction<{
|
|
391
|
+
status: string | {
|
|
392
|
+
error: string;
|
|
393
|
+
};
|
|
394
|
+
}, "Specific data.">]>;
|
|
395
|
+
}, undefined>, v.DescriptionAction<{
|
|
396
|
+
type: "twapCancel";
|
|
397
|
+
data: {
|
|
398
|
+
status: string | {
|
|
399
|
+
error: string;
|
|
400
|
+
};
|
|
401
|
+
};
|
|
402
|
+
}, "Response details.">]>;
|
|
403
|
+
}, undefined>, v.DescriptionAction<{
|
|
404
|
+
status: "ok";
|
|
405
|
+
response: {
|
|
406
|
+
type: "twapCancel";
|
|
407
|
+
data: {
|
|
408
|
+
status: string | {
|
|
409
|
+
error: string;
|
|
410
|
+
};
|
|
411
|
+
};
|
|
412
|
+
};
|
|
413
|
+
}, "Response for canceling a TWAP order.">]>;
|
|
414
|
+
export type TwapCancelResponse = v.InferOutput<typeof TwapCancelResponse>;
|
|
415
|
+
/** Successful variant of {@linkcode TwapCancelResponse} without errors. */
|
|
416
|
+
export declare const TwapCancelSuccessResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
417
|
+
/** Successful status. */
|
|
418
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
419
|
+
/** Response details. */
|
|
420
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
421
|
+
/** Type of response. */
|
|
422
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"twapCancel", undefined>, v.DescriptionAction<"twapCancel", "Type of response.">]>;
|
|
423
|
+
/** Specific data. */
|
|
424
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
425
|
+
/** Status of the operation. */
|
|
426
|
+
readonly status: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.DescriptionAction<string, "Status of the operation.">]>;
|
|
427
|
+
}, undefined>, v.DescriptionAction<{
|
|
428
|
+
status: string;
|
|
429
|
+
}, "Specific data.">]>;
|
|
430
|
+
}, undefined>, v.DescriptionAction<{
|
|
431
|
+
type: "twapCancel";
|
|
432
|
+
data: {
|
|
433
|
+
status: string;
|
|
434
|
+
};
|
|
435
|
+
}, "Response details.">]>;
|
|
436
|
+
}, undefined>, v.DescriptionAction<{
|
|
437
|
+
status: "ok";
|
|
438
|
+
response: {
|
|
439
|
+
type: "twapCancel";
|
|
440
|
+
data: {
|
|
441
|
+
status: string;
|
|
442
|
+
};
|
|
443
|
+
};
|
|
444
|
+
}, "Successful variant of `TwapCancelResponse` without errors.">]>;
|
|
445
|
+
export type TwapCancelSuccessResponse = v.InferOutput<typeof TwapCancelSuccessResponse>;
|
|
446
|
+
/** Response for creating a TWAP order. */
|
|
447
|
+
export declare const TwapOrderResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
448
|
+
/** Successful status. */
|
|
449
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
450
|
+
/** Response details. */
|
|
451
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
452
|
+
/** Type of response. */
|
|
453
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"twapOrder", undefined>, v.DescriptionAction<"twapOrder", "Type of response.">]>;
|
|
454
|
+
/** Specific data. */
|
|
455
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
456
|
+
/** Status of the operation or error message. */
|
|
457
|
+
readonly status: v.SchemaWithPipe<readonly [v.UnionSchema<[v.ObjectSchema<{
|
|
458
|
+
/** Running order status. */
|
|
459
|
+
readonly running: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
460
|
+
/** TWAP ID. */
|
|
461
|
+
readonly twapId: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.SafeIntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, v.DescriptionAction<number, "TWAP ID.">]>;
|
|
462
|
+
}, undefined>, v.DescriptionAction<{
|
|
463
|
+
twapId: number;
|
|
464
|
+
}, "Running order status.">]>;
|
|
465
|
+
}, undefined>, v.ObjectSchema<{
|
|
466
|
+
/** Error message. */
|
|
467
|
+
readonly error: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.DescriptionAction<string, "Error message.">]>;
|
|
468
|
+
}, undefined>], undefined>, v.DescriptionAction<{
|
|
469
|
+
running: {
|
|
470
|
+
twapId: number;
|
|
471
|
+
};
|
|
472
|
+
} | {
|
|
473
|
+
error: string;
|
|
474
|
+
}, "Status of the operation or error message.">]>;
|
|
475
|
+
}, undefined>, v.DescriptionAction<{
|
|
476
|
+
status: {
|
|
477
|
+
running: {
|
|
478
|
+
twapId: number;
|
|
479
|
+
};
|
|
480
|
+
} | {
|
|
481
|
+
error: string;
|
|
482
|
+
};
|
|
483
|
+
}, "Specific data.">]>;
|
|
484
|
+
}, undefined>, v.DescriptionAction<{
|
|
485
|
+
type: "twapOrder";
|
|
486
|
+
data: {
|
|
487
|
+
status: {
|
|
488
|
+
running: {
|
|
489
|
+
twapId: number;
|
|
490
|
+
};
|
|
491
|
+
} | {
|
|
492
|
+
error: string;
|
|
493
|
+
};
|
|
494
|
+
};
|
|
495
|
+
}, "Response details.">]>;
|
|
496
|
+
}, undefined>, v.DescriptionAction<{
|
|
497
|
+
status: "ok";
|
|
498
|
+
response: {
|
|
499
|
+
type: "twapOrder";
|
|
500
|
+
data: {
|
|
501
|
+
status: {
|
|
502
|
+
running: {
|
|
503
|
+
twapId: number;
|
|
504
|
+
};
|
|
505
|
+
} | {
|
|
506
|
+
error: string;
|
|
507
|
+
};
|
|
508
|
+
};
|
|
509
|
+
};
|
|
510
|
+
}, "Response for creating a TWAP order.">]>;
|
|
511
|
+
export type TwapOrderResponse = v.InferOutput<typeof TwapOrderResponse>;
|
|
512
|
+
/** Successful variant of {@linkcode TwapOrderResponse} without errors. */
|
|
513
|
+
export declare const TwapOrderSuccessResponse: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
514
|
+
/** Successful status. */
|
|
515
|
+
readonly status: v.SchemaWithPipe<readonly [v.LiteralSchema<"ok", undefined>, v.DescriptionAction<"ok", "Successful status.">]>;
|
|
516
|
+
/** Response details. */
|
|
517
|
+
readonly response: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
518
|
+
/** Type of response. */
|
|
519
|
+
readonly type: v.SchemaWithPipe<readonly [v.LiteralSchema<"twapOrder", undefined>, v.DescriptionAction<"twapOrder", "Type of response.">]>;
|
|
520
|
+
/** Specific data. */
|
|
521
|
+
readonly data: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
522
|
+
/** Status of the operation. */
|
|
523
|
+
readonly status: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
524
|
+
/** Running order status. */
|
|
525
|
+
readonly running: v.SchemaWithPipe<readonly [v.ObjectSchema<{
|
|
526
|
+
/** TWAP ID. */
|
|
527
|
+
readonly twapId: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.SafeIntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, v.DescriptionAction<number, "TWAP ID.">]>;
|
|
528
|
+
}, undefined>, v.DescriptionAction<{
|
|
529
|
+
twapId: number;
|
|
530
|
+
}, "Running order status.">]>;
|
|
531
|
+
}, undefined>, v.DescriptionAction<{
|
|
532
|
+
running: {
|
|
533
|
+
twapId: number;
|
|
534
|
+
};
|
|
535
|
+
}, "Status of the operation.">]>;
|
|
536
|
+
}, undefined>, v.DescriptionAction<{
|
|
537
|
+
status: {
|
|
538
|
+
running: {
|
|
539
|
+
twapId: number;
|
|
540
|
+
};
|
|
541
|
+
};
|
|
542
|
+
}, "Specific data.">]>;
|
|
543
|
+
}, undefined>, v.DescriptionAction<{
|
|
544
|
+
type: "twapOrder";
|
|
545
|
+
data: {
|
|
546
|
+
status: {
|
|
547
|
+
running: {
|
|
548
|
+
twapId: number;
|
|
549
|
+
};
|
|
550
|
+
};
|
|
551
|
+
};
|
|
552
|
+
}, "Response details.">]>;
|
|
553
|
+
}, undefined>, v.DescriptionAction<{
|
|
554
|
+
status: "ok";
|
|
555
|
+
response: {
|
|
556
|
+
type: "twapOrder";
|
|
557
|
+
data: {
|
|
558
|
+
status: {
|
|
559
|
+
running: {
|
|
560
|
+
twapId: number;
|
|
561
|
+
};
|
|
562
|
+
};
|
|
563
|
+
};
|
|
564
|
+
};
|
|
565
|
+
}, "Successful variant of `TwapOrderResponse` without errors.">]>;
|
|
566
|
+
export type TwapOrderSuccessResponse = v.InferOutput<typeof TwapOrderSuccessResponse>;
|
|
567
|
+
//# sourceMappingURL=responses.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"responses.d.ts","sourceRoot":"","sources":["../../../../src/src/schemas/exchange/responses.ts"],"names":[],"mappings":"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"}
|