@0xmonaco/types 1.0.55 → 1.0.56
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/dist/profile/index.d.ts +13 -0
- package/dist/sweeper/index.d.ts +58 -4
- package/dist/websocket/base.d.ts +7 -1
- package/dist/websocket/events/balance-events.d.ts +23 -8
- package/dist/wire/operations.d.ts +1 -1
- package/dist/wire/operations.js +1 -0
- package/dist/wire/schema.d.ts +162 -15
- package/package.json +2 -2
package/dist/profile/index.d.ts
CHANGED
|
@@ -199,6 +199,19 @@ export interface AccountBalance {
|
|
|
199
199
|
lockedBalanceRaw: string;
|
|
200
200
|
/** Total balance (available + locked) in raw format (wei) */
|
|
201
201
|
totalBalanceRaw: string;
|
|
202
|
+
/**
|
|
203
|
+
* Opaque, non-negative producer-owned version for this spot balance row.
|
|
204
|
+
* Compare only within the same account/application/token; higher is newer.
|
|
205
|
+
*
|
|
206
|
+
* OPTIONAL, and absent is not an error: a server that predates this field
|
|
207
|
+
* sends no key at all, which is what a rolling deploy looks like from a
|
|
208
|
+
* client. Absent and 0 mean the same thing — unranked — and never
|
|
209
|
+
* participate in ordering. Normalize before comparing: `undefined <= 710` is
|
|
210
|
+
* false, so an un-normalized guard silently passes and a stale row wins.
|
|
211
|
+
* Fall back to a full field comparison rather than ranking an unranked row
|
|
212
|
+
* as oldest.
|
|
213
|
+
*/
|
|
214
|
+
version?: number;
|
|
202
215
|
/**
|
|
203
216
|
* True when this asset is the chain's wrapped-native token (e.g. WSEI):
|
|
204
217
|
* vault deposits can be made in native coin via depositNative (the vault
|
package/dist/sweeper/index.d.ts
CHANGED
|
@@ -22,8 +22,10 @@ export type RegisterSweeperStatus = "registered" | "already_registered";
|
|
|
22
22
|
* Body for a deposit-address registration.
|
|
23
23
|
*
|
|
24
24
|
* Deliberately tiny: the application and the credited address both come from
|
|
25
|
-
* the authenticated session (`login` takes the application's client id),
|
|
26
|
-
*
|
|
25
|
+
* the authenticated session (`login` takes the application's client id), and
|
|
26
|
+
* one registration is watched on every supported chain ({@link
|
|
27
|
+
* SweeperAPI.getChains} lists them), so the only thing left to say is which
|
|
28
|
+
* ledger to aim at.
|
|
27
29
|
*/
|
|
28
30
|
export interface RegisterSweeperRequest {
|
|
29
31
|
/**
|
|
@@ -63,8 +65,48 @@ export interface RegisterSweeperResponse {
|
|
|
63
65
|
*/
|
|
64
66
|
initialSweepCheck: boolean;
|
|
65
67
|
}
|
|
68
|
+
/** One asset the sweeper watches on a chain. */
|
|
69
|
+
export interface SweeperChainAsset {
|
|
70
|
+
/** The asset's symbol on this chain, e.g. `"USDC"` */
|
|
71
|
+
symbol: string;
|
|
72
|
+
/** The ERC20 contract address to send on this chain */
|
|
73
|
+
tokenAddress: string;
|
|
74
|
+
/** The token's decimals on this chain; `0` when not published */
|
|
75
|
+
decimals: number;
|
|
76
|
+
/**
|
|
77
|
+
* Minimum sweepable balance in raw base units (a decimal string — raw
|
|
78
|
+
* amounts can exceed `Number.MAX_SAFE_INTEGER`). Smaller balances are left
|
|
79
|
+
* on the deposit address until a later deposit lifts the total past it.
|
|
80
|
+
*/
|
|
81
|
+
minSweepRaw: string;
|
|
82
|
+
}
|
|
83
|
+
/** One chain the sweeper watches. */
|
|
84
|
+
export interface SweeperChain {
|
|
85
|
+
/**
|
|
86
|
+
* The chain's EVM chain id. Always at most `2^53 - 1`
|
|
87
|
+
* (`Number.MAX_SAFE_INTEGER`) — the service refuses larger ids — so the
|
|
88
|
+
* number is exact. Every registered deposit address is watched on every
|
|
89
|
+
* listed chain — the address is identical on all of them.
|
|
90
|
+
*/
|
|
91
|
+
chainId: number;
|
|
92
|
+
/** Short human-readable chain name, e.g. `"sei"` */
|
|
93
|
+
name: string;
|
|
94
|
+
/**
|
|
95
|
+
* Whether this is the settlement (hub) chain deposits are forwarded into.
|
|
96
|
+
* Deposits on every other listed chain are bridged there automatically.
|
|
97
|
+
*/
|
|
98
|
+
hub: boolean;
|
|
99
|
+
/** The assets swept on this chain */
|
|
100
|
+
assets: SweeperChainAsset[];
|
|
101
|
+
}
|
|
102
|
+
/** The chains and assets the sweeper watches. */
|
|
103
|
+
export interface GetSweeperChainsResponse {
|
|
104
|
+
/** One entry per supported chain */
|
|
105
|
+
chains: SweeperChain[];
|
|
106
|
+
}
|
|
66
107
|
/**
|
|
67
|
-
* Sweeper API interface. The register endpoint requires authentication
|
|
108
|
+
* Sweeper API interface. The register endpoint requires authentication;
|
|
109
|
+
* the chain listing is public.
|
|
68
110
|
*/
|
|
69
111
|
export interface SweeperAPI extends BaseAPI {
|
|
70
112
|
/**
|
|
@@ -74,7 +116,10 @@ export interface SweeperAPI extends BaseAPI {
|
|
|
74
116
|
*
|
|
75
117
|
* The application and the credited address both come from the authenticated
|
|
76
118
|
* session, so this only ever registers the caller's own address under their
|
|
77
|
-
* own application.
|
|
119
|
+
* own application. The deposit address is identical on every supported
|
|
120
|
+
* chain and ONE registration is watched on all of them (see
|
|
121
|
+
* {@link getChains} for the set) — call it with no arguments for a spot
|
|
122
|
+
* address.
|
|
78
123
|
*
|
|
79
124
|
* Returns immediately with the derived deposit address; the one-time
|
|
80
125
|
* initial balance check runs in the background. Idempotent and safe to
|
|
@@ -86,4 +131,13 @@ export interface SweeperAPI extends BaseAPI {
|
|
|
86
131
|
* global admission limit is exceeded (429).
|
|
87
132
|
*/
|
|
88
133
|
register(body?: RegisterSweeperRequest): Promise<RegisterSweeperResponse>;
|
|
134
|
+
/**
|
|
135
|
+
* The chains and assets the sweeper watches — where a registered deposit
|
|
136
|
+
* address accepts deposits, which tokens are swept on each chain, and each
|
|
137
|
+
* token's minimum sweep amount.
|
|
138
|
+
*
|
|
139
|
+
* Public: a depositor needs this before they have any session. The set
|
|
140
|
+
* changes only with operator configuration, so it is safe to cache briefly.
|
|
141
|
+
*/
|
|
142
|
+
getChains(): Promise<GetSweeperChainsResponse>;
|
|
89
143
|
}
|
package/dist/websocket/base.d.ts
CHANGED
|
@@ -62,7 +62,13 @@ export type WebSocketErrorCode =
|
|
|
62
62
|
* active and live diffs flow, but the baseline is missing — refetch it (e.g.
|
|
63
63
|
* from REST) rather than assuming the stream started from a coherent state.
|
|
64
64
|
*/
|
|
65
|
-
| "SNAPSHOT_UNAVAILABLE"
|
|
65
|
+
| "SNAPSHOT_UNAVAILABLE"
|
|
66
|
+
/**
|
|
67
|
+
* The per-connection inbound message-rate cap was exceeded; the connection
|
|
68
|
+
* is closed (1008) after this frame. Batch subscriptions and back off
|
|
69
|
+
* before reconnecting — a hot re-subscribe loop trips the cap again.
|
|
70
|
+
*/
|
|
71
|
+
| "MESSAGE_RATE_LIMIT";
|
|
66
72
|
/**
|
|
67
73
|
* An `Error` frame the server sent on this connection.
|
|
68
74
|
*
|
|
@@ -16,12 +16,16 @@ import type { Address } from "viem";
|
|
|
16
16
|
* path: `liquidation` on the liquidated victim's collateral, `adl` on an
|
|
17
17
|
* account impacted by auto-deleveraging.
|
|
18
18
|
*
|
|
19
|
-
* A
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
19
|
+
* A genuine spot frame carries the resulting `user_balances` row and its
|
|
20
|
+
* producer-owned `version`, scoped to the authenticated user/application and
|
|
21
|
+
* token. Higher is newer; equal is idempotent. A collateral transfer that
|
|
22
|
+
* moves the spot wallet row emits a genuine versioned spot frame for that leg.
|
|
23
|
+
* Margin collateral frames — a parent to risk-bucket allocation, which moves
|
|
24
|
+
* no wallet balance — and margin-routed deposit notifications omit `version`:
|
|
25
|
+
* they are not spot rows, and a deposit notification can carry a delta rather
|
|
26
|
+
* than whole-row state.
|
|
27
|
+
* They cannot be reconciled against a spot snapshot or summed as separate
|
|
28
|
+
* credits; refresh authoritative margin-account state instead.
|
|
25
29
|
*/
|
|
26
30
|
export type BalanceUpdateReason = "lock" | "unlock" | "deposit" | "margin_deposit" | "withdrawal" | "trade" | "fee" | "rebate" | "funding" | "liquidation" | "adl" | "margin_transfer_in" | "margin_transfer_out";
|
|
27
31
|
/**
|
|
@@ -40,15 +44,26 @@ export interface UserBalanceEventData {
|
|
|
40
44
|
locked: string;
|
|
41
45
|
/** Locked balance in raw format (wei) */
|
|
42
46
|
lockedRaw: string;
|
|
43
|
-
/** Total balance
|
|
47
|
+
/** Total balance represented by this frame, normalized */
|
|
44
48
|
total: string;
|
|
45
49
|
/** Total balance in raw format (wei) */
|
|
46
50
|
totalRaw: string;
|
|
51
|
+
/**
|
|
52
|
+
* Opaque durable spot-row version. Present only for genuine `user_balances`
|
|
53
|
+
* state; absent on legacy frames and margin collateral notifications.
|
|
54
|
+
*
|
|
55
|
+
* Only a POSITIVE version is rankable. `0` is the legacy sentinel and means
|
|
56
|
+
* exactly what an absent field means — unranked — so normalize the two
|
|
57
|
+
* together. A subscribe-time snapshot can carry a persisted `0`, and ranking
|
|
58
|
+
* it as the oldest revision would suppress the unranked frames a rolling
|
|
59
|
+
* deploy produces.
|
|
60
|
+
*/
|
|
61
|
+
version?: number;
|
|
47
62
|
/** Reason for the balance update */
|
|
48
63
|
reason: BalanceUpdateReason | (string & {});
|
|
49
64
|
/** Reference ID for related entity (e.g., order ID, deposit ID) */
|
|
50
65
|
referenceId: string | null;
|
|
51
|
-
/**
|
|
66
|
+
/** Display/source timestamp only; never use it to order balance state. */
|
|
52
67
|
updatedAt: string;
|
|
53
68
|
}
|
|
54
69
|
/**
|
|
@@ -10,6 +10,6 @@
|
|
|
10
10
|
* hand-written SDK surface. CI regenerates it and fails on a diff, identical to
|
|
11
11
|
* the `schema.ts` wire-types tripwire (MON-1476), so it can never go stale.
|
|
12
12
|
*/
|
|
13
|
-
export declare const OPERATION_IDS: readonly ["attach_position_tp_sl", "batch_cancel_all", "batch_cancel_all_by_pair", "batch_cancel_orders", "batch_close_all_positions", "batch_create_orders", "batch_replace_orders", "cancel_conditional_order", "cancel_order", "cancel_twap_order", "check_trader_code_availability", "clear_trader_code", "close_position", "create_challenge", "create_delegated_session", "create_order", "create_sub_account_limit", "create_twap_order", "delete_sub_account_limit", "get_application_config", "get_application_stats", "get_available_collateral", "get_candles", "get_conditional_order", "get_faucet_info", "get_funding_state", "get_index_price", "get_margin_account_movements", "get_margin_account_summary", "get_mark_price", "get_market_metadata", "get_market_stats", "get_my_fee_tier", "get_my_trader_code", "get_open_interest", "get_order_by_id", "get_orderbook_snapshot", "get_orders", "get_parent_margin_account_movements", "get_parent_margin_account_summary", "get_perp_market_config", "get_perp_market_summary", "get_portfolio_assets", "get_portfolio_chart", "get_portfolio_margin", "get_portfolio_performance", "get_portfolio_realized_pnl", "get_portfolio_stats", "get_portfolio_summary", "get_position", "get_position_pnl_history", "get_position_risk", "get_pulse", "get_rewards_balance", "get_screener", "get_sub_account_limits", "get_trade_by_id", "get_trader_code_info", "get_trades", "get_trading_pair_by_id", "get_twap_order", "get_twap_order_tca", "get_user_balance_by_asset", "get_user_balances", "get_user_movements", "get_user_profile", "get_user_trades", "get_withdrawal", "health_check", "initiate_withdrawal", "list_all_funding_history", "list_application_balances", "list_application_movements", "list_application_orders", "list_application_users", "list_conditional_orders", "list_delegated_agent_owners", "list_delegated_agents", "list_funding_history", "list_funding_payments", "list_margin_accounts", "list_pending_withdrawals", "list_position_history", "list_positions", "list_sub_accounts_with_balances", "list_trading_pairs", "list_twap_orders", "mint_tokens", "refresh_session", "register_deposit_address", "replace_order", "revoke_delegated_agent", "revoke_session", "set_trader_code", "simulate_fees", "simulate_order_risk", "simulate_parent_margin_order_risk", "simulate_risk_bucket_order_risk", "submit_whitelist", "transfer_collateral_from_margin_account", "transfer_collateral_from_parent_margin_account", "transfer_collateral_to_margin_account", "transfer_collateral_to_parent_margin_account", "transfer_collateral_to_risk_bucket", "transfer_rewards", "update_sub_account_limit", "upsert_delegated_agent", "verify_signature"];
|
|
13
|
+
export declare const OPERATION_IDS: readonly ["attach_position_tp_sl", "batch_cancel_all", "batch_cancel_all_by_pair", "batch_cancel_orders", "batch_close_all_positions", "batch_create_orders", "batch_replace_orders", "cancel_conditional_order", "cancel_order", "cancel_twap_order", "check_trader_code_availability", "clear_trader_code", "close_position", "create_challenge", "create_delegated_session", "create_order", "create_sub_account_limit", "create_twap_order", "delete_sub_account_limit", "get_application_config", "get_application_stats", "get_available_collateral", "get_candles", "get_conditional_order", "get_faucet_info", "get_funding_state", "get_index_price", "get_margin_account_movements", "get_margin_account_summary", "get_mark_price", "get_market_metadata", "get_market_stats", "get_my_fee_tier", "get_my_trader_code", "get_open_interest", "get_order_by_id", "get_orderbook_snapshot", "get_orders", "get_parent_margin_account_movements", "get_parent_margin_account_summary", "get_perp_market_config", "get_perp_market_summary", "get_portfolio_assets", "get_portfolio_chart", "get_portfolio_margin", "get_portfolio_performance", "get_portfolio_realized_pnl", "get_portfolio_stats", "get_portfolio_summary", "get_position", "get_position_pnl_history", "get_position_risk", "get_pulse", "get_rewards_balance", "get_screener", "get_sub_account_limits", "get_sweeper_chains", "get_trade_by_id", "get_trader_code_info", "get_trades", "get_trading_pair_by_id", "get_twap_order", "get_twap_order_tca", "get_user_balance_by_asset", "get_user_balances", "get_user_movements", "get_user_profile", "get_user_trades", "get_withdrawal", "health_check", "initiate_withdrawal", "list_all_funding_history", "list_application_balances", "list_application_movements", "list_application_orders", "list_application_users", "list_conditional_orders", "list_delegated_agent_owners", "list_delegated_agents", "list_funding_history", "list_funding_payments", "list_margin_accounts", "list_pending_withdrawals", "list_position_history", "list_positions", "list_sub_accounts_with_balances", "list_trading_pairs", "list_twap_orders", "mint_tokens", "refresh_session", "register_deposit_address", "replace_order", "revoke_delegated_agent", "revoke_session", "set_trader_code", "simulate_fees", "simulate_order_risk", "simulate_parent_margin_order_risk", "simulate_risk_bucket_order_risk", "submit_whitelist", "transfer_collateral_from_margin_account", "transfer_collateral_from_parent_margin_account", "transfer_collateral_to_margin_account", "transfer_collateral_to_parent_margin_account", "transfer_collateral_to_risk_bucket", "transfer_rewards", "update_sub_account_limit", "upsert_delegated_agent", "verify_signature"];
|
|
14
14
|
/** Union of every OpenAPI operationId in the spec. */
|
|
15
15
|
export type OperationId = (typeof OPERATION_IDS)[number];
|
package/dist/wire/operations.js
CHANGED
package/dist/wire/schema.d.ts
CHANGED
|
@@ -2079,6 +2079,36 @@ export interface paths {
|
|
|
2079
2079
|
patch?: never;
|
|
2080
2080
|
trace?: never;
|
|
2081
2081
|
};
|
|
2082
|
+
"/api/v1/sweeper/chains": {
|
|
2083
|
+
parameters: {
|
|
2084
|
+
query?: never;
|
|
2085
|
+
header?: never;
|
|
2086
|
+
path?: never;
|
|
2087
|
+
cookie?: never;
|
|
2088
|
+
};
|
|
2089
|
+
/**
|
|
2090
|
+
* List the chains and assets the sweeper watches
|
|
2091
|
+
* @description The chains and assets the sweeper watches.
|
|
2092
|
+
*
|
|
2093
|
+
* One entry per supported chain, each listing the sweepable assets there
|
|
2094
|
+
* with their token addresses and minimum sweep amounts (raw base units;
|
|
2095
|
+
* balances below the minimum wait until a later deposit lifts them past
|
|
2096
|
+
* it). The deposit address returned by `register_deposit_address` is the
|
|
2097
|
+
* same on every listed chain, and a registered address is watched on all of
|
|
2098
|
+
* them.
|
|
2099
|
+
*
|
|
2100
|
+
* Public and unauthenticated; the set changes only with operator
|
|
2101
|
+
* configuration.
|
|
2102
|
+
*/
|
|
2103
|
+
get: operations["get_sweeper_chains"];
|
|
2104
|
+
put?: never;
|
|
2105
|
+
post?: never;
|
|
2106
|
+
delete?: never;
|
|
2107
|
+
options?: never;
|
|
2108
|
+
head?: never;
|
|
2109
|
+
patch?: never;
|
|
2110
|
+
trace?: never;
|
|
2111
|
+
};
|
|
2082
2112
|
"/api/v1/sweeper/register": {
|
|
2083
2113
|
parameters: {
|
|
2084
2114
|
query?: never;
|
|
@@ -2093,20 +2123,23 @@ export interface paths {
|
|
|
2093
2123
|
* @description Register a deposit address for monitoring.
|
|
2094
2124
|
*
|
|
2095
2125
|
* Every (application, user, deposit target) triple has a deterministic
|
|
2096
|
-
* deposit address
|
|
2097
|
-
*
|
|
2098
|
-
*
|
|
2126
|
+
* deposit address — the SAME address on every supported chain. This
|
|
2127
|
+
* registers the caller's own address so the sweeper service watches it on
|
|
2128
|
+
* every chain it is configured for (`get_sweeper_chains` lists the set) and
|
|
2129
|
+
* automatically forwards every supported deposit into the exchange,
|
|
2130
|
+
* crediting the caller under the application. One registration covers all
|
|
2131
|
+
* supported chains — there is nothing chain-specific to choose.
|
|
2099
2132
|
*
|
|
2100
2133
|
* Authenticated, and the whole identity comes from the session: the
|
|
2101
2134
|
* application is the one `login` established the session under, and the
|
|
2102
2135
|
* credited address is the session's own. Neither is a request parameter, so a
|
|
2103
2136
|
* caller can only ever register their own address under their own
|
|
2104
|
-
* application. The
|
|
2137
|
+
* application. The body carries only which ledger to aim at.
|
|
2105
2138
|
*
|
|
2106
2139
|
* Registration also runs a one-time initial check in the background: any
|
|
2107
|
-
* balance already sitting on the address
|
|
2108
|
-
* transfer. The response returns immediately with
|
|
2109
|
-
* does not wait for that check.
|
|
2140
|
+
* balance already sitting on the address, on any supported chain, is swept
|
|
2141
|
+
* without waiting for a new transfer. The response returns immediately with
|
|
2142
|
+
* the derived address; it does not wait for that check.
|
|
2110
2143
|
*
|
|
2111
2144
|
* Idempotent and safe to retry: re-registering an existing triple returns
|
|
2112
2145
|
* `already_registered` with the same address and never re-triggers the
|
|
@@ -2340,6 +2373,12 @@ export interface components {
|
|
|
2340
2373
|
* @example true
|
|
2341
2374
|
*/
|
|
2342
2375
|
wrappedNative?: boolean | null;
|
|
2376
|
+
/**
|
|
2377
|
+
* Format: int64
|
|
2378
|
+
* @description Opaque, non-negative producer-owned version for this spot user_balances row. Compare only within the same (user, application, token); higher is newer. 0 is the unranked legacy sentinel and never participates in ordering: it means the row predates this field or came from a producer that does not stamp it, so treat it exactly as an absent version and fall back to a full field comparison rather than ranking it as oldest. This does not order margin collateral.
|
|
2379
|
+
* @example 918342
|
|
2380
|
+
*/
|
|
2381
|
+
version?: number | null;
|
|
2343
2382
|
};
|
|
2344
2383
|
AppUser: {
|
|
2345
2384
|
/**
|
|
@@ -3930,6 +3969,12 @@ export interface components {
|
|
|
3930
3969
|
* @example true
|
|
3931
3970
|
*/
|
|
3932
3971
|
wrappedNative?: boolean | null;
|
|
3972
|
+
/**
|
|
3973
|
+
* Format: int64
|
|
3974
|
+
* @description Opaque, non-negative producer-owned version for this spot user_balances row. Compare only within the same (user, application, token); higher is newer. 0 is the unranked legacy sentinel and never participates in ordering: it means the row predates this field or came from a producer that does not stamp it, so treat it exactly as an absent version and fall back to a full field comparison rather than ranking it as oldest. This does not order margin collateral.
|
|
3975
|
+
* @example 918342
|
|
3976
|
+
*/
|
|
3977
|
+
version?: number | null;
|
|
3933
3978
|
};
|
|
3934
3979
|
GetBalancesResponse: {
|
|
3935
3980
|
balances?: components["schemas"]["AccountBalance"][] | null;
|
|
@@ -3962,6 +4007,10 @@ export interface components {
|
|
|
3962
4007
|
GetCandlesResponse: {
|
|
3963
4008
|
candles?: components["schemas"]["Candle"][] | null;
|
|
3964
4009
|
};
|
|
4010
|
+
GetChainsResponse: {
|
|
4011
|
+
/** @description One entry per chain the sweeper watches */
|
|
4012
|
+
chains?: components["schemas"]["SweeperChain"][] | null;
|
|
4013
|
+
};
|
|
3965
4014
|
GetConfigResponse: {
|
|
3966
4015
|
/**
|
|
3967
4016
|
* @description Application UUID
|
|
@@ -7169,6 +7218,49 @@ export interface components {
|
|
|
7169
7218
|
*/
|
|
7170
7219
|
userId?: string | null;
|
|
7171
7220
|
};
|
|
7221
|
+
SweeperChain: {
|
|
7222
|
+
/**
|
|
7223
|
+
* Format: int64
|
|
7224
|
+
* @description The chain's EVM chain id, served as a JSON number and always at most 2^53 - 1 (JavaScript's safe-integer range). Every registered deposit address is watched on every listed chain — the address is identical on all of them
|
|
7225
|
+
* @example 1329
|
|
7226
|
+
*/
|
|
7227
|
+
chainId?: number | null;
|
|
7228
|
+
/**
|
|
7229
|
+
* @description Short human-readable chain name
|
|
7230
|
+
* @example sei
|
|
7231
|
+
*/
|
|
7232
|
+
name?: string | null;
|
|
7233
|
+
/**
|
|
7234
|
+
* @description Whether this is the settlement (hub) chain deposits are forwarded into; deposits on every other listed chain are bridged there automatically
|
|
7235
|
+
* @example true
|
|
7236
|
+
*/
|
|
7237
|
+
hub?: boolean | null;
|
|
7238
|
+
/** @description The assets swept on this chain */
|
|
7239
|
+
assets?: components["schemas"]["SweeperChainAsset"][] | null;
|
|
7240
|
+
};
|
|
7241
|
+
SweeperChainAsset: {
|
|
7242
|
+
/**
|
|
7243
|
+
* @description The asset's symbol on this chain
|
|
7244
|
+
* @example USDC
|
|
7245
|
+
*/
|
|
7246
|
+
symbol?: string | null;
|
|
7247
|
+
/**
|
|
7248
|
+
* @description The ERC20 contract address to send on this chain
|
|
7249
|
+
* @example 0xe15fC38F6D8c56aF07bbCBe3BAf5708A2Bf42392
|
|
7250
|
+
*/
|
|
7251
|
+
tokenAddress?: string | null;
|
|
7252
|
+
/**
|
|
7253
|
+
* Format: uint32
|
|
7254
|
+
* @description The token's decimals on this chain; 0 when not published
|
|
7255
|
+
* @example 6
|
|
7256
|
+
*/
|
|
7257
|
+
decimals?: number | null;
|
|
7258
|
+
/**
|
|
7259
|
+
* @description Minimum sweepable balance in raw base units; smaller balances wait until a later deposit lifts the total past it
|
|
7260
|
+
* @example 5000000
|
|
7261
|
+
*/
|
|
7262
|
+
minSweepRaw?: string | null;
|
|
7263
|
+
};
|
|
7172
7264
|
TpSlLeg: {
|
|
7173
7265
|
triggerPrice?: string | null;
|
|
7174
7266
|
orderType?: string | null;
|
|
@@ -10900,7 +10992,7 @@ export interface operations {
|
|
|
10900
10992
|
};
|
|
10901
10993
|
content?: never;
|
|
10902
10994
|
};
|
|
10903
|
-
/** @description Order rate limit exceeded — the per-account item-weighted budget is spent; retry after the interval in details.retryAfter */
|
|
10995
|
+
/** @description Order rate limit exceeded — the per-account item-weighted budget, or the budget the account family (master and sub-accounts) shares, is spent; retry after the interval in details.retryAfter */
|
|
10904
10996
|
429: {
|
|
10905
10997
|
headers: {
|
|
10906
10998
|
[name: string]: unknown;
|
|
@@ -10959,7 +11051,7 @@ export interface operations {
|
|
|
10959
11051
|
};
|
|
10960
11052
|
content?: never;
|
|
10961
11053
|
};
|
|
10962
|
-
/** @description Risk-reduction rate limit exceeded — each id counts against the 2x risk-reduction budget and the whole request is rejected; retry after the interval in details.retryAfter */
|
|
11054
|
+
/** @description Risk-reduction rate limit exceeded — each id counts against the 2x risk-reduction budget (per account, and shared across the account family) and the whole request is rejected; retry after the interval in details.retryAfter */
|
|
10963
11055
|
429: {
|
|
10964
11056
|
headers: {
|
|
10965
11057
|
[name: string]: unknown;
|
|
@@ -11000,6 +11092,13 @@ export interface operations {
|
|
|
11000
11092
|
};
|
|
11001
11093
|
content?: never;
|
|
11002
11094
|
};
|
|
11095
|
+
/** @description Risk-reduction rate limit exceeded — mass exit costs one risk-reduction item per call (per account and account family), however many orders it cancels; retry after the interval in details.retryAfter */
|
|
11096
|
+
429: {
|
|
11097
|
+
headers: {
|
|
11098
|
+
[name: string]: unknown;
|
|
11099
|
+
};
|
|
11100
|
+
content?: never;
|
|
11101
|
+
};
|
|
11003
11102
|
/** @description Internal server error or matching engine failure */
|
|
11004
11103
|
500: {
|
|
11005
11104
|
headers: {
|
|
@@ -11044,6 +11143,13 @@ export interface operations {
|
|
|
11044
11143
|
};
|
|
11045
11144
|
content?: never;
|
|
11046
11145
|
};
|
|
11146
|
+
/** @description Risk-reduction rate limit exceeded — mass exit costs one risk-reduction item per call (per account and account family), however many orders it cancels; retry after the interval in details.retryAfter */
|
|
11147
|
+
429: {
|
|
11148
|
+
headers: {
|
|
11149
|
+
[name: string]: unknown;
|
|
11150
|
+
};
|
|
11151
|
+
content?: never;
|
|
11152
|
+
};
|
|
11047
11153
|
/** @description Internal server error or matching engine failure */
|
|
11048
11154
|
500: {
|
|
11049
11155
|
headers: {
|
|
@@ -11089,7 +11195,7 @@ export interface operations {
|
|
|
11089
11195
|
};
|
|
11090
11196
|
content?: never;
|
|
11091
11197
|
};
|
|
11092
|
-
/** @description Order rate limit exceeded — each batch item counts against the per-account budget and the whole request is rejected; retry after the interval in details.retryAfter */
|
|
11198
|
+
/** @description Order rate limit exceeded — each batch item counts against the per-account budget (and the account family's shared budget) and the whole request is rejected; retry after the interval in details.retryAfter */
|
|
11093
11199
|
429: {
|
|
11094
11200
|
headers: {
|
|
11095
11201
|
[name: string]: unknown;
|
|
@@ -11141,7 +11247,7 @@ export interface operations {
|
|
|
11141
11247
|
};
|
|
11142
11248
|
content?: never;
|
|
11143
11249
|
};
|
|
11144
|
-
/** @description Order rate limit exceeded — each batch item counts against the per-account budget and the whole request is rejected; retry after the interval in details.retryAfter */
|
|
11250
|
+
/** @description Order rate limit exceeded — each batch item counts against the per-account budget (and the account family's shared budget) and the whole request is rejected; retry after the interval in details.retryAfter */
|
|
11145
11251
|
429: {
|
|
11146
11252
|
headers: {
|
|
11147
11253
|
[name: string]: unknown;
|
|
@@ -11200,7 +11306,7 @@ export interface operations {
|
|
|
11200
11306
|
};
|
|
11201
11307
|
content?: never;
|
|
11202
11308
|
};
|
|
11203
|
-
/** @description Risk-reduction rate limit exceeded — cancels draw the 2x risk-reduction budget; retry after the interval in details.retryAfter */
|
|
11309
|
+
/** @description Risk-reduction rate limit exceeded — cancels draw the 2x risk-reduction budget (per account, and shared across the account family); retry after the interval in details.retryAfter */
|
|
11204
11310
|
429: {
|
|
11205
11311
|
headers: {
|
|
11206
11312
|
[name: string]: unknown;
|
|
@@ -11289,7 +11395,7 @@ export interface operations {
|
|
|
11289
11395
|
"application/json": components["schemas"]["CancelConditionalOrderResponse"];
|
|
11290
11396
|
};
|
|
11291
11397
|
};
|
|
11292
|
-
/** @description Risk-reduction rate limit exceeded — cancels draw the 2x risk-reduction budget; retry after the interval in details.retryAfter */
|
|
11398
|
+
/** @description Risk-reduction rate limit exceeded — cancels draw the 2x risk-reduction budget (per account, and shared across the account family); retry after the interval in details.retryAfter */
|
|
11293
11399
|
429: {
|
|
11294
11400
|
headers: {
|
|
11295
11401
|
[name: string]: unknown;
|
|
@@ -11390,6 +11496,13 @@ export interface operations {
|
|
|
11390
11496
|
};
|
|
11391
11497
|
content?: never;
|
|
11392
11498
|
};
|
|
11499
|
+
/** @description Order rate limit exceeded — a TWAP parent costs one order-creation item against the per-account budget and the account family's shared budget; retry after the interval in details.retryAfter */
|
|
11500
|
+
429: {
|
|
11501
|
+
headers: {
|
|
11502
|
+
[name: string]: unknown;
|
|
11503
|
+
};
|
|
11504
|
+
content?: never;
|
|
11505
|
+
};
|
|
11393
11506
|
/** @description Internal server error or matching engine failure */
|
|
11394
11507
|
500: {
|
|
11395
11508
|
headers: {
|
|
@@ -11490,7 +11603,7 @@ export interface operations {
|
|
|
11490
11603
|
};
|
|
11491
11604
|
content?: never;
|
|
11492
11605
|
};
|
|
11493
|
-
/** @description Risk-reduction rate limit exceeded — cancels draw the 2x risk-reduction budget; retry after the interval in details.retryAfter */
|
|
11606
|
+
/** @description Risk-reduction rate limit exceeded — cancels draw the 2x risk-reduction budget (per account, and shared across the account family); retry after the interval in details.retryAfter */
|
|
11494
11607
|
429: {
|
|
11495
11608
|
headers: {
|
|
11496
11609
|
[name: string]: unknown;
|
|
@@ -11660,7 +11773,7 @@ export interface operations {
|
|
|
11660
11773
|
};
|
|
11661
11774
|
content?: never;
|
|
11662
11775
|
};
|
|
11663
|
-
/** @description Order rate limit exceeded — the per-account item-weighted budget is spent; retry after the interval in details.retryAfter */
|
|
11776
|
+
/** @description Order rate limit exceeded — the per-account item-weighted budget, or the budget the account family (master and sub-accounts) shares, is spent; retry after the interval in details.retryAfter */
|
|
11664
11777
|
429: {
|
|
11665
11778
|
headers: {
|
|
11666
11779
|
[name: string]: unknown;
|
|
@@ -12254,6 +12367,40 @@ export interface operations {
|
|
|
12254
12367
|
};
|
|
12255
12368
|
};
|
|
12256
12369
|
};
|
|
12370
|
+
get_sweeper_chains: {
|
|
12371
|
+
parameters: {
|
|
12372
|
+
query?: never;
|
|
12373
|
+
header?: never;
|
|
12374
|
+
path?: never;
|
|
12375
|
+
cookie?: never;
|
|
12376
|
+
};
|
|
12377
|
+
requestBody?: never;
|
|
12378
|
+
responses: {
|
|
12379
|
+
/** @description OK */
|
|
12380
|
+
200: {
|
|
12381
|
+
headers: {
|
|
12382
|
+
[name: string]: unknown;
|
|
12383
|
+
};
|
|
12384
|
+
content: {
|
|
12385
|
+
"application/json": components["schemas"]["GetChainsResponse"];
|
|
12386
|
+
};
|
|
12387
|
+
};
|
|
12388
|
+
/** @description Internal server error */
|
|
12389
|
+
500: {
|
|
12390
|
+
headers: {
|
|
12391
|
+
[name: string]: unknown;
|
|
12392
|
+
};
|
|
12393
|
+
content?: never;
|
|
12394
|
+
};
|
|
12395
|
+
/** @description Sweeper unavailable (not configured or resolver down); safe to retry */
|
|
12396
|
+
503: {
|
|
12397
|
+
headers: {
|
|
12398
|
+
[name: string]: unknown;
|
|
12399
|
+
};
|
|
12400
|
+
content?: never;
|
|
12401
|
+
};
|
|
12402
|
+
};
|
|
12403
|
+
};
|
|
12257
12404
|
register_deposit_address: {
|
|
12258
12405
|
parameters: {
|
|
12259
12406
|
query?: never;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@0xmonaco/types",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.56",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"homepage": "https://docs.0xmonaco.com/sdk/typescript",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"lint": "biome lint ."
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@0xmonaco/contracts": "1.0.
|
|
19
|
+
"@0xmonaco/contracts": "1.0.56",
|
|
20
20
|
"zod": "^4.1.12"
|
|
21
21
|
},
|
|
22
22
|
"peerDependencies": {
|