@0xmonaco/types 1.1.7 → 1.1.9
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/analytics/builders.d.ts +9 -2
- package/dist/analytics/index.d.ts +20 -1
- package/dist/fees/responses.d.ts +7 -0
- package/dist/fees/responses.js +15 -7
- package/dist/margin-accounts/index.d.ts +9 -4
- package/dist/market/index.d.ts +7 -3
- package/dist/rfq/index.d.ts +12 -1
- package/dist/rfq/responses.d.ts +142 -0
- package/dist/rfq/responses.js +7 -0
- package/dist/sweeper/index.d.ts +181 -0
- package/dist/validation/rfq.d.ts +5 -0
- package/dist/validation/rfq.js +7 -0
- package/dist/wire/operations.d.ts +1 -1
- package/dist/wire/operations.js +1 -0
- package/dist/wire/schema.d.ts +171 -22
- package/package.json +2 -2
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* Fees here are the builder's own add-ons (taker plus maker), never the
|
|
10
10
|
* protocol taker fee. USD amounts are decimal strings (USDC 1:1).
|
|
11
11
|
*/
|
|
12
|
-
import type { AnalyticsWindow, AnalyticsWindowParams } from "./index";
|
|
12
|
+
import type { AnalyticsWindow, AnalyticsWindowParams, VolumeUsdBySource } from "./index";
|
|
13
13
|
/** A builder's kind. */
|
|
14
14
|
export type BuilderKind = "application" | "group";
|
|
15
15
|
/** The display group an application is shown under. */
|
|
@@ -78,6 +78,8 @@ export interface BuilderFigures {
|
|
|
78
78
|
withdrawalsUsd: string;
|
|
79
79
|
/** `depositsUsd` less `withdrawalsUsd`; negative when more left than arrived. */
|
|
80
80
|
netFlowUsd: string;
|
|
81
|
+
/** `volumeUsd` split into its order-book and RFQ parts, counting the trades the builder took; absent when it covers a bucket folded before the split was recorded. */
|
|
82
|
+
volumeBySource?: VolumeUsdBySource;
|
|
81
83
|
}
|
|
82
84
|
/** Every displayed builder, by name. */
|
|
83
85
|
export interface ListBuildersResponse {
|
|
@@ -95,6 +97,8 @@ export interface GetBuilderTotalsResponse extends BuilderFigures {
|
|
|
95
97
|
activeTakers: number;
|
|
96
98
|
/** Wallets whose first trade through one of its applications fell in the window, once per (application, wallet). */
|
|
97
99
|
newTraders: number;
|
|
100
|
+
/** Accounts registered in the window under one of its applications (sign-ups), whether or not they traded. */
|
|
101
|
+
newAccounts: number;
|
|
98
102
|
}
|
|
99
103
|
/** A builder's figures for one bucket. */
|
|
100
104
|
export interface BuilderSeriesPoint extends BuilderFigures {
|
|
@@ -102,6 +106,7 @@ export interface BuilderSeriesPoint extends BuilderFigures {
|
|
|
102
106
|
bucketStart: number;
|
|
103
107
|
activeTakers: number;
|
|
104
108
|
newTraders: number;
|
|
109
|
+
newAccounts: number;
|
|
105
110
|
}
|
|
106
111
|
/** A builder's figures per bucket over a window. */
|
|
107
112
|
export interface GetBuilderSeriesResponse {
|
|
@@ -115,10 +120,12 @@ export interface ListBuilderLeaderboardParams extends AnalyticsWindowParams {
|
|
|
115
120
|
/** Builders to return, largest volume first (1-100, default 25). */
|
|
116
121
|
limit?: number;
|
|
117
122
|
}
|
|
118
|
-
/** One builder's row on the leaderboard; a display group ranks as one. A builder that only took deposits ranks with zero volume. */
|
|
123
|
+
/** One builder's row on the leaderboard; a display group ranks as one. A builder that only took deposits or only registered accounts ranks with zero volume. */
|
|
119
124
|
export interface BuilderLeaderboardRow extends BuilderFigures {
|
|
120
125
|
builder: Builder;
|
|
121
126
|
newTraders: number;
|
|
127
|
+
/** Accounts registered in the window under one of its applications (sign-ups). */
|
|
128
|
+
newAccounts: number;
|
|
122
129
|
/**
|
|
123
130
|
* Distinct taker wallets that traded through the builder, each once. With
|
|
124
131
|
* `window: "all"`, every wallet that ever traded through it. `null` for a
|
|
@@ -50,6 +50,16 @@ export interface AnalyticsWindow {
|
|
|
50
50
|
/** Bucket size the window is counted in. */
|
|
51
51
|
granularity: AnalyticsGranularity | (string & {});
|
|
52
52
|
}
|
|
53
|
+
/**
|
|
54
|
+
* A USD volume split by how it executed (RFQ-17). `orderBookVolumeUsd` plus
|
|
55
|
+
* `rfqVolumeUsd` is exactly the `volumeUsd` beside it.
|
|
56
|
+
*/
|
|
57
|
+
export interface VolumeUsdBySource {
|
|
58
|
+
/** The part of `volumeUsd` filled on the order book: `volumeUsd` less `rfqVolumeUsd`. */
|
|
59
|
+
orderBookVolumeUsd: string;
|
|
60
|
+
/** The part of `volumeUsd` filled by RFQ block trades. */
|
|
61
|
+
rfqVolumeUsd: string;
|
|
62
|
+
}
|
|
53
63
|
/** Protocol figures over a window or one bucket. */
|
|
54
64
|
export interface ProtocolFigures {
|
|
55
65
|
/** Taker volume in USD routed by the displayed builders; hidden builders' trades are not counted. */
|
|
@@ -64,8 +74,15 @@ export interface ProtocolFigures {
|
|
|
64
74
|
protocolFeesUsd: string;
|
|
65
75
|
/** Distinct taker wallets that traded (each once), all builders included. */
|
|
66
76
|
activeTakers: number;
|
|
67
|
-
/** Wallets whose first trade
|
|
77
|
+
/** Wallets whose first trade on the protocol fell inside, each counted once however many builders it traded through. */
|
|
68
78
|
newTraders: number;
|
|
79
|
+
/**
|
|
80
|
+
* Accounts registered inside (sign-ups) under any application, whether or not
|
|
81
|
+
* they traded, all builders included; `newTraders` counts first trades instead.
|
|
82
|
+
*/
|
|
83
|
+
newAccounts: number;
|
|
84
|
+
/** `volumeUsd` split into its order-book and RFQ parts; absent when it covers a bucket folded before the split was recorded. */
|
|
85
|
+
volumeBySource?: VolumeUsdBySource;
|
|
69
86
|
}
|
|
70
87
|
/** USDC custody flow over a window or one bucket, in USD (1:1). */
|
|
71
88
|
export interface CustodyFlows {
|
|
@@ -113,6 +130,8 @@ export interface MarketVolume {
|
|
|
113
130
|
protocolFeesUsd: string;
|
|
114
131
|
/** Trades in the market. */
|
|
115
132
|
tradesCount: number;
|
|
133
|
+
/** `volumeUsd` split into its order-book and RFQ parts; absent when the window holds a bucket folded before the split was recorded. */
|
|
134
|
+
volumeBySource?: VolumeUsdBySource;
|
|
116
135
|
}
|
|
117
136
|
/** Volume per market over a window. */
|
|
118
137
|
export interface ListMarketVolumesResponse {
|
package/dist/fees/responses.d.ts
CHANGED
|
@@ -85,6 +85,13 @@ export declare const GetMyFeeTierResponseSchema: z.ZodObject<{
|
|
|
85
85
|
makerFeeBps: z.ZodString;
|
|
86
86
|
takerFeeBps: z.ZodString;
|
|
87
87
|
}, z.core.$strip>>;
|
|
88
|
+
rateSource: z.ZodEnum<{
|
|
89
|
+
custom: "custom";
|
|
90
|
+
tier_override: "tier_override";
|
|
91
|
+
volume: "volume";
|
|
92
|
+
}>;
|
|
93
|
+
makerFeeBps: z.ZodString;
|
|
94
|
+
takerFeeBps: z.ZodString;
|
|
88
95
|
}, z.core.$strip>;
|
|
89
96
|
/**
|
|
90
97
|
* Zod schema for the parameters of a public fee schedule lookup
|
package/dist/fees/responses.js
CHANGED
|
@@ -67,17 +67,19 @@ export const SimulateFeeResponseSchema = z.object({
|
|
|
67
67
|
applicationMakerFee: z.string().optional(),
|
|
68
68
|
/** Maker add-on rate in basis points an order placed now would store. Absent from servers older than this field */
|
|
69
69
|
applicationMakerFeeBps: z.number().optional(),
|
|
70
|
-
/** Monaco protocol maker
|
|
70
|
+
/** Monaco protocol maker fee: negative is a rebate, positive is a fee */
|
|
71
71
|
monacoMakerRebate: z.string(),
|
|
72
72
|
/**
|
|
73
|
-
*
|
|
74
|
-
*
|
|
73
|
+
* Monaco maker rate as a decimal basis-points string (negative is a rebate, positive is
|
|
74
|
+
* a fee), e.g. "-1" — the exact rate this caller gets, from their tier or the assigned or
|
|
75
|
+
* custom rate on their wallet.
|
|
75
76
|
*/
|
|
76
77
|
monacoMakerRebateBpsExact: z.string(),
|
|
77
78
|
/** Monaco protocol taker fee */
|
|
78
79
|
monacoTakerFee: z.string(),
|
|
79
80
|
/**
|
|
80
|
-
*
|
|
81
|
+
* Monaco taker fee, from the caller's tier or the assigned or custom rate on their
|
|
82
|
+
* wallet, as a decimal basis-points string, e.g. "6.5" — the exact
|
|
81
83
|
* rate the ledger charges this caller (equals monacoTakerFee / notional).
|
|
82
84
|
*/
|
|
83
85
|
monacoTakerFeeBpsExact: z.string(),
|
|
@@ -118,7 +120,7 @@ export const FeeTierScheduleRowSchema = z.object({
|
|
|
118
120
|
* Zod schema for the "my fee tier" response
|
|
119
121
|
*/
|
|
120
122
|
export const GetMyFeeTierResponseSchema = z.object({
|
|
121
|
-
/** Caller's
|
|
123
|
+
/** Caller's tier (1–6) on the requested pair: the tier their rates come from, or the tier their wallet's recorded weighted 14-day volume earns when `rateSource` is `custom` */
|
|
122
124
|
currentTierLevel: z.number().int(),
|
|
123
125
|
/** Caller's weighted 14-day volume (perp + 2.5× spot), summed across every application the wallet trades through */
|
|
124
126
|
weightedVolume14d: z.string(),
|
|
@@ -126,12 +128,18 @@ export const GetMyFeeTierResponseSchema = z.object({
|
|
|
126
128
|
spotVolume14d: z.string(),
|
|
127
129
|
/** Caller's rolling 14-day perp volume, summed across every application the wallet trades through */
|
|
128
130
|
perpVolume14d: z.string(),
|
|
129
|
-
/** Additional weighted volume needed to reach the next tier, counted from the volume the current tier resolved from; absent at tier 6 */
|
|
131
|
+
/** Additional weighted volume needed to reach the next tier, counted from the volume the current tier resolved from; absent at tier 6 and unless `rateSource` is `volume` */
|
|
130
132
|
volumeToNextTier: z.string().nullable().optional(),
|
|
131
|
-
/** Next tier level; absent when already at tier 6 */
|
|
133
|
+
/** Next tier level; absent when already at tier 6 and unless `rateSource` is `volume` */
|
|
132
134
|
nextTierLevel: z.number().int().nullable().optional(),
|
|
133
135
|
/** Six-row fee schedule for the requested pair, ascending by tier */
|
|
134
136
|
feeSchedule: z.array(FeeTierScheduleRowSchema),
|
|
137
|
+
/** Why this rate applies: `volume` (the tier your 14-day volume earns), `tier_override` (an assigned tier), or `custom` (custom rates assigned to your wallet). Applies to orders you place now */
|
|
138
|
+
rateSource: z.enum(["volume", "tier_override", "custom"]),
|
|
139
|
+
/** Effective maker rate for the requested pair, in decimal basis points; negative is a rebate, positive is a fee */
|
|
140
|
+
makerFeeBps: z.string(),
|
|
141
|
+
/** Effective taker rate for the requested pair, in decimal basis points */
|
|
142
|
+
takerFeeBps: z.string(),
|
|
135
143
|
});
|
|
136
144
|
/**
|
|
137
145
|
* Zod schema for the parameters of a public fee schedule lookup
|
|
@@ -593,7 +593,7 @@ export interface CloseMarginSubAccountResponse {
|
|
|
593
593
|
/** Collateral moved to the default margin account. */
|
|
594
594
|
amount: string;
|
|
595
595
|
}
|
|
596
|
-
/** One side of a collateral transfer: the spot wallet,
|
|
596
|
+
/** One side of a collateral transfer: the spot wallet, a margin account, or one of its risk buckets. */
|
|
597
597
|
export type CollateralTransferEndpoint = {
|
|
598
598
|
wallet: true;
|
|
599
599
|
marginAccountId?: never;
|
|
@@ -604,9 +604,11 @@ export type CollateralTransferEndpoint = {
|
|
|
604
604
|
riskBucketId?: string;
|
|
605
605
|
};
|
|
606
606
|
/**
|
|
607
|
-
* Move collateral between
|
|
608
|
-
*
|
|
609
|
-
*
|
|
607
|
+
* Move collateral between any two of the caller's places: the spot wallet, a
|
|
608
|
+
* margin account, a risk bucket. A route that crosses accounts or the wallet
|
|
609
|
+
* runs up to three moves in one step, and a refused request moves nothing. The
|
|
610
|
+
* wallet is reached through the default margin account. A route to or from the
|
|
611
|
+
* wallet or a risk bucket refuses a copy-trading sub-account.
|
|
610
612
|
*/
|
|
611
613
|
export interface TransferMarginCollateralRequest {
|
|
612
614
|
asset: string;
|
|
@@ -628,6 +630,9 @@ export interface TransferMarginCollateralResponse {
|
|
|
628
630
|
fromMarginAccountId?: string;
|
|
629
631
|
toMarginAccountId?: string;
|
|
630
632
|
toRiskBucketId?: string;
|
|
633
|
+
fromRiskBucketId?: string;
|
|
634
|
+
/** Whether funding the risk bucket credited its sole open position's margin. Absent when the destination is not a risk bucket. */
|
|
635
|
+
positionMarginCredited?: boolean;
|
|
631
636
|
}
|
|
632
637
|
export interface MarginAccountsAPI extends BaseAPI {
|
|
633
638
|
/**
|
package/dist/market/index.d.ts
CHANGED
|
@@ -273,8 +273,8 @@ export interface ScreenerItem {
|
|
|
273
273
|
/**
|
|
274
274
|
* Estimated rate for the in-progress funding window (decimal fraction per
|
|
275
275
|
* window), the same value as `getFundingState().estimatedNextFundingRate`.
|
|
276
|
-
* A window that ends with too few accepted samples settles at the
|
|
277
|
-
* settled rate
|
|
276
|
+
* A window that ends with too few accepted samples settles at zero, so the
|
|
277
|
+
* settled rate can differ.
|
|
278
278
|
* Null for spot pairs and margin pairs whose current window has no samples yet
|
|
279
279
|
*/
|
|
280
280
|
estimatedNextFundingRate: string | null;
|
|
@@ -524,7 +524,11 @@ export interface FundingRecord {
|
|
|
524
524
|
windowClosedAt: string;
|
|
525
525
|
/** Settlement time (ISO 8601); the sort key for `listAllFundingHistory`. */
|
|
526
526
|
settledAt: string;
|
|
527
|
-
/**
|
|
527
|
+
/**
|
|
528
|
+
* True when the window held too few accepted samples and settled at zero
|
|
529
|
+
* (sparse-sample rule). Windows settled before 0XM-3728 carried the last
|
|
530
|
+
* settled rate instead.
|
|
531
|
+
*/
|
|
528
532
|
carried?: boolean;
|
|
529
533
|
}
|
|
530
534
|
export interface ListFundingHistoryParams {
|
package/dist/rfq/index.d.ts
CHANGED
|
@@ -9,7 +9,12 @@
|
|
|
9
9
|
*/
|
|
10
10
|
import type { BaseAPI } from "../api";
|
|
11
11
|
import type { AcceptRfqParams, CancelRfqParams, CreateRfqParams, RespondRfqLastLookParams, UpsertRfqQuoteParams, WithdrawRfqQuoteParams } from "../validation/rfq";
|
|
12
|
-
import type { GetRfqCapabilitiesResponse, RespondRfqLastLookResponse, RfqQuoteVersion, RfqStatus, WithdrawRfqQuoteResponse } from "./responses";
|
|
12
|
+
import type { GetRfqCapabilitiesResponse, ListRfqsResponse, RespondRfqLastLookResponse, RfqQuoteVersion, RfqStatus, WithdrawRfqQuoteResponse } from "./responses";
|
|
13
|
+
/** `listRfqs` paging: up to 100 per page (default 50), and the previous page's token. */
|
|
14
|
+
export interface ListRfqsParams {
|
|
15
|
+
pageSize?: number;
|
|
16
|
+
pageToken?: string;
|
|
17
|
+
}
|
|
13
18
|
/**
|
|
14
19
|
* RFQ API.
|
|
15
20
|
*
|
|
@@ -30,6 +35,12 @@ export interface RfqAPI extends BaseAPI {
|
|
|
30
35
|
* and, once selected, `ownSelection` for last look.
|
|
31
36
|
*/
|
|
32
37
|
getRfq(rfqId: string): Promise<RfqStatus>;
|
|
38
|
+
/**
|
|
39
|
+
* Your RFQs as the taker, newest first, in every state (those that filled
|
|
40
|
+
* nothing included). Each is as `getRfq` gives it, without the live `view`.
|
|
41
|
+
* Follow `nextPageToken` until it is empty.
|
|
42
|
+
*/
|
|
43
|
+
listRfqs(params?: ListRfqsParams): Promise<ListRfqsResponse>;
|
|
33
44
|
/** Accept one side of the view you last saw (`view.viewVersion`). Binding. */
|
|
34
45
|
acceptRfq(rfqId: string, params: AcceptRfqParams): Promise<RfqStatus>;
|
|
35
46
|
/** Cancel an RFQ you have not accepted, before its deadline. */
|
package/dist/rfq/responses.d.ts
CHANGED
|
@@ -336,6 +336,147 @@ export declare const RfqStatusSchema: z.ZodObject<{
|
|
|
336
336
|
bookFullSize: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
337
337
|
}, z.core.$strip>>>;
|
|
338
338
|
}, z.core.$strip>;
|
|
339
|
+
/** A page of your RFQs as the taker, newest first. */
|
|
340
|
+
export declare const ListRfqsResponseSchema: z.ZodObject<{
|
|
341
|
+
rfqs: z.ZodArray<z.ZodObject<{
|
|
342
|
+
terms: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
343
|
+
rfqId: z.ZodString;
|
|
344
|
+
tradingPairId: z.ZodString;
|
|
345
|
+
product: z.ZodOptional<z.ZodNullable<z.ZodType<"PERPETUAL" | "SPOT" | (string & {}), unknown, z.core.$ZodTypeInternals<"PERPETUAL" | "SPOT" | (string & {}), unknown>>>>;
|
|
346
|
+
quantity: z.ZodString;
|
|
347
|
+
createdAtMs: z.ZodNumber;
|
|
348
|
+
deadlineAtMs: z.ZodNumber;
|
|
349
|
+
side: z.ZodOptional<z.ZodNullable<z.ZodType<"BUY" | "SELL" | (string & {}), unknown, z.core.$ZodTypeInternals<"BUY" | "SELL" | (string & {}), unknown>>>>;
|
|
350
|
+
quoteSide: z.ZodOptional<z.ZodNullable<z.ZodType<"ASK" | "BID" | (string & {}), unknown, z.core.$ZodTypeInternals<"ASK" | "BID" | (string & {}), unknown>>>>;
|
|
351
|
+
leverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
352
|
+
marginMode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
353
|
+
}, z.core.$strip>>>;
|
|
354
|
+
state: z.ZodType<RfqState | (string & {}), unknown, z.core.$ZodTypeInternals<RfqState | (string & {}), unknown>>;
|
|
355
|
+
stateVersion: z.ZodNumber;
|
|
356
|
+
acceptedSide: z.ZodOptional<z.ZodNullable<z.ZodType<"BUY" | "SELL" | (string & {}), unknown, z.core.$ZodTypeInternals<"BUY" | "SELL" | (string & {}), unknown>>>>;
|
|
357
|
+
lastLookDeadlineAtMs: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
358
|
+
view: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
359
|
+
viewVersion: z.ZodNumber;
|
|
360
|
+
bid: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
361
|
+
vwap: z.ZodString;
|
|
362
|
+
availableQuantity: z.ZodString;
|
|
363
|
+
grossVwap: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
364
|
+
estimatedMonacoFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
365
|
+
estimatedBuilderFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
366
|
+
estimatedTotalFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
367
|
+
book: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
368
|
+
vwap: z.ZodString;
|
|
369
|
+
grossVwap: z.ZodString;
|
|
370
|
+
asOfMs: z.ZodNumber;
|
|
371
|
+
levels: z.ZodNumber;
|
|
372
|
+
}, z.core.$strip>>>;
|
|
373
|
+
}, z.core.$strip>>>;
|
|
374
|
+
ask: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
375
|
+
vwap: z.ZodString;
|
|
376
|
+
availableQuantity: z.ZodString;
|
|
377
|
+
grossVwap: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
378
|
+
estimatedMonacoFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
379
|
+
estimatedBuilderFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
380
|
+
estimatedTotalFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
381
|
+
book: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
382
|
+
vwap: z.ZodString;
|
|
383
|
+
grossVwap: z.ZodString;
|
|
384
|
+
asOfMs: z.ZodNumber;
|
|
385
|
+
levels: z.ZodNumber;
|
|
386
|
+
}, z.core.$strip>>>;
|
|
387
|
+
}, z.core.$strip>>>;
|
|
388
|
+
asOfMs: z.ZodNumber;
|
|
389
|
+
monacoFeeCbps: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
390
|
+
builderFeeCbps: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
391
|
+
}, z.core.$strip>>>;
|
|
392
|
+
ownQuote: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
393
|
+
rfqId: z.ZodString;
|
|
394
|
+
quoteId: z.ZodString;
|
|
395
|
+
version: z.ZodNumber;
|
|
396
|
+
bid: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
397
|
+
price: z.ZodString;
|
|
398
|
+
capacity: z.ZodString;
|
|
399
|
+
}, z.core.$strip>>>;
|
|
400
|
+
ask: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
401
|
+
price: z.ZodString;
|
|
402
|
+
capacity: z.ZodString;
|
|
403
|
+
}, z.core.$strip>>>;
|
|
404
|
+
issuedAtMs: z.ZodNumber;
|
|
405
|
+
validUntilMs: z.ZodNumber;
|
|
406
|
+
leverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
407
|
+
marginMode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
408
|
+
refusedSides: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
409
|
+
side: z.ZodType<"ASK" | "BID" | (string & {}), unknown, z.core.$ZodTypeInternals<"ASK" | "BID" | (string & {}), unknown>>;
|
|
410
|
+
code: z.ZodString;
|
|
411
|
+
reason: z.ZodString;
|
|
412
|
+
}, z.core.$strip>>>>;
|
|
413
|
+
}, z.core.$strip>>>;
|
|
414
|
+
ownSelection: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
415
|
+
acceptanceId: z.ZodString;
|
|
416
|
+
takerSide: z.ZodOptional<z.ZodNullable<z.ZodType<"BUY" | "SELL" | (string & {}), unknown, z.core.$ZodTypeInternals<"BUY" | "SELL" | (string & {}), unknown>>>>;
|
|
417
|
+
quoteId: z.ZodString;
|
|
418
|
+
quoteVersion: z.ZodNumber;
|
|
419
|
+
quantity: z.ZodString;
|
|
420
|
+
frozenTerms: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
421
|
+
price: z.ZodString;
|
|
422
|
+
capacity: z.ZodString;
|
|
423
|
+
}, z.core.$strip>>>;
|
|
424
|
+
lastLookDeadlineAtMs: z.ZodNumber;
|
|
425
|
+
monacoFeeCbps: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
426
|
+
maxBuilderFeeCbps: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
427
|
+
estimatedNet: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
428
|
+
}, z.core.$strip>>>;
|
|
429
|
+
ownLatestVersion: z.ZodNumber;
|
|
430
|
+
ownQuoteWithdrawn: z.ZodBoolean;
|
|
431
|
+
outcome: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
432
|
+
executedQuantity: z.ZodString;
|
|
433
|
+
unfilledQuantity: z.ZodString;
|
|
434
|
+
vwap: z.ZodString;
|
|
435
|
+
fills: z.ZodArray<z.ZodObject<{
|
|
436
|
+
executionId: z.ZodString;
|
|
437
|
+
price: z.ZodString;
|
|
438
|
+
quantity: z.ZodString;
|
|
439
|
+
fee: z.ZodString;
|
|
440
|
+
monacoFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
441
|
+
builderFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
442
|
+
}, z.core.$strip>>;
|
|
443
|
+
allInVwap: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
444
|
+
bookAtFill: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
445
|
+
vwap: z.ZodString;
|
|
446
|
+
grossVwap: z.ZodString;
|
|
447
|
+
asOfMs: z.ZodNumber;
|
|
448
|
+
levels: z.ZodNumber;
|
|
449
|
+
}, z.core.$strip>>>;
|
|
450
|
+
bookAtFillFullSize: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
451
|
+
}, z.core.$strip>>>;
|
|
452
|
+
durableSequence: z.ZodNumber;
|
|
453
|
+
ownFills: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
454
|
+
executionId: z.ZodString;
|
|
455
|
+
price: z.ZodString;
|
|
456
|
+
quantity: z.ZodString;
|
|
457
|
+
fee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
458
|
+
monacoFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
459
|
+
builderFee: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
460
|
+
}, z.core.$strip>>>>;
|
|
461
|
+
acceptance: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
462
|
+
viewVersion: z.ZodNumber;
|
|
463
|
+
acceptedAtMs: z.ZodNumber;
|
|
464
|
+
vwap: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
465
|
+
grossVwap: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
466
|
+
availableQuantity: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
467
|
+
monacoFeeCbps: z.ZodNumber;
|
|
468
|
+
builderFeeCbps: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
469
|
+
book: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
470
|
+
vwap: z.ZodString;
|
|
471
|
+
grossVwap: z.ZodString;
|
|
472
|
+
asOfMs: z.ZodNumber;
|
|
473
|
+
levels: z.ZodNumber;
|
|
474
|
+
}, z.core.$strip>>>;
|
|
475
|
+
bookFullSize: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
476
|
+
}, z.core.$strip>>>;
|
|
477
|
+
}, z.core.$strip>>;
|
|
478
|
+
nextPageToken: z.ZodString;
|
|
479
|
+
}, z.core.$strip>;
|
|
339
480
|
/** A market RFQ is offered on. */
|
|
340
481
|
export declare const RfqMarketCapabilitySchema: z.ZodObject<{
|
|
341
482
|
tradingPairId: z.ZodString;
|
|
@@ -385,6 +526,7 @@ export type RfqQuoteVersion = z.infer<typeof RfqQuoteVersionSchema>;
|
|
|
385
526
|
export type RfqRefusedSide = z.infer<typeof RfqRefusedSideSchema>;
|
|
386
527
|
export type RfqMakerSelection = z.infer<typeof RfqMakerSelectionSchema>;
|
|
387
528
|
export type RfqStatus = z.infer<typeof RfqStatusSchema>;
|
|
529
|
+
export type ListRfqsResponse = z.infer<typeof ListRfqsResponseSchema>;
|
|
388
530
|
export type RfqMarketCapability = z.infer<typeof RfqMarketCapabilitySchema>;
|
|
389
531
|
export type GetRfqCapabilitiesResponse = z.infer<typeof GetRfqCapabilitiesResponseSchema>;
|
|
390
532
|
export type WithdrawRfqQuoteResponse = z.infer<typeof WithdrawRfqQuoteResponseSchema>;
|
package/dist/rfq/responses.js
CHANGED
|
@@ -233,6 +233,13 @@ export const RfqStatusSchema = z.object({
|
|
|
233
233
|
/** Taker only: what your view showed when you accepted. */
|
|
234
234
|
acceptance: RfqAcceptanceRecordSchema.nullish(),
|
|
235
235
|
});
|
|
236
|
+
/** A page of your RFQs as the taker, newest first. */
|
|
237
|
+
export const ListRfqsResponseSchema = z.object({
|
|
238
|
+
/** Each as `getRfq` gives it to the taker, without the live `view`. */
|
|
239
|
+
rfqs: z.array(RfqStatusSchema),
|
|
240
|
+
/** Pass as `pageToken` for the next page; empty once there are no more. */
|
|
241
|
+
nextPageToken: z.string(),
|
|
242
|
+
});
|
|
236
243
|
/** A market RFQ is offered on. */
|
|
237
244
|
export const RfqMarketCapabilitySchema = z.object({
|
|
238
245
|
tradingPairId: z.string(),
|
package/dist/sweeper/index.d.ts
CHANGED
|
@@ -204,6 +204,121 @@ export interface ListSweeperDepositsResponse {
|
|
|
204
204
|
/** Cursor for the next page; empty when this page is the last */
|
|
205
205
|
nextPageToken: string;
|
|
206
206
|
}
|
|
207
|
+
/**
|
|
208
|
+
* Which Hyperliquid (HyperCore) balance a {@link SweeperAPI.depositFromHypercore}
|
|
209
|
+
* withdrawal draws on.
|
|
210
|
+
*/
|
|
211
|
+
export type HypercoreBalanceSource = "perp" | "spot";
|
|
212
|
+
/**
|
|
213
|
+
* A Hyperliquid account's abstraction mode, as Hyperliquid's `userAbstraction`
|
|
214
|
+
* query reports it. `unifiedAccount` and `portfolioMargin` keep one balance per
|
|
215
|
+
* asset, reported as spot; the others keep separate perp and spot balances.
|
|
216
|
+
* Widened: Hyperliquid may add modes this SDK version predates.
|
|
217
|
+
*/
|
|
218
|
+
export type HypercoreAccountMode = "unifiedAccount" | "portfolioMargin" | "disabled" | "default" | "dexAbstraction" | (string & {});
|
|
219
|
+
/**
|
|
220
|
+
* What a deposit from Hyperliquid can draw on, from
|
|
221
|
+
* {@link SweeperAPI.getHypercoreDepositInfo}. Amounts are raw USDC base units
|
|
222
|
+
* (6 decimals), truncated from Hyperliquid's own decimals.
|
|
223
|
+
*/
|
|
224
|
+
export interface HypercoreDepositInfo {
|
|
225
|
+
/** The wallet's address, which is its Hyperliquid account */
|
|
226
|
+
account: string;
|
|
227
|
+
/** The account's abstraction mode */
|
|
228
|
+
accountMode: HypercoreAccountMode;
|
|
229
|
+
/** Withdrawable USDC in the perp balance; `0n` for a unified or portfolio-margin account */
|
|
230
|
+
perpBalance: bigint;
|
|
231
|
+
/** USDC in the spot balance not on hold */
|
|
232
|
+
spotBalance: bigint;
|
|
233
|
+
/**
|
|
234
|
+
* The most one deposit can draw: a withdrawal draws on a single balance, and
|
|
235
|
+
* 0.1 USDC stays back for the fee Hyperliquid charges on top of the amount —
|
|
236
|
+
* in spot when spot can hold it, otherwise in the balance drawn
|
|
237
|
+
*/
|
|
238
|
+
available: bigint;
|
|
239
|
+
/** The most Circle deducts to forward a withdrawal to Sei, read from Circle's CoreDepositWallet on HyperEVM */
|
|
240
|
+
maxFee: bigint;
|
|
241
|
+
/** The smallest `amount` {@link SweeperAPI.depositFromHypercore} accepts: `maxFee` plus the Sei hub's USDC minimum */
|
|
242
|
+
minimumAmount: bigint;
|
|
243
|
+
}
|
|
244
|
+
/** Body for {@link SweeperAPI.depositFromHypercore}. */
|
|
245
|
+
export interface DepositFromHypercoreRequest {
|
|
246
|
+
/**
|
|
247
|
+
* USDC to withdraw from Hyperliquid, in raw base units (6 decimals). Circle
|
|
248
|
+
* deducts its forwarding fee on the way, so at least `amount - maxFee`
|
|
249
|
+
* reaches Sei, and that must clear the Sei hub's USDC `minSweepRaw` (see
|
|
250
|
+
* {@link SweeperAPI.getChains}).
|
|
251
|
+
*/
|
|
252
|
+
amount: bigint;
|
|
253
|
+
/**
|
|
254
|
+
* Which deposit address receives it, as in
|
|
255
|
+
* {@link RegisterSweeperRequest.depositTarget}. Defaults to `"spot"`.
|
|
256
|
+
*/
|
|
257
|
+
depositTarget?: DepositTarget;
|
|
258
|
+
}
|
|
259
|
+
/** Result of {@link SweeperAPI.depositFromHypercore}: Hyperliquid accepted the withdrawal. */
|
|
260
|
+
export interface DepositFromHypercoreResponse {
|
|
261
|
+
/** The deposit address on Sei the USDC is minted to */
|
|
262
|
+
sweeperAddress: string;
|
|
263
|
+
/** USDC withdrawn from Hyperliquid, raw base units */
|
|
264
|
+
amount: bigint;
|
|
265
|
+
/** The Hyperliquid balance it was drawn from */
|
|
266
|
+
source: HypercoreBalanceSource;
|
|
267
|
+
/**
|
|
268
|
+
* The most Circle deducts to forward the withdrawal to Sei, raw base units,
|
|
269
|
+
* read from Circle's CoreDepositWallet on HyperEVM before signing
|
|
270
|
+
*/
|
|
271
|
+
maxFee: bigint;
|
|
272
|
+
/** `amount - maxFee`: the least that is minted on Sei and credited */
|
|
273
|
+
minimumCredit: bigint;
|
|
274
|
+
/** The Hyperliquid action's nonce (milliseconds since the epoch) */
|
|
275
|
+
nonce: number;
|
|
276
|
+
}
|
|
277
|
+
/**
|
|
278
|
+
* What a deposit from HyperEVM can draw on, from
|
|
279
|
+
* {@link SweeperAPI.getHyperEvmDepositInfo}. USDC amounts are raw base units
|
|
280
|
+
* (6 decimals).
|
|
281
|
+
*/
|
|
282
|
+
export interface HyperEvmDepositInfo {
|
|
283
|
+
/** The wallet's address on HyperEVM */
|
|
284
|
+
account: string;
|
|
285
|
+
/** The wallet's Circle USDC on HyperEVM */
|
|
286
|
+
usdcBalance: bigint;
|
|
287
|
+
/** The wallet's HYPE on HyperEVM, in wei: it pays the approval and burn gas */
|
|
288
|
+
gasBalance: bigint;
|
|
289
|
+
/** Circle's forwarding fee to Sei, quoted from Circle's API: the most Circle keeps */
|
|
290
|
+
maxFee: bigint;
|
|
291
|
+
/** The smallest `amount` {@link SweeperAPI.depositFromHyperEvm} accepts: `maxFee` plus the Sei hub's USDC minimum */
|
|
292
|
+
minimumAmount: bigint;
|
|
293
|
+
}
|
|
294
|
+
/** Body for {@link SweeperAPI.depositFromHyperEvm}. */
|
|
295
|
+
export interface DepositFromHyperEvmRequest {
|
|
296
|
+
/**
|
|
297
|
+
* USDC to burn on HyperEVM, in raw base units (6 decimals). Circle keeps its
|
|
298
|
+
* forwarding fee, so at least `amount - maxFee` reaches Sei.
|
|
299
|
+
*/
|
|
300
|
+
amount: bigint;
|
|
301
|
+
/**
|
|
302
|
+
* Which deposit address receives it, as in
|
|
303
|
+
* {@link RegisterSweeperRequest.depositTarget}. Defaults to `"spot"`.
|
|
304
|
+
*/
|
|
305
|
+
depositTarget?: DepositTarget;
|
|
306
|
+
}
|
|
307
|
+
/** Result of {@link SweeperAPI.depositFromHyperEvm}: the burn landed on HyperEVM. */
|
|
308
|
+
export interface DepositFromHyperEvmResponse {
|
|
309
|
+
/** The deposit address on Sei the USDC is minted to */
|
|
310
|
+
sweeperAddress: string;
|
|
311
|
+
/** USDC burned on HyperEVM, raw base units */
|
|
312
|
+
amount: bigint;
|
|
313
|
+
/** The most Circle keeps to forward the transfer to Sei, raw base units */
|
|
314
|
+
maxFee: bigint;
|
|
315
|
+
/** `amount - maxFee`: the least that is minted on Sei and credited */
|
|
316
|
+
minimumCredit: bigint;
|
|
317
|
+
/** The HyperEVM approval transaction, when the allowance had to be raised */
|
|
318
|
+
approveTxHash?: string;
|
|
319
|
+
/** The HyperEVM burn transaction */
|
|
320
|
+
burnTxHash: string;
|
|
321
|
+
}
|
|
207
322
|
/**
|
|
208
323
|
* Sweeper API interface. Registration and deposit status require
|
|
209
324
|
* authentication; the chain listing is public.
|
|
@@ -266,4 +381,70 @@ export interface SweeperAPI extends BaseAPI {
|
|
|
266
381
|
* sending).
|
|
267
382
|
*/
|
|
268
383
|
listDeposits(params?: ListSweeperDepositsParams): Promise<ListSweeperDepositsResponse>;
|
|
384
|
+
/**
|
|
385
|
+
* Deposits USDC the wallet holds on Hyperliquid (HyperCore): the wallet
|
|
386
|
+
* signs Circle's CCTP withdrawal to the caller's deposit address on Sei, and
|
|
387
|
+
* the SDK posts it to Hyperliquid, which executes it. Circle forwards the
|
|
388
|
+
* mint to Sei and the sweeper credits it like any deposit to the address —
|
|
389
|
+
* it lists in {@link listDeposits} by its Sei mint once minted. No gas and
|
|
390
|
+
* no HyperEVM transaction from the user.
|
|
391
|
+
*
|
|
392
|
+
* The balance is chosen from the account itself: the spot balance for a
|
|
393
|
+
* unified or portfolio-margin account, otherwise whichever of perp (first)
|
|
394
|
+
* or spot covers `amount`.
|
|
395
|
+
*
|
|
396
|
+
* Needs a session (it registers the deposit address first) and a wallet
|
|
397
|
+
* client on Sei, whose account must be the one holding the Hyperliquid
|
|
398
|
+
* balance. Throws before signing on an invalid amount, a wallet on another
|
|
399
|
+
* chain, a failed Hyperliquid balance read, a hub that does not sweep USDC,
|
|
400
|
+
* an amount below {@link HypercoreDepositInfo.minimumAmount}, and an amount
|
|
401
|
+
* above {@link HypercoreDepositInfo.available}.
|
|
402
|
+
*
|
|
403
|
+
* Throws `APIError` when Hyperliquid refuses the action (a decided outcome:
|
|
404
|
+
* nothing moved). A lost or unreadable reply is an UNKNOWN outcome — the
|
|
405
|
+
* error carries `retryable: false`, because calling this again signs a
|
|
406
|
+
* second withdrawal. Check {@link listDeposits} or the Hyperliquid balance
|
|
407
|
+
* first.
|
|
408
|
+
*/
|
|
409
|
+
depositFromHypercore(body: DepositFromHypercoreRequest): Promise<DepositFromHypercoreResponse>;
|
|
410
|
+
/**
|
|
411
|
+
* What the wallet can deposit from Hyperliquid: its account mode and USDC
|
|
412
|
+
* balances, the most one deposit can draw, Circle's fee and the smallest
|
|
413
|
+
* accepted amount — everything a deposit form needs before the user types.
|
|
414
|
+
* Reads only public data, so it needs a wallet client on Sei but no
|
|
415
|
+
* session. A failed Hyperliquid read throws `APIError`.
|
|
416
|
+
*/
|
|
417
|
+
getHypercoreDepositInfo(): Promise<HypercoreDepositInfo>;
|
|
418
|
+
/**
|
|
419
|
+
* Deposits Circle USDC the wallet holds on HyperEVM: the wallet approves
|
|
420
|
+
* and burns it through Circle's TokenMessengerV2 on HyperEVM, naming the
|
|
421
|
+
* caller's Sei deposit address as the recipient and asking Circle to
|
|
422
|
+
* forward the mint. Circle mints on Sei and the sweeper credits it like any
|
|
423
|
+
* deposit to the address — it lists in {@link listDeposits} by its Sei mint.
|
|
424
|
+
* The wallet pays HYPE for gas; no Monaco contract is involved on HyperEVM.
|
|
425
|
+
*
|
|
426
|
+
* Needs a session (it registers the deposit address) and a wallet client
|
|
427
|
+
* on Sei. A browser or embedded wallet is switched to HyperEVM (added
|
|
428
|
+
* first if it does not know the chain) and back to Sei afterwards. Throws
|
|
429
|
+
* before registering or sending on an invalid amount, a wallet on another
|
|
430
|
+
* chain, a failed read or fee quote, a hub that does not sweep USDC, an
|
|
431
|
+
* amount below {@link HyperEvmDepositInfo.minimumAmount} or above the
|
|
432
|
+
* wallet's HyperEVM USDC, and a wallet with no HYPE.
|
|
433
|
+
*
|
|
434
|
+
* A burn that reverts throws `ContractError` (nothing burned). A burn
|
|
435
|
+
* broadcast but whose receipt cannot be read is an UNKNOWN outcome: the
|
|
436
|
+
* `APIError` carries `retryable: false` and the burn's hash, because
|
|
437
|
+
* calling this again burns a second time. Check {@link listDeposits} or the
|
|
438
|
+
* HyperEVM transaction first.
|
|
439
|
+
*/
|
|
440
|
+
depositFromHyperEvm(body: DepositFromHyperEvmRequest): Promise<DepositFromHyperEvmResponse>;
|
|
441
|
+
/**
|
|
442
|
+
* What the wallet can deposit from HyperEVM: its Circle USDC and HYPE on
|
|
443
|
+
* HyperEVM, Circle's forwarding fee and the smallest accepted amount.
|
|
444
|
+
* Reads only public data, so it needs a wallet client on Sei but no
|
|
445
|
+
* session.
|
|
446
|
+
*/
|
|
447
|
+
getHyperEvmDepositInfo(): Promise<HyperEvmDepositInfo>;
|
|
448
|
+
/** Set the wallet client that signs {@link depositFromHypercore} and {@link depositFromHyperEvm}. */
|
|
449
|
+
setWalletClient(walletClient: unknown): void;
|
|
269
450
|
}
|
package/dist/validation/rfq.d.ts
CHANGED
|
@@ -62,6 +62,11 @@ export declare const CancelRfqSchema: z.ZodObject<{
|
|
|
62
62
|
idempotencyKey: z.ZodOptional<z.ZodString>;
|
|
63
63
|
}, z.core.$strict>;
|
|
64
64
|
/** Params for placing or replacing a quote: a bid, an ask or both. */
|
|
65
|
+
/** `listRfqs` paging: 1 to 100 per page, and the previous page's token. */
|
|
66
|
+
export declare const ListRfqsSchema: z.ZodObject<{
|
|
67
|
+
pageSize: z.ZodOptional<z.ZodNumber>;
|
|
68
|
+
pageToken: z.ZodOptional<z.ZodString>;
|
|
69
|
+
}, z.core.$strict>;
|
|
65
70
|
export declare const UpsertRfqQuoteSchema: z.ZodObject<{
|
|
66
71
|
expectedVersion: z.ZodNumber;
|
|
67
72
|
bid: z.ZodOptional<z.ZodObject<{
|
package/dist/validation/rfq.js
CHANGED
|
@@ -70,6 +70,13 @@ export const CancelRfqSchema = z
|
|
|
70
70
|
})
|
|
71
71
|
.strict();
|
|
72
72
|
/** Params for placing or replacing a quote: a bid, an ask or both. */
|
|
73
|
+
/** `listRfqs` paging: 1 to 100 per page, and the previous page's token. */
|
|
74
|
+
export const ListRfqsSchema = z
|
|
75
|
+
.object({
|
|
76
|
+
pageSize: z.number().int().min(1).max(100).optional(),
|
|
77
|
+
pageToken: z.string().min(1).optional(),
|
|
78
|
+
})
|
|
79
|
+
.strict();
|
|
73
80
|
export const UpsertRfqQuoteSchema = z
|
|
74
81
|
.object({
|
|
75
82
|
/** Your current version for this RFQ (`ownLatestVersion`); 0 for your first quote. */
|
|
@@ -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 ["accept_rfq", "add_follow_position_margin", "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_all_after", "cancel_conditional_order", "cancel_order", "cancel_rfq", "cancel_twap_order", "check_trader_code_availability", "claim_buildercode_rewards", "claim_managed_market_lease", "clear_trader_code", "close_all_copy_positions", "close_follow_positions", "close_position", "close_sub_account", "create_challenge", "create_delegated_session", "create_order", "create_rfq", "create_sub_account", "create_sub_account_limit", "create_twap_order", "delete_sub_account_limit", "get_application_config", "get_application_stats", "get_available_collateral", "get_builder", "get_builder_series", "get_builder_totals", "get_buildercode_payout_summary", "get_buildercode_rewards_balance", "get_buildercodes_config", "get_candles", "get_conditional_order", "get_faucet_info", "get_fee_schedule", "get_follow", "get_funding_state", "get_index_price", "get_lead_trader", "get_liquidation_metrics", "get_margin_account_movements", "get_margin_account_pnl", "get_margin_account_summary", "get_mark_price", "get_market_metadata", "get_market_stats", "get_my_fee_tier", "get_my_lead_trader", "get_my_referral_downline", "get_my_referral_position", "get_my_referral_tree", "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_protocol_series", "get_protocol_totals", "get_pulse", "get_region_status", "get_rewards_balance", "get_rfq", "get_rfq_capabilities", "get_screener", "get_self_trade_prevention_default", "get_sub_account_limits", "get_sweeper_chains", "get_sweeper_deposit_status", "get_token_custody", "get_trade_by_id", "get_trade_flow", "get_trader_code_info", "get_trader_metrics", "get_trades", "get_trading_pair_by_id", "get_treasury_net_fees", "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_wallet_summary", "get_withdrawal", "health_check", "initiate_withdrawal", "list_all_funding_history", "list_all_liquidation_events", "list_application_balances", "list_application_movements", "list_application_orders", "list_application_users", "list_builder_fee_changes", "list_builder_leaderboard", "list_buildercode_payouts", "list_builders", "list_conditional_orders", "list_delegated_agent_owners", "list_delegated_agents", "list_follow_leader_positions", "list_funding_history", "list_funding_payments", "list_insurance_funds", "list_invite_codes", "list_lead_trader_closed_trades", "list_lead_trader_open_positions", "list_lead_traders", "list_liquidation_events", "list_managed_market_assignments", "list_margin_accounts", "list_market_volumes", "list_my_followers", "list_my_follows", "list_pending_withdrawals", "list_position_history", "list_positions", "list_sub_accounts_with_balances", "list_sweeper_deposits", "list_token_custody", "list_trades", "list_trading_pairs", "list_twap_order_slices", "list_twap_orders", "list_vault_deposits", "list_vault_withdrawals", "list_wallet_leaderboard", "list_wallet_liquidations", "mint_tokens", "preview_follow", "refresh_managed_market_quotes", "refresh_session", "register_deposit_address", "replace_order", "request_invite_codes", "respond_rfq_last_look", "revoke_delegated_agent", "revoke_session", "set_builder_fee", "set_self_trade_prevention_default", "set_trader_code", "simulate_fees", "simulate_order_risk", "simulate_parent_margin_order_risk", "simulate_risk_bucket_order_risk", "stop_follow", "transfer_collateral", "transfer_collateral_from_margin_account", "transfer_collateral_from_parent_margin_account", "transfer_collateral_from_sub_account", "transfer_collateral_to_margin_account", "transfer_collateral_to_parent_margin_account", "transfer_collateral_to_risk_bucket", "transfer_collateral_to_sub_account", "transfer_rewards", "update_sub_account_limit", "upsert_delegated_agent", "upsert_follow", "upsert_lead_trader", "upsert_rfq_quote", "verify_signature", "withdraw_rfq_quote"];
|
|
13
|
+
export declare const OPERATION_IDS: readonly ["accept_rfq", "add_follow_position_margin", "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_all_after", "cancel_conditional_order", "cancel_order", "cancel_rfq", "cancel_twap_order", "check_trader_code_availability", "claim_buildercode_rewards", "claim_managed_market_lease", "clear_trader_code", "close_all_copy_positions", "close_follow_positions", "close_position", "close_sub_account", "create_challenge", "create_delegated_session", "create_order", "create_rfq", "create_sub_account", "create_sub_account_limit", "create_twap_order", "delete_sub_account_limit", "get_application_config", "get_application_stats", "get_available_collateral", "get_builder", "get_builder_series", "get_builder_totals", "get_buildercode_payout_summary", "get_buildercode_rewards_balance", "get_buildercodes_config", "get_candles", "get_conditional_order", "get_faucet_info", "get_fee_schedule", "get_follow", "get_funding_state", "get_index_price", "get_lead_trader", "get_liquidation_metrics", "get_margin_account_movements", "get_margin_account_pnl", "get_margin_account_summary", "get_mark_price", "get_market_metadata", "get_market_stats", "get_my_fee_tier", "get_my_lead_trader", "get_my_referral_downline", "get_my_referral_position", "get_my_referral_tree", "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_protocol_series", "get_protocol_totals", "get_pulse", "get_region_status", "get_rewards_balance", "get_rfq", "get_rfq_capabilities", "get_screener", "get_self_trade_prevention_default", "get_sub_account_limits", "get_sweeper_chains", "get_sweeper_deposit_status", "get_token_custody", "get_trade_by_id", "get_trade_flow", "get_trader_code_info", "get_trader_metrics", "get_trades", "get_trading_pair_by_id", "get_treasury_net_fees", "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_wallet_summary", "get_withdrawal", "health_check", "initiate_withdrawal", "list_all_funding_history", "list_all_liquidation_events", "list_application_balances", "list_application_movements", "list_application_orders", "list_application_users", "list_builder_fee_changes", "list_builder_leaderboard", "list_buildercode_payouts", "list_builders", "list_conditional_orders", "list_delegated_agent_owners", "list_delegated_agents", "list_follow_leader_positions", "list_funding_history", "list_funding_payments", "list_insurance_funds", "list_invite_codes", "list_lead_trader_closed_trades", "list_lead_trader_open_positions", "list_lead_traders", "list_liquidation_events", "list_managed_market_assignments", "list_margin_accounts", "list_market_volumes", "list_my_followers", "list_my_follows", "list_pending_withdrawals", "list_position_history", "list_positions", "list_rfqs", "list_sub_accounts_with_balances", "list_sweeper_deposits", "list_token_custody", "list_trades", "list_trading_pairs", "list_twap_order_slices", "list_twap_orders", "list_vault_deposits", "list_vault_withdrawals", "list_wallet_leaderboard", "list_wallet_liquidations", "mint_tokens", "preview_follow", "refresh_managed_market_quotes", "refresh_session", "register_deposit_address", "replace_order", "request_invite_codes", "respond_rfq_last_look", "revoke_delegated_agent", "revoke_session", "set_builder_fee", "set_self_trade_prevention_default", "set_trader_code", "simulate_fees", "simulate_order_risk", "simulate_parent_margin_order_risk", "simulate_risk_bucket_order_risk", "stop_follow", "transfer_collateral", "transfer_collateral_from_margin_account", "transfer_collateral_from_parent_margin_account", "transfer_collateral_from_sub_account", "transfer_collateral_to_margin_account", "transfer_collateral_to_parent_margin_account", "transfer_collateral_to_risk_bucket", "transfer_collateral_to_sub_account", "transfer_rewards", "update_sub_account_limit", "upsert_delegated_agent", "upsert_follow", "upsert_lead_trader", "upsert_rfq_quote", "verify_signature", "withdraw_rfq_quote"];
|
|
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
|
@@ -1953,9 +1953,11 @@ export interface paths {
|
|
|
1953
1953
|
};
|
|
1954
1954
|
/**
|
|
1955
1955
|
* Get my fee tier and pair schedule
|
|
1956
|
-
* @description Return the caller's current fee tier, rolling 14-day volumes,
|
|
1956
|
+
* @description Return the caller's current fee tier, rolling 14-day volumes, the rates that
|
|
1957
|
+
* apply to them on a pair and why, and the pair's schedule.
|
|
1957
1958
|
*
|
|
1958
|
-
* Volumes and the tier are wallet-wide: the caller's wallet total
|
|
1959
|
+
* Volumes and the volume-earned tier are wallet-wide: the caller's wallet total
|
|
1960
|
+
* across every application.
|
|
1959
1961
|
*/
|
|
1960
1962
|
get: operations["get_my_fee_tier"];
|
|
1961
1963
|
put?: never;
|
|
@@ -2227,12 +2229,18 @@ export interface paths {
|
|
|
2227
2229
|
get?: never;
|
|
2228
2230
|
put?: never;
|
|
2229
2231
|
/**
|
|
2230
|
-
* @description Move collateral between
|
|
2231
|
-
*
|
|
2232
|
-
* account (optionally one of its risk buckets).
|
|
2233
|
-
* the
|
|
2234
|
-
*
|
|
2235
|
-
*
|
|
2232
|
+
* @description Move collateral between any two of the caller's places: the spot wallet, a
|
|
2233
|
+
* margin account, a risk bucket. `from` and `to` each name the wallet or a
|
|
2234
|
+
* margin account (optionally one of its risk buckets). A route that crosses
|
|
2235
|
+
* accounts or the wallet runs up to three moves in one step: out of the risk
|
|
2236
|
+
* bucket, across to the other account, into the destination. The wallet is
|
|
2237
|
+
* reached through the default margin account. A refused request moves nothing.
|
|
2238
|
+
* A route to or from the wallet or a risk bucket refuses a copy-trading
|
|
2239
|
+
* sub-account. If the service fails partway, the request answers
|
|
2240
|
+
* COLLATERAL_TRANSFER_STOPPED_PARTWAY (HTTP 409 / gRPC ALREADY_EXISTS) naming
|
|
2241
|
+
* the margin account that holds the amount: move it from there rather than
|
|
2242
|
+
* retrying, and re-read the wallet balance. The older transfer routes keep
|
|
2243
|
+
* working unchanged.
|
|
2236
2244
|
*/
|
|
2237
2245
|
post: operations["transfer_collateral"];
|
|
2238
2246
|
delete?: never;
|
|
@@ -3531,7 +3539,15 @@ export interface paths {
|
|
|
3531
3539
|
path?: never;
|
|
3532
3540
|
cookie?: never;
|
|
3533
3541
|
};
|
|
3534
|
-
|
|
3542
|
+
/**
|
|
3543
|
+
* List your RFQs
|
|
3544
|
+
* @description List your RFQs.
|
|
3545
|
+
*
|
|
3546
|
+
* The caller's own RFQs as the taker, newest first, in every state, those
|
|
3547
|
+
* that filled nothing included. Each carries what GetRfq gives the taker
|
|
3548
|
+
* except the live view: read GetRfq for that.
|
|
3549
|
+
*/
|
|
3550
|
+
get: operations["list_rfqs"];
|
|
3535
3551
|
put?: never;
|
|
3536
3552
|
/**
|
|
3537
3553
|
* Request quotes
|
|
@@ -5268,6 +5284,13 @@ export interface components {
|
|
|
5268
5284
|
* @example 11000
|
|
5269
5285
|
*/
|
|
5270
5286
|
netFlowUsd?: string | null;
|
|
5287
|
+
volumeBySource?: components["schemas"]["VolumeUsdBySource"];
|
|
5288
|
+
/**
|
|
5289
|
+
* Format: int64
|
|
5290
|
+
* @description Accounts registered in the window under one of the builder's applications, whether or not they traded, summed over a group's applications (newTraders counts first trades instead)
|
|
5291
|
+
* @example 12
|
|
5292
|
+
*/
|
|
5293
|
+
newAccounts?: number | null;
|
|
5271
5294
|
};
|
|
5272
5295
|
BuilderSeriesPoint: {
|
|
5273
5296
|
/**
|
|
@@ -5339,6 +5362,13 @@ export interface components {
|
|
|
5339
5362
|
* @example 11000
|
|
5340
5363
|
*/
|
|
5341
5364
|
netFlowUsd?: string | null;
|
|
5365
|
+
volumeBySource?: components["schemas"]["VolumeUsdBySource"];
|
|
5366
|
+
/**
|
|
5367
|
+
* Format: int64
|
|
5368
|
+
* @description Accounts registered in the bucket under one of the builder's applications, whether or not they traded, summed over a group's applications (newTraders counts first trades instead)
|
|
5369
|
+
* @example 2
|
|
5370
|
+
*/
|
|
5371
|
+
newAccounts?: number | null;
|
|
5342
5372
|
};
|
|
5343
5373
|
BuildercodePayout: {
|
|
5344
5374
|
/**
|
|
@@ -6637,8 +6667,8 @@ export interface components {
|
|
|
6637
6667
|
settledAt?: string | null;
|
|
6638
6668
|
/**
|
|
6639
6669
|
* @description True when the window held fewer than the minimum accepted samples and
|
|
6640
|
-
* settled at
|
|
6641
|
-
*
|
|
6670
|
+
* settled at zero instead of a freshly computed average. (Windows settled
|
|
6671
|
+
* before this rule carried the last settled rate instead.)
|
|
6642
6672
|
*/
|
|
6643
6673
|
carried?: boolean | null;
|
|
6644
6674
|
};
|
|
@@ -6877,6 +6907,13 @@ export interface components {
|
|
|
6877
6907
|
* @example 11000
|
|
6878
6908
|
*/
|
|
6879
6909
|
netFlowUsd?: string | null;
|
|
6910
|
+
volumeBySource?: components["schemas"]["VolumeUsdBySource"];
|
|
6911
|
+
/**
|
|
6912
|
+
* Format: int64
|
|
6913
|
+
* @description Accounts registered in the window under one of the builder's applications, whether or not they traded, summed over a group's applications (newTraders counts first trades instead)
|
|
6914
|
+
* @example 12
|
|
6915
|
+
*/
|
|
6916
|
+
newAccounts?: number | null;
|
|
6880
6917
|
};
|
|
6881
6918
|
GetBuildercodePayoutSummaryResponse: {
|
|
6882
6919
|
/**
|
|
@@ -7042,7 +7079,7 @@ export interface components {
|
|
|
7042
7079
|
*/
|
|
7043
7080
|
currentFundingRate?: string | null;
|
|
7044
7081
|
/**
|
|
7045
|
-
* @description Implied rate for the in-progress window. An estimate refreshed on each accepted premium sample (roughly every sample interval plus persistence lag), not a real-time stream; absent when the window has no samples. A window that ends with too few accepted samples settles at
|
|
7082
|
+
* @description Implied rate for the in-progress window. An estimate refreshed on each accepted premium sample (roughly every sample interval plus persistence lag), not a real-time stream; absent when the window has no samples. A window that ends with too few accepted samples settles at zero instead, so the settled rate can differ from this estimate
|
|
7046
7083
|
* @example 0.00012
|
|
7047
7084
|
*/
|
|
7048
7085
|
estimatedNextFundingRate?: string | null;
|
|
@@ -7387,7 +7424,7 @@ export interface components {
|
|
|
7387
7424
|
GetMyFeeTierResponse: {
|
|
7388
7425
|
/**
|
|
7389
7426
|
* Format: int32
|
|
7390
|
-
* @description Caller's
|
|
7427
|
+
* @description Caller's tier (1–6) on the requested pair: the tier their rates come from, or the tier their wallet's recorded weighted 14-day volume earns when rateSource is custom
|
|
7391
7428
|
* @example 2
|
|
7392
7429
|
*/
|
|
7393
7430
|
currentTierLevel?: number | null;
|
|
@@ -7407,18 +7444,33 @@ export interface components {
|
|
|
7407
7444
|
*/
|
|
7408
7445
|
perpVolume14d?: string | null;
|
|
7409
7446
|
/**
|
|
7410
|
-
* @description Additional weighted volume needed to reach the next tier, counted from the volume the current tier resolved from; omitted at tier 6
|
|
7447
|
+
* @description Additional weighted volume needed to reach the next tier, counted from the volume the current tier resolved from; omitted at tier 6 and unless rateSource is volume
|
|
7411
7448
|
* @example 17500000
|
|
7412
7449
|
*/
|
|
7413
7450
|
volumeToNextTier?: string | null;
|
|
7414
7451
|
/**
|
|
7415
7452
|
* Format: int32
|
|
7416
|
-
* @description Next tier level when not already at 6
|
|
7453
|
+
* @description Next tier level when not already at 6; omitted unless rateSource is volume
|
|
7417
7454
|
* @example 3
|
|
7418
7455
|
*/
|
|
7419
7456
|
nextTierLevel?: number | null;
|
|
7420
7457
|
/** @description Six-row fee schedule for the requested pair, ascending by tier */
|
|
7421
7458
|
feeSchedule?: components["schemas"]["FeeTierScheduleRow"][] | null;
|
|
7459
|
+
/**
|
|
7460
|
+
* @description Why this rate applies: volume (the tier your 14-day volume earns), tier_override (an assigned tier), or custom (custom rates assigned to your wallet). Applies to orders you place now.
|
|
7461
|
+
* @example volume
|
|
7462
|
+
*/
|
|
7463
|
+
rateSource?: string | null;
|
|
7464
|
+
/**
|
|
7465
|
+
* @description Effective maker rate for the requested pair, in decimal basis points; negative is a rebate, positive is a fee
|
|
7466
|
+
* @example -1.15
|
|
7467
|
+
*/
|
|
7468
|
+
makerFeeBps?: string | null;
|
|
7469
|
+
/**
|
|
7470
|
+
* @description Effective taker rate for the requested pair, in decimal basis points
|
|
7471
|
+
* @example 6
|
|
7472
|
+
*/
|
|
7473
|
+
takerFeeBps?: string | null;
|
|
7422
7474
|
};
|
|
7423
7475
|
GetMyReferralDownlineResponse: {
|
|
7424
7476
|
/** @description One page of rows, one per (source account, level, token) the caller earns from, across every reward level, ordered by each source account's own total, largest first. A wallet that traded through several applications has one account per application: its rows within a page are merged into one row at the position of its first (largest) part, so a merged row can sit below a smaller one, and the wallet can appear again on a later page. Paged by `pageSize` / `pageToken`; follow `nextPageToken` for the rest. Comes from the caller's maintained reward totals — no tree walk. */
|
|
@@ -8364,7 +8416,7 @@ export interface components {
|
|
|
8364
8416
|
activeTakers?: number | null;
|
|
8365
8417
|
/**
|
|
8366
8418
|
* Format: int64
|
|
8367
|
-
* @description Wallets whose first trade
|
|
8419
|
+
* @description Wallets whose first trade on the protocol fell in the window, each counted once however many builders it traded through
|
|
8368
8420
|
* @example 27
|
|
8369
8421
|
*/
|
|
8370
8422
|
newTraders?: number | null;
|
|
@@ -8399,6 +8451,13 @@ export interface components {
|
|
|
8399
8451
|
* @example 418
|
|
8400
8452
|
*/
|
|
8401
8453
|
activeAccounts?: number | null;
|
|
8454
|
+
volumeBySource?: components["schemas"]["VolumeUsdBySource"];
|
|
8455
|
+
/**
|
|
8456
|
+
* Format: int64
|
|
8457
|
+
* @description Accounts registered in the window: every account with an application, whether or not it traded, all builders included (newTraders counts first trades instead). Every sign-up counts, in buckets without trades too; window=all starts where the analytics history does.
|
|
8458
|
+
* @example 57
|
|
8459
|
+
*/
|
|
8460
|
+
newAccounts?: number | null;
|
|
8402
8461
|
};
|
|
8403
8462
|
GetPulseResponse: {
|
|
8404
8463
|
/**
|
|
@@ -9349,7 +9408,8 @@ export interface components {
|
|
|
9349
9408
|
/**
|
|
9350
9409
|
* @description Displayed builders with figures in the window, largest volume first
|
|
9351
9410
|
* (ties by builder id), up to limit. A builder that only earned maker
|
|
9352
|
-
* add-ons,
|
|
9411
|
+
* add-ons, only took deposits, or only registered accounts, ranks with zero
|
|
9412
|
+
* volume.
|
|
9353
9413
|
*/
|
|
9354
9414
|
rows?: components["schemas"]["BuilderLeaderboardRow"][] | null;
|
|
9355
9415
|
};
|
|
@@ -9692,6 +9752,12 @@ export interface components {
|
|
|
9692
9752
|
*/
|
|
9693
9753
|
totalCapped?: boolean | null;
|
|
9694
9754
|
};
|
|
9755
|
+
ListRfqsResponse: {
|
|
9756
|
+
/** @description Newest first. Each is the taker's status as GetRfq gives it, without the live view */
|
|
9757
|
+
rfqs?: components["schemas"]["RfqStatus"][] | null;
|
|
9758
|
+
/** @description Pass as pageToken for the next page; empty once there are no more */
|
|
9759
|
+
nextPageToken?: string | null;
|
|
9760
|
+
};
|
|
9695
9761
|
ListSubAccountsResponse: {
|
|
9696
9762
|
subAccounts?: components["schemas"]["SubAccount"][] | null;
|
|
9697
9763
|
/**
|
|
@@ -10057,6 +10123,7 @@ export interface components {
|
|
|
10057
10123
|
* @example 2100
|
|
10058
10124
|
*/
|
|
10059
10125
|
tradesCount?: number | null;
|
|
10126
|
+
volumeBySource?: components["schemas"]["VolumeUsdBySource"];
|
|
10060
10127
|
};
|
|
10061
10128
|
MatchResult: {
|
|
10062
10129
|
/**
|
|
@@ -11023,7 +11090,7 @@ export interface components {
|
|
|
11023
11090
|
activeTakers?: number | null;
|
|
11024
11091
|
/**
|
|
11025
11092
|
* Format: int64
|
|
11026
|
-
* @description Wallets whose first trade
|
|
11093
|
+
* @description Wallets whose first trade on the protocol fell in the bucket, each counted once however many builders it traded through
|
|
11027
11094
|
* @example 3
|
|
11028
11095
|
*/
|
|
11029
11096
|
newTraders?: number | null;
|
|
@@ -11047,6 +11114,13 @@ export interface components {
|
|
|
11047
11114
|
* @example 49000
|
|
11048
11115
|
*/
|
|
11049
11116
|
netFlowUsd?: string | null;
|
|
11117
|
+
volumeBySource?: components["schemas"]["VolumeUsdBySource"];
|
|
11118
|
+
/**
|
|
11119
|
+
* Format: int64
|
|
11120
|
+
* @description Accounts registered in the bucket: every account with an application, whether or not it traded, all builders included (newTraders counts first trades instead)
|
|
11121
|
+
* @example 4
|
|
11122
|
+
*/
|
|
11123
|
+
newAccounts?: number | null;
|
|
11050
11124
|
};
|
|
11051
11125
|
PublicHealthCheckResponse: {
|
|
11052
11126
|
/**
|
|
@@ -11972,7 +12046,7 @@ export interface components {
|
|
|
11972
12046
|
*/
|
|
11973
12047
|
openInterestNotionalAvg7d?: string | null;
|
|
11974
12048
|
/**
|
|
11975
|
-
* @description Estimated rate for the in-progress funding window, the same value as getFundingState / getPerpMarketSummary estimatedNextFundingRate (a decimal fraction per funding window). An estimate refreshed on each accepted premium sample, not a real-time stream. A window that ends with too few accepted samples settles at
|
|
12049
|
+
* @description Estimated rate for the in-progress funding window, the same value as getFundingState / getPerpMarketSummary estimatedNextFundingRate (a decimal fraction per funding window). An estimate refreshed on each accepted premium sample, not a real-time stream. A window that ends with too few accepted samples settles at zero instead, so the settled rate can differ from this estimate. Null for spot pairs and margin pairs whose current window has no samples yet
|
|
11976
12050
|
* @example 0.00012
|
|
11977
12051
|
*/
|
|
11978
12052
|
estimatedNextFundingRate?: string | null;
|
|
@@ -12089,7 +12163,7 @@ export interface components {
|
|
|
12089
12163
|
*/
|
|
12090
12164
|
monacoTakerFee?: string | null;
|
|
12091
12165
|
/**
|
|
12092
|
-
* @description Monaco maker
|
|
12166
|
+
* @description Monaco maker fee in quote token: negative is a rebate, positive is a fee
|
|
12093
12167
|
* @example -5.00
|
|
12094
12168
|
*/
|
|
12095
12169
|
monacoMakerRebate?: string | null;
|
|
@@ -12146,12 +12220,12 @@ export interface components {
|
|
|
12146
12220
|
*/
|
|
12147
12221
|
slippageToleranceBps?: number | null;
|
|
12148
12222
|
/**
|
|
12149
|
-
* @description
|
|
12223
|
+
* @description Monaco taker fee rate as a decimal basis-points string — the exact rate the ledger charges this caller, from their tier or the assigned or custom rate on their wallet (equals monaco_taker_fee / notional). Fractional, e.g. "6.5".
|
|
12150
12224
|
* @example 6.5
|
|
12151
12225
|
*/
|
|
12152
12226
|
monacoTakerFeeBpsExact?: string | null;
|
|
12153
12227
|
/**
|
|
12154
|
-
* @description
|
|
12228
|
+
* @description Monaco maker rate as a decimal basis-points string (negative is a rebate, positive is a fee) — the exact rate this caller gets, from their tier or the assigned or custom rate on their wallet. Fractional, e.g. "-1".
|
|
12155
12229
|
* @example -1
|
|
12156
12230
|
*/
|
|
12157
12231
|
monacoMakerRebateBpsExact?: string | null;
|
|
@@ -13059,6 +13133,13 @@ export interface components {
|
|
|
13059
13133
|
toMarginAccountId?: string | null;
|
|
13060
13134
|
/** @description The destination risk bucket, when the destination is one. */
|
|
13061
13135
|
toRiskBucketId?: string | null;
|
|
13136
|
+
/** @description The source risk bucket, when the source is one. */
|
|
13137
|
+
fromRiskBucketId?: string | null;
|
|
13138
|
+
/**
|
|
13139
|
+
* @description Whether funding the destination risk bucket credited its sole open
|
|
13140
|
+
* position's margin. Absent when the destination is not a risk bucket.
|
|
13141
|
+
*/
|
|
13142
|
+
positionMarginCredited?: boolean | null;
|
|
13062
13143
|
};
|
|
13063
13144
|
TransferCollateralToMarginAccountRequest: {
|
|
13064
13145
|
/** @description Parent margin account UUID that receives collateral. */
|
|
@@ -14005,6 +14086,22 @@ export interface components {
|
|
|
14005
14086
|
*/
|
|
14006
14087
|
rfqQuoteVolume?: string | null;
|
|
14007
14088
|
};
|
|
14089
|
+
/**
|
|
14090
|
+
* @description A USD volume split by how it executed (RFQ-17): the order-book part and the
|
|
14091
|
+
* RFQ part add back exactly to the volumeUsd beside it.
|
|
14092
|
+
*/
|
|
14093
|
+
VolumeUsdBySource: {
|
|
14094
|
+
/**
|
|
14095
|
+
* @description The part of volumeUsd filled on the order book: volumeUsd less rfqVolumeUsd
|
|
14096
|
+
* @example 1180000.5
|
|
14097
|
+
*/
|
|
14098
|
+
orderBookVolumeUsd?: string | null;
|
|
14099
|
+
/**
|
|
14100
|
+
* @description The part of volumeUsd filled by RFQ block trades
|
|
14101
|
+
* @example 70000
|
|
14102
|
+
*/
|
|
14103
|
+
rfqVolumeUsd?: string | null;
|
|
14104
|
+
};
|
|
14008
14105
|
/** @description A wallet's figures through one displayed builder. A display group's applications fold into one row under the group. */
|
|
14009
14106
|
WalletBuilderVolume: {
|
|
14010
14107
|
/** @description The builder the figures are reported under; applications is empty. */
|
|
@@ -22080,6 +22177,58 @@ export interface operations {
|
|
|
22080
22177
|
};
|
|
22081
22178
|
};
|
|
22082
22179
|
};
|
|
22180
|
+
list_rfqs: {
|
|
22181
|
+
parameters: {
|
|
22182
|
+
query?: {
|
|
22183
|
+
/** @description RFQs per page, 1 to 100 (default 50) */
|
|
22184
|
+
pageSize?: number;
|
|
22185
|
+
pageToken?: string;
|
|
22186
|
+
};
|
|
22187
|
+
header?: never;
|
|
22188
|
+
path?: never;
|
|
22189
|
+
cookie?: never;
|
|
22190
|
+
};
|
|
22191
|
+
requestBody?: never;
|
|
22192
|
+
responses: {
|
|
22193
|
+
/** @description OK */
|
|
22194
|
+
200: {
|
|
22195
|
+
headers: {
|
|
22196
|
+
[name: string]: unknown;
|
|
22197
|
+
};
|
|
22198
|
+
content: {
|
|
22199
|
+
"application/json": components["schemas"]["ListRfqsResponse"];
|
|
22200
|
+
};
|
|
22201
|
+
};
|
|
22202
|
+
/** @description Invalid page size or malformed page token */
|
|
22203
|
+
400: {
|
|
22204
|
+
headers: {
|
|
22205
|
+
[name: string]: unknown;
|
|
22206
|
+
};
|
|
22207
|
+
content?: never;
|
|
22208
|
+
};
|
|
22209
|
+
/** @description Authentication required */
|
|
22210
|
+
401: {
|
|
22211
|
+
headers: {
|
|
22212
|
+
[name: string]: unknown;
|
|
22213
|
+
};
|
|
22214
|
+
content?: never;
|
|
22215
|
+
};
|
|
22216
|
+
/** @description RFQ is not enabled for this account (RFQ_DISABLED) */
|
|
22217
|
+
403: {
|
|
22218
|
+
headers: {
|
|
22219
|
+
[name: string]: unknown;
|
|
22220
|
+
};
|
|
22221
|
+
content?: never;
|
|
22222
|
+
};
|
|
22223
|
+
/** @description RFQ service unavailable; retry */
|
|
22224
|
+
503: {
|
|
22225
|
+
headers: {
|
|
22226
|
+
[name: string]: unknown;
|
|
22227
|
+
};
|
|
22228
|
+
content?: never;
|
|
22229
|
+
};
|
|
22230
|
+
};
|
|
22231
|
+
};
|
|
22083
22232
|
create_rfq: {
|
|
22084
22233
|
parameters: {
|
|
22085
22234
|
query?: never;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@0xmonaco/types",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.9",
|
|
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.1.
|
|
19
|
+
"@0xmonaco/contracts": "1.1.9",
|
|
20
20
|
"zod": "^4.6.7"
|
|
21
21
|
},
|
|
22
22
|
"peerDependencies": {
|