@0xmonaco/types 1.0.85 → 1.0.87
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/applications/responses.d.ts +9 -3
- package/dist/auth/index.d.ts +1 -1
- package/dist/auth/responses.d.ts +21 -0
- package/dist/buildercodes/index.d.ts +1 -1
- package/dist/buildercodes/responses.d.ts +24 -3
- package/dist/buildercodes/responses.js +32 -4
- package/dist/fees/responses.d.ts +2 -0
- package/dist/fees/responses.js +5 -1
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/market/index.d.ts +15 -13
- package/dist/profile/index.d.ts +5 -5
- package/dist/sdk/index.d.ts +0 -8
- package/dist/trading/index.d.ts +2 -2
- package/dist/trading/responses.d.ts +1 -1
- package/dist/websocket/events/market-stats-events.d.ts +7 -6
- package/dist/websocket/events/orders-events.d.ts +11 -9
- package/dist/wire/operations.d.ts +1 -1
- package/dist/wire/operations.js +0 -10
- package/dist/wire/schema.d.ts +134 -808
- package/package.json +2 -2
- package/dist/pitpass/index.d.ts +0 -14
- package/dist/pitpass/index.js +0 -8
|
@@ -228,8 +228,10 @@ export interface ListAppBalancesResponse {
|
|
|
228
228
|
/**
|
|
229
229
|
* Aggregate volume and fee stats for an application.
|
|
230
230
|
*
|
|
231
|
-
* Stats are scoped to trades where the application's users were the taker
|
|
232
|
-
*
|
|
231
|
+
* Stats are scoped to trades where the application's users were the taker,
|
|
232
|
+
* except `applicationMakerFee` (and its share of `builderFeeTotal`), which
|
|
233
|
+
* counts trades where they were the maker. All monetary values are normalized
|
|
234
|
+
* (human-readable quote token units).
|
|
233
235
|
*/
|
|
234
236
|
export interface GetAppStatsResponse {
|
|
235
237
|
/** Total quote volume for trades where this application's users were the taker */
|
|
@@ -238,8 +240,12 @@ export interface GetAppStatsResponse {
|
|
|
238
240
|
makerFee: string;
|
|
239
241
|
/** Total taker fees collected */
|
|
240
242
|
takerFee: string;
|
|
241
|
-
/**
|
|
243
|
+
/** Builder fees this application charged its users as takers. Taker side only */
|
|
242
244
|
applicationTakerFee: string;
|
|
243
245
|
/** Total number of trades */
|
|
244
246
|
tradeCount: number;
|
|
247
|
+
/** Maker add-ons this application charged its users as makers. Absent from servers older than this field */
|
|
248
|
+
applicationMakerFee?: string;
|
|
249
|
+
/** `applicationTakerFee` plus `applicationMakerFee`. Absent from servers older than this field */
|
|
250
|
+
builderFeeTotal?: string;
|
|
245
251
|
}
|
package/dist/auth/index.d.ts
CHANGED
|
@@ -108,7 +108,7 @@ export interface AuthAPI extends BaseAPI {
|
|
|
108
108
|
*/
|
|
109
109
|
setWalletClient(walletClient: unknown): void;
|
|
110
110
|
}
|
|
111
|
-
export type { ApplicationInfo, AuthState, ChallengeResponse, SessionCredentials, SessionRefreshResponse, User, } from "./responses";
|
|
111
|
+
export type { ApplicationInfo, AuthState, ChallengeResponse, ReferralNotAppliedReason, SessionCredentials, SessionRefreshResponse, User, } from "./responses";
|
|
112
112
|
export interface InviteCodeRequestSummary {
|
|
113
113
|
mainnetVolumeUsd: string;
|
|
114
114
|
eligibleMilestones: number;
|
package/dist/auth/responses.d.ts
CHANGED
|
@@ -23,6 +23,19 @@ export interface User {
|
|
|
23
23
|
/** Username of the user */
|
|
24
24
|
username?: string;
|
|
25
25
|
}
|
|
26
|
+
/**
|
|
27
|
+
* Why a TraderCode presented on a first sign-in did not record a referral.
|
|
28
|
+
* Sign-in succeeds either way.
|
|
29
|
+
*
|
|
30
|
+
* - `REFERRAL_NOT_APPLIED_REASON_ALREADY_REFERRED`: the wallet already has a
|
|
31
|
+
* different referrer, from signing up with that referrer's code on this or
|
|
32
|
+
* another application. A wallet keeps its first referrer.
|
|
33
|
+
* - `REFERRAL_NOT_APPLIED_REASON_UNKNOWN_CODE`: the code matches no wallet and
|
|
34
|
+
* no custom handle.
|
|
35
|
+
* - `REFERRAL_NOT_APPLIED_REASON_SELF_REFERRAL`: the code is the signing
|
|
36
|
+
* wallet's own.
|
|
37
|
+
*/
|
|
38
|
+
export type ReferralNotAppliedReason = "REFERRAL_NOT_APPLIED_REASON_UNSPECIFIED" | "REFERRAL_NOT_APPLIED_REASON_ALREADY_REFERRED" | "REFERRAL_NOT_APPLIED_REASON_UNKNOWN_CODE" | "REFERRAL_NOT_APPLIED_REASON_SELF_REFERRAL";
|
|
26
39
|
/**
|
|
27
40
|
* Authentication state for the noncustodial session-key scheme.
|
|
28
41
|
*
|
|
@@ -58,6 +71,14 @@ export interface AuthState {
|
|
|
58
71
|
* the field.
|
|
59
72
|
*/
|
|
60
73
|
referralApplied?: boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Why the TraderCode presented on this sign-up did not apply, to show the
|
|
76
|
+
* user (e.g. "you already have a referrer"). Absent when it applied, when no
|
|
77
|
+
* code was presented, for a returning user of this application, and on
|
|
78
|
+
* responses from a server that predates the field. Treat an unrecognised
|
|
79
|
+
* value as a newer reason.
|
|
80
|
+
*/
|
|
81
|
+
referralNotAppliedReason?: ReferralNotAppliedReason | (string & {});
|
|
61
82
|
}
|
|
62
83
|
export interface ApplicationInfo {
|
|
63
84
|
/** Unique identifier for the application */
|
|
@@ -18,7 +18,7 @@ import type { ClaimBuildercodeRewardsParams, ClaimBuildercodeRewardsResponse, Ge
|
|
|
18
18
|
export interface BuildercodesAPI extends BaseAPI {
|
|
19
19
|
/** Read this authenticated frontend's enrollment, payout address, and live budget. */
|
|
20
20
|
getConfig(): Promise<GetBuildercodesConfigResponse>;
|
|
21
|
-
/** Set this frontend's stored builder fee in basis points. */
|
|
21
|
+
/** Set this frontend's stored builder fee and, optionally, its maker add-on, in basis points, as one change. */
|
|
22
22
|
setBuilderFee(params: SetBuilderFeeParams): Promise<SetBuilderFeeResponse>;
|
|
23
23
|
/** List this frontend's builder-fee audit log, newest first. */
|
|
24
24
|
listBuilderFeeChanges(params?: ListBuilderFeeChangesParams): Promise<ListBuilderFeeChangesResponse>;
|
|
@@ -17,17 +17,21 @@ export declare const GetBuildercodesConfigResponseSchema: z.ZodObject<{
|
|
|
17
17
|
builderFeeCapBps: z.ZodNumber;
|
|
18
18
|
changesRemaining: z.ZodNumber;
|
|
19
19
|
nextChangeAllowedAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
20
|
+
builderMakerFeeBps: z.ZodOptional<z.ZodNumber>;
|
|
20
21
|
}, z.core.$strip>;
|
|
21
|
-
/** Schema for changing this frontend's builder
|
|
22
|
+
/** Schema for changing this frontend's builder fees. */
|
|
22
23
|
export declare const SetBuilderFeeParamsSchema: z.ZodObject<{
|
|
23
24
|
bps: z.ZodNumber;
|
|
25
|
+
makerBps: z.ZodOptional<z.ZodNumber>;
|
|
24
26
|
}, z.core.$strip>;
|
|
25
|
-
/** Schema returned after setting this frontend's builder
|
|
27
|
+
/** Schema returned after setting this frontend's builder fees. */
|
|
26
28
|
export declare const SetBuilderFeeResponseSchema: z.ZodObject<{
|
|
27
29
|
builderFeeBps: z.ZodNumber;
|
|
28
30
|
previousBuilderFeeBps: z.ZodNumber;
|
|
29
31
|
changesRemaining: z.ZodNumber;
|
|
30
32
|
nextChangeAllowedAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
33
|
+
builderMakerFeeBps: z.ZodOptional<z.ZodNumber>;
|
|
34
|
+
previousBuilderMakerFeeBps: z.ZodOptional<z.ZodNumber>;
|
|
31
35
|
}, z.core.$strip>;
|
|
32
36
|
/** Builder-fee change actor exposed by the audit log. */
|
|
33
37
|
export declare const BuilderFeeActorTypeSchema: z.ZodEnum<{
|
|
@@ -44,6 +48,8 @@ export declare const BuilderFeeChangeSchema: z.ZodObject<{
|
|
|
44
48
|
oldBps: z.ZodNumber;
|
|
45
49
|
newBps: z.ZodNumber;
|
|
46
50
|
createdAt: z.ZodString;
|
|
51
|
+
oldMakerBps: z.ZodOptional<z.ZodNumber>;
|
|
52
|
+
newMakerBps: z.ZodOptional<z.ZodNumber>;
|
|
47
53
|
}, z.core.$strip>;
|
|
48
54
|
/** Cursor pagination accepted by the builder-fee change log. */
|
|
49
55
|
export declare const ListBuilderFeeChangesParamsSchema: z.ZodObject<{
|
|
@@ -61,16 +67,20 @@ export declare const ListBuilderFeeChangesResponseSchema: z.ZodObject<{
|
|
|
61
67
|
oldBps: z.ZodNumber;
|
|
62
68
|
newBps: z.ZodNumber;
|
|
63
69
|
createdAt: z.ZodString;
|
|
70
|
+
oldMakerBps: z.ZodOptional<z.ZodNumber>;
|
|
71
|
+
newMakerBps: z.ZodOptional<z.ZodNumber>;
|
|
64
72
|
}, z.core.$strip>>;
|
|
65
73
|
nextPageToken: z.ZodString;
|
|
66
74
|
}, z.core.$strip>;
|
|
67
75
|
/**
|
|
68
76
|
* The payout stream a BuilderCodes credit belongs to. `REVENUE_SHARE` records
|
|
69
|
-
* Monaco revenue share; `BUILDER_FEE` records builder fees charged to takers
|
|
77
|
+
* Monaco revenue share; `BUILDER_FEE` records builder fees charged to takers;
|
|
78
|
+
* `BUILDER_MAKER_FEE` records maker add-ons charged to makers.
|
|
70
79
|
*/
|
|
71
80
|
export declare const BuildercodePayoutKindSchema: z.ZodEnum<{
|
|
72
81
|
REVENUE_SHARE: "REVENUE_SHARE";
|
|
73
82
|
BUILDER_FEE: "BUILDER_FEE";
|
|
83
|
+
BUILDER_MAKER_FEE: "BUILDER_MAKER_FEE";
|
|
74
84
|
}>;
|
|
75
85
|
/**
|
|
76
86
|
* Pagination and filter accepted by the per-trade payout history endpoint.
|
|
@@ -86,6 +96,7 @@ export declare const ListBuildercodePayoutsParamsSchema: z.ZodObject<{
|
|
|
86
96
|
kind: z.ZodOptional<z.ZodEnum<{
|
|
87
97
|
REVENUE_SHARE: "REVENUE_SHARE";
|
|
88
98
|
BUILDER_FEE: "BUILDER_FEE";
|
|
99
|
+
BUILDER_MAKER_FEE: "BUILDER_MAKER_FEE";
|
|
89
100
|
}>>;
|
|
90
101
|
}, z.core.$strip>;
|
|
91
102
|
/** One per-trade BuilderCodes credit. Amounts are RAW atomic units. */
|
|
@@ -99,6 +110,7 @@ export declare const BuildercodePayoutSchema: z.ZodObject<{
|
|
|
99
110
|
kind: z.ZodOptional<z.ZodEnum<{
|
|
100
111
|
REVENUE_SHARE: "REVENUE_SHARE";
|
|
101
112
|
BUILDER_FEE: "BUILDER_FEE";
|
|
113
|
+
BUILDER_MAKER_FEE: "BUILDER_MAKER_FEE";
|
|
102
114
|
}>>;
|
|
103
115
|
}, z.core.$strip>;
|
|
104
116
|
/** Schema for the paginated per-trade payout history. */
|
|
@@ -113,6 +125,7 @@ export declare const ListBuildercodePayoutsResponseSchema: z.ZodObject<{
|
|
|
113
125
|
kind: z.ZodOptional<z.ZodEnum<{
|
|
114
126
|
REVENUE_SHARE: "REVENUE_SHARE";
|
|
115
127
|
BUILDER_FEE: "BUILDER_FEE";
|
|
128
|
+
BUILDER_MAKER_FEE: "BUILDER_MAKER_FEE";
|
|
116
129
|
}>>;
|
|
117
130
|
}, z.core.$strip>>;
|
|
118
131
|
total: z.ZodNumber;
|
|
@@ -133,6 +146,7 @@ export declare const BuildercodePayoutTokenKindTotalSchema: z.ZodObject<{
|
|
|
133
146
|
kind: z.ZodEnum<{
|
|
134
147
|
REVENUE_SHARE: "REVENUE_SHARE";
|
|
135
148
|
BUILDER_FEE: "BUILDER_FEE";
|
|
149
|
+
BUILDER_MAKER_FEE: "BUILDER_MAKER_FEE";
|
|
136
150
|
}>;
|
|
137
151
|
totalAmount: z.ZodString;
|
|
138
152
|
payoutCount: z.ZodNumber;
|
|
@@ -153,11 +167,18 @@ export declare const GetBuildercodePayoutSummaryResponseSchema: z.ZodObject<{
|
|
|
153
167
|
kind: z.ZodEnum<{
|
|
154
168
|
REVENUE_SHARE: "REVENUE_SHARE";
|
|
155
169
|
BUILDER_FEE: "BUILDER_FEE";
|
|
170
|
+
BUILDER_MAKER_FEE: "BUILDER_MAKER_FEE";
|
|
156
171
|
}>;
|
|
157
172
|
totalAmount: z.ZodString;
|
|
158
173
|
payoutCount: z.ZodNumber;
|
|
159
174
|
lastCreditedAt: z.ZodString;
|
|
160
175
|
}, z.core.$strip>>>;
|
|
176
|
+
builderFeeByToken: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
177
|
+
token: z.ZodString;
|
|
178
|
+
totalAmount: z.ZodString;
|
|
179
|
+
payoutCount: z.ZodNumber;
|
|
180
|
+
lastCreditedAt: z.ZodString;
|
|
181
|
+
}, z.core.$strip>>>;
|
|
161
182
|
}, z.core.$strip>;
|
|
162
183
|
/** One available balance in the reserved BuilderCodes reward bucket. */
|
|
163
184
|
export declare const BuildercodeRewardsBalanceSchema: z.ZodObject<{
|
|
@@ -21,17 +21,35 @@ export const GetBuildercodesConfigResponseSchema = z.object({
|
|
|
21
21
|
builderFeeCapBps: z.number().int().min(0).max(100),
|
|
22
22
|
changesRemaining: z.number().int().min(0).max(2),
|
|
23
23
|
nextChangeAllowedAt: z.string().nullable().optional(),
|
|
24
|
+
/**
|
|
25
|
+
* The stored maker add-on in basis points: the additional fee this frontend
|
|
26
|
+
* charges its users when their order fills as the maker. Shares
|
|
27
|
+
* `builderFeeCapBps` and the switches with the taker fee. Absent from servers
|
|
28
|
+
* older than this field.
|
|
29
|
+
*/
|
|
30
|
+
builderMakerFeeBps: z.number().int().min(0).max(100).optional(),
|
|
24
31
|
});
|
|
25
|
-
/** Schema for changing this frontend's builder
|
|
32
|
+
/** Schema for changing this frontend's builder fees. */
|
|
26
33
|
export const SetBuilderFeeParamsSchema = z.object({
|
|
34
|
+
/** The taker builder fee in basis points. Required; `0` stops charging one. */
|
|
27
35
|
bps: z.number().int().min(0).max(100),
|
|
36
|
+
/**
|
|
37
|
+
* The maker add-on in basis points. Omit to leave it unchanged; `0` stops
|
|
38
|
+
* charging one. Applies to orders placed shortly after it is saved, never to
|
|
39
|
+
* an order already resting. One call that sets both sides is one change.
|
|
40
|
+
*/
|
|
41
|
+
makerBps: z.number().int().min(0).max(100).optional(),
|
|
28
42
|
});
|
|
29
|
-
/** Schema returned after setting this frontend's builder
|
|
43
|
+
/** Schema returned after setting this frontend's builder fees. */
|
|
30
44
|
export const SetBuilderFeeResponseSchema = z.object({
|
|
31
45
|
builderFeeBps: z.number().int().min(0).max(100),
|
|
32
46
|
previousBuilderFeeBps: z.number().int().min(0).max(100),
|
|
33
47
|
changesRemaining: z.number().int().min(0).max(2),
|
|
34
48
|
nextChangeAllowedAt: z.string().nullable().optional(),
|
|
49
|
+
/** The maker add-on now stored. Absent from servers older than this field. */
|
|
50
|
+
builderMakerFeeBps: z.number().int().min(0).max(100).optional(),
|
|
51
|
+
/** The maker add-on this change replaced. Absent from servers older than this field. */
|
|
52
|
+
previousBuilderMakerFeeBps: z.number().int().min(0).max(100).optional(),
|
|
35
53
|
});
|
|
36
54
|
/** Builder-fee change actor exposed by the audit log. */
|
|
37
55
|
export const BuilderFeeActorTypeSchema = z.enum(["BUILDER", "ADMIN"]);
|
|
@@ -42,6 +60,10 @@ export const BuilderFeeChangeSchema = z.object({
|
|
|
42
60
|
oldBps: z.number().int().min(0).max(100),
|
|
43
61
|
newBps: z.number().int().min(0).max(100),
|
|
44
62
|
createdAt: z.string(),
|
|
63
|
+
/** The maker add-on before the change. Absent from servers older than this field. */
|
|
64
|
+
oldMakerBps: z.number().int().min(0).max(100).optional(),
|
|
65
|
+
/** The maker add-on after the change. Absent from servers older than this field. */
|
|
66
|
+
newMakerBps: z.number().int().min(0).max(100).optional(),
|
|
45
67
|
});
|
|
46
68
|
/** Cursor pagination accepted by the builder-fee change log. */
|
|
47
69
|
export const ListBuilderFeeChangesParamsSchema = z.object({
|
|
@@ -55,9 +77,10 @@ export const ListBuilderFeeChangesResponseSchema = z.object({
|
|
|
55
77
|
});
|
|
56
78
|
/**
|
|
57
79
|
* The payout stream a BuilderCodes credit belongs to. `REVENUE_SHARE` records
|
|
58
|
-
* Monaco revenue share; `BUILDER_FEE` records builder fees charged to takers
|
|
80
|
+
* Monaco revenue share; `BUILDER_FEE` records builder fees charged to takers;
|
|
81
|
+
* `BUILDER_MAKER_FEE` records maker add-ons charged to makers.
|
|
59
82
|
*/
|
|
60
|
-
export const BuildercodePayoutKindSchema = z.enum(["REVENUE_SHARE", "BUILDER_FEE"]);
|
|
83
|
+
export const BuildercodePayoutKindSchema = z.enum(["REVENUE_SHARE", "BUILDER_FEE", "BUILDER_MAKER_FEE"]);
|
|
61
84
|
/**
|
|
62
85
|
* Pagination and filter accepted by the per-trade payout history endpoint.
|
|
63
86
|
*
|
|
@@ -130,6 +153,11 @@ export const GetBuildercodePayoutSummaryResponseSchema = z.object({
|
|
|
130
153
|
* `byToken` total. Absent from servers older than this field.
|
|
131
154
|
*/
|
|
132
155
|
byTokenAndKind: z.array(BuildercodePayoutTokenKindTotalSchema).optional(),
|
|
156
|
+
/**
|
|
157
|
+
* Per-token builder-fee totals: `BUILDER_FEE` plus `BUILDER_MAKER_FEE`,
|
|
158
|
+
* without the revenue share. Absent from servers older than this field.
|
|
159
|
+
*/
|
|
160
|
+
builderFeeByToken: z.array(BuildercodePayoutTokenTotalSchema).optional(),
|
|
133
161
|
});
|
|
134
162
|
/** One available balance in the reserved BuilderCodes reward bucket. */
|
|
135
163
|
export const BuildercodeRewardsBalanceSchema = z.object({
|
package/dist/fees/responses.d.ts
CHANGED
|
@@ -31,6 +31,8 @@ export declare const SimulateFeeResponseSchema: z.ZodObject<{
|
|
|
31
31
|
applicationTakerFeeBps: z.ZodNumber;
|
|
32
32
|
buyOrderLockAmount: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
33
33
|
makerTotalReceipt: z.ZodString;
|
|
34
|
+
applicationMakerFee: z.ZodOptional<z.ZodString>;
|
|
35
|
+
applicationMakerFeeBps: z.ZodOptional<z.ZodNumber>;
|
|
34
36
|
monacoMakerRebate: z.ZodString;
|
|
35
37
|
monacoMakerRebateBps: z.ZodNumber;
|
|
36
38
|
monacoMakerRebateBpsExact: z.ZodString;
|
package/dist/fees/responses.js
CHANGED
|
@@ -61,8 +61,12 @@ export const SimulateFeeResponseSchema = z.object({
|
|
|
61
61
|
applicationTakerFeeBps: z.number(),
|
|
62
62
|
/** Amount to lock for BUY orders (null for `SELL`) */
|
|
63
63
|
buyOrderLockAmount: z.string().nullable().optional(),
|
|
64
|
-
/** Total amount maker
|
|
64
|
+
/** Total amount received if the order fills as the maker: notional minus the maker fee (a rebate adds) minus `applicationMakerFee` */
|
|
65
65
|
makerTotalReceipt: z.string(),
|
|
66
|
+
/** Frontend maker add-on if the order fills as the maker. Absent from servers older than this field */
|
|
67
|
+
applicationMakerFee: z.string().optional(),
|
|
68
|
+
/** Maker add-on rate in basis points an order placed now would store. Absent from servers older than this field */
|
|
69
|
+
applicationMakerFeeBps: z.number().optional(),
|
|
66
70
|
/** Monaco protocol maker rebate (negative = rebate) */
|
|
67
71
|
monacoMakerRebate: z.string(),
|
|
68
72
|
/**
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
package/dist/market/index.d.ts
CHANGED
|
@@ -201,7 +201,7 @@ export interface ScreenerSnapshotPoint {
|
|
|
201
201
|
quoteVolume: string;
|
|
202
202
|
/** Percent price change (close - open) / open * 100 for the day */
|
|
203
203
|
priceChangePercent: string;
|
|
204
|
-
/** Daily average of the valued completed-UTC-minute
|
|
204
|
+
/** Daily average of the valued completed-UTC-minute one-sided LONG open-interest notionals; null for spot or when fewer than 95% of the day's 1440 minutes (1368) are valued */
|
|
205
205
|
openInterestNotionalAvg: string | null;
|
|
206
206
|
}
|
|
207
207
|
/**
|
|
@@ -252,22 +252,24 @@ export interface ScreenerItem {
|
|
|
252
252
|
*/
|
|
253
253
|
lastFundingTime: string | null;
|
|
254
254
|
/**
|
|
255
|
-
*
|
|
256
|
-
*
|
|
255
|
+
* One-sided LONG open interest (each contract counted once) in base-asset units
|
|
256
|
+
* (e.g. BTC), from the latest completed-minute sample; null for spot pairs or
|
|
257
|
+
* when no sample was recorded in the last five minutes, "0" for a margin pair with no
|
|
258
|
+
* open positions
|
|
257
259
|
*/
|
|
258
260
|
openInterestBase: string | null;
|
|
259
261
|
/**
|
|
260
|
-
*
|
|
262
|
+
* One-sided LONG open-interest notional in quote units
|
|
261
263
|
* (openInterestBase × latest trade price); null for spot pairs. Valued at the pair's latest trade price (a
|
|
262
264
|
* snapshot); the mark-accurate notional lives on getPerpMarketSummary /
|
|
263
265
|
* getOpenInterest
|
|
264
266
|
*/
|
|
265
267
|
openInterestNotional: string | null;
|
|
266
|
-
/** Average of the valued completed-UTC-minute
|
|
268
|
+
/** Average of the valued completed-UTC-minute one-sided LONG open-interest notionals over the last 60 minutes; null for spot or when fewer than 95% of them (57) are valued */
|
|
267
269
|
openInterestNotionalAvg1h: string | null;
|
|
268
|
-
/** Average of the valued completed-UTC-minute
|
|
270
|
+
/** Average of the valued completed-UTC-minute one-sided LONG open-interest notionals over the last 1440 minutes; null for spot or when fewer than 95% of them (1368) are valued */
|
|
269
271
|
openInterestNotionalAvg24h: string | null;
|
|
270
|
-
/** Average of the valued completed-UTC-minute
|
|
272
|
+
/** Average of the valued completed-UTC-minute one-sided LONG open-interest notionals over the last 10080 minutes; null for spot or when fewer than 95% of them (9576) are valued */
|
|
271
273
|
openInterestNotionalAvg7d: string | null;
|
|
272
274
|
/**
|
|
273
275
|
* Estimated rate for the in-progress funding window (decimal fraction per
|
|
@@ -436,11 +438,11 @@ export interface PerpMarketSummary {
|
|
|
436
438
|
quoteVolume24h?: string;
|
|
437
439
|
priceChange24h?: string;
|
|
438
440
|
priceChangePercent24h?: string;
|
|
439
|
-
/**
|
|
441
|
+
/** One-sided LONG open interest (each contract counted once) in base-asset units (legacy alias of openInterestBase) */
|
|
440
442
|
openInterest: string;
|
|
441
|
-
/**
|
|
443
|
+
/** One-sided LONG open interest (each contract counted once) in base-asset units (e.g. BTC) */
|
|
442
444
|
openInterestBase?: string;
|
|
443
|
-
/**
|
|
445
|
+
/** One-sided LONG open-interest notional in quote units (openInterestBase × mark price, falling back to the last trade price when no mark is available) */
|
|
444
446
|
openInterestNotional?: string;
|
|
445
447
|
currentFundingRate?: string;
|
|
446
448
|
estimatedNextFundingRate?: string;
|
|
@@ -595,11 +597,11 @@ export interface ListAllFundingHistoryResponse {
|
|
|
595
597
|
}
|
|
596
598
|
export interface OpenInterest {
|
|
597
599
|
tradingPairId: string;
|
|
598
|
-
/**
|
|
600
|
+
/** One-sided LONG open interest (each contract counted once) in base-asset units (legacy alias of openInterestBase) */
|
|
599
601
|
openInterest?: string;
|
|
600
|
-
/**
|
|
602
|
+
/** One-sided LONG open interest (each contract counted once) in base-asset units */
|
|
601
603
|
openInterestBase: string;
|
|
602
|
-
/**
|
|
604
|
+
/** One-sided LONG open-interest notional in quote units (openInterestBase × mark price, falling back to the last trade price when no mark is available) */
|
|
603
605
|
openInterestNotional: string;
|
|
604
606
|
updatedAt: string;
|
|
605
607
|
}
|
package/dist/profile/index.d.ts
CHANGED
|
@@ -287,16 +287,16 @@ export interface UserTrade {
|
|
|
287
287
|
/**
|
|
288
288
|
* Total fee paid for this trade (as string to preserve precision). For a
|
|
289
289
|
* taker this is Monaco's taker fee plus the frontend's builder fee; for a
|
|
290
|
-
* maker it is the maker fee (negative for a rebate)
|
|
291
|
-
* `monacoFee + builderFee`.
|
|
290
|
+
* maker it is the maker fee (negative for a rebate) plus the frontend's
|
|
291
|
+
* maker add-on. Equals `monacoFee + builderFee`.
|
|
292
292
|
*/
|
|
293
293
|
fee: string;
|
|
294
294
|
/** Monaco's component of `fee`. Absent from servers older than this field. */
|
|
295
295
|
monacoFee?: string;
|
|
296
296
|
/**
|
|
297
|
-
* The frontend's builder fee component of `fee
|
|
298
|
-
*
|
|
299
|
-
*
|
|
297
|
+
* The frontend's builder fee component of `fee`: the builder fee for a
|
|
298
|
+
* taker, the maker add-on for a maker. Absent from servers older than this
|
|
299
|
+
* field.
|
|
300
300
|
*/
|
|
301
301
|
builderFee?: string;
|
|
302
302
|
/** Timestamp when the trade was executed (ISO string) */
|
package/dist/sdk/index.d.ts
CHANGED
|
@@ -9,7 +9,6 @@ import type { FeesAPI } from "../fees";
|
|
|
9
9
|
import type { ManagedMarketsAPI } from "../managed-markets";
|
|
10
10
|
import type { MarginAccountsAPI } from "../margin-accounts";
|
|
11
11
|
import type { MarketAPI } from "../market";
|
|
12
|
-
import type { PitpassAPI } from "../pitpass";
|
|
13
12
|
import type { PortfolioAPI } from "../portfolio";
|
|
14
13
|
import type { PositionsAPI } from "../positions";
|
|
15
14
|
import type { ProfileAPI } from "../profile";
|
|
@@ -115,13 +114,6 @@ export interface MonacoSDK {
|
|
|
115
114
|
subAccounts: SubAccountsAPI;
|
|
116
115
|
/** TraderCodes referral and rewards API */
|
|
117
116
|
tradercodes: TraderCodesAPI;
|
|
118
|
-
/**
|
|
119
|
-
* TraderCodes referral and rewards API under its original name: the same
|
|
120
|
-
* instance as {@link tradercodes}.
|
|
121
|
-
*
|
|
122
|
-
* @deprecated Use `tradercodes`. Removed after at least two SDK releases.
|
|
123
|
-
*/
|
|
124
|
-
pitpass: PitpassAPI;
|
|
125
117
|
/** BuilderCodes frontend revenue-share payout API */
|
|
126
118
|
buildercodes: BuildercodesAPI;
|
|
127
119
|
/** Copy trading API: lead trader profiles and the leaderboard, and your follows */
|
package/dist/trading/index.d.ts
CHANGED
|
@@ -71,7 +71,7 @@ export interface TradingAPI extends BaseAPI {
|
|
|
71
71
|
* replacement re-states it and inherits nothing from the original order.
|
|
72
72
|
*/
|
|
73
73
|
clientOrderId?: string;
|
|
74
|
-
/** The SDK generates a key once per call when omitted. Supply the same key to retry a logical order within
|
|
74
|
+
/** The SDK generates a key once per call when omitted. Supply the same key to retry a logical order within 15 minutes. */
|
|
75
75
|
idempotencyKey?: string;
|
|
76
76
|
takeProfit?: ParentTpSlLegParams;
|
|
77
77
|
stopLoss?: ParentTpSlLegParams;
|
|
@@ -126,7 +126,7 @@ export interface TradingAPI extends BaseAPI {
|
|
|
126
126
|
* replacement re-states it and inherits nothing from the original order.
|
|
127
127
|
*/
|
|
128
128
|
clientOrderId?: string;
|
|
129
|
-
/** The SDK generates a key once per call when omitted. Supply the same key to retry a logical order within
|
|
129
|
+
/** The SDK generates a key once per call when omitted. Supply the same key to retry a logical order within 15 minutes. */
|
|
130
130
|
idempotencyKey?: string;
|
|
131
131
|
takeProfit?: ParentTpSlLegParams;
|
|
132
132
|
stopLoss?: ParentTpSlLegParams;
|
|
@@ -425,7 +425,7 @@ export interface BatchCreateOrderParams {
|
|
|
425
425
|
* execute a second time.
|
|
426
426
|
*/
|
|
427
427
|
clientOrderId?: string;
|
|
428
|
-
/** The SDK generates a key once per item when omitted. Supply the same key for batch or single-create retries within
|
|
428
|
+
/** The SDK generates a key once per item when omitted. Supply the same key for batch or single-create retries within 15 minutes. */
|
|
429
429
|
idempotencyKey?: string;
|
|
430
430
|
}
|
|
431
431
|
/**
|
|
@@ -45,7 +45,8 @@ export interface MarketStatsData {
|
|
|
45
45
|
/** Best ask price (decimal string) */
|
|
46
46
|
bestAskPrice?: string;
|
|
47
47
|
/**
|
|
48
|
-
*
|
|
48
|
+
* One-sided LONG open interest (each contract counted once) in base
|
|
49
|
+
* units (decimal string).
|
|
49
50
|
* Perp-only; omitted for spot, and omitted (never zero) until the market's
|
|
50
51
|
* open interest is known.
|
|
51
52
|
*/
|
|
@@ -58,8 +59,8 @@ export interface MarketStatsData {
|
|
|
58
59
|
openInterestLimit?: string;
|
|
59
60
|
/**
|
|
60
61
|
* What is left of `openInterestLimit` at the mark, in quote (USD) notional,
|
|
61
|
-
* never below zero (decimal string): the cap minus the gross
|
|
62
|
-
* × `markPrice`. At zero, orders that open exposure are refused until open
|
|
62
|
+
* never below zero (decimal string): the cap minus the gross open interest
|
|
63
|
+
* (longs plus shorts, not derivable from `openInterest`) × `markPrice`. At zero, orders that open exposure are refused until open
|
|
63
64
|
* interest or the mark falls. Perp-only; omitted for spot, when there is no
|
|
64
65
|
* mark, and until open interest is known.
|
|
65
66
|
*/
|
|
@@ -147,7 +148,8 @@ export interface MarketStatsSummary {
|
|
|
147
148
|
/** 24h low price (decimal string) */
|
|
148
149
|
dailyPriceLow?: string;
|
|
149
150
|
/**
|
|
150
|
-
*
|
|
151
|
+
* One-sided LONG open interest (each contract counted once) in base
|
|
152
|
+
* units (decimal string).
|
|
151
153
|
* Perp-only; omitted for spot, and omitted (never zero) until the market's
|
|
152
154
|
* open interest is known.
|
|
153
155
|
*/
|
|
@@ -169,8 +171,7 @@ export interface MarketStatsSummary {
|
|
|
169
171
|
/** Funding premium (decimal string). Perp-only; omitted for spot. */
|
|
170
172
|
premium?: string;
|
|
171
173
|
/**
|
|
172
|
-
*
|
|
173
|
-
* string): `openInterest` priced at the mark, falling back to the last trade
|
|
174
|
+
* One-sided LONG open interest in quote notional (decimal string): `openInterest` priced at the mark, falling back to the last trade
|
|
174
175
|
* price. Perp-only; omitted for spot,
|
|
175
176
|
* and omitted (never zero) until both open interest and a price are known.
|
|
176
177
|
*/
|
|
@@ -288,7 +288,7 @@ export interface OrderMatchedEvent extends OrderEvent {
|
|
|
288
288
|
* units (negative = maker rebate): `monacoFee + builderFee`. For a taker
|
|
289
289
|
* this is Monaco's taker fee plus the frontend's builder fee, the same
|
|
290
290
|
* total as the order echo's `totalTakerFees`; for a maker it is the maker
|
|
291
|
-
* fee. Wire: `fee`.
|
|
291
|
+
* fee plus the frontend's maker add-on. Wire: `fee`.
|
|
292
292
|
*/
|
|
293
293
|
fee: string;
|
|
294
294
|
/**
|
|
@@ -307,8 +307,8 @@ export interface OrderMatchedEvent extends OrderEvent {
|
|
|
307
307
|
monacoFeeRaw?: string;
|
|
308
308
|
/**
|
|
309
309
|
* The frontend's builder fee component of `fee`, in normalized decimal
|
|
310
|
-
* QUOTE units
|
|
311
|
-
*
|
|
310
|
+
* QUOTE units: the builder fee for a taker, the maker add-on for a maker.
|
|
311
|
+
* Optional because a server older than this field omits it.
|
|
312
312
|
* Wire: `builder_fee`.
|
|
313
313
|
*/
|
|
314
314
|
builderFee?: string;
|
|
@@ -409,7 +409,7 @@ export interface OrderPartiallyFilledEvent extends OrderEvent {
|
|
|
409
409
|
*
|
|
410
410
|
* For a taker this is Monaco's taker fee plus the frontend's builder fee,
|
|
411
411
|
* the same total as the order echo's `totalTakerFees`; for a maker it is
|
|
412
|
-
* the maker fee. It previously held the raw integer value now exposed as
|
|
412
|
+
* the maker fee plus the frontend's maker add-on. It previously held the raw integer value now exposed as
|
|
413
413
|
* `feeRaw`, and before that Monaco's fee alone.
|
|
414
414
|
*/
|
|
415
415
|
fee?: string;
|
|
@@ -426,8 +426,9 @@ export interface OrderPartiallyFilledEvent extends OrderEvent {
|
|
|
426
426
|
monacoFeeRaw?: string;
|
|
427
427
|
/**
|
|
428
428
|
* The frontend's builder fee component of `fee`, in normalized decimal
|
|
429
|
-
* QUOTE units
|
|
430
|
-
*
|
|
429
|
+
* QUOTE units: the builder fee for a taker, the maker add-on (charged at
|
|
430
|
+
* the rate the order stored when it was placed) for a maker. Wire:
|
|
431
|
+
* `builder_fee`.
|
|
431
432
|
*/
|
|
432
433
|
builderFee?: string;
|
|
433
434
|
/** `builderFee` in RAW quote-unit precision. Wire: `builder_fee_raw`. */
|
|
@@ -507,7 +508,7 @@ export interface OrderFilledEvent extends OrderEvent {
|
|
|
507
508
|
*
|
|
508
509
|
* For a taker this is Monaco's taker fee plus the frontend's builder fee,
|
|
509
510
|
* the same total as the order echo's `totalTakerFees`; for a maker it is
|
|
510
|
-
* the maker fee. It previously held the raw integer value now exposed as
|
|
511
|
+
* the maker fee plus the frontend's maker add-on. It previously held the raw integer value now exposed as
|
|
511
512
|
* `feeRaw`, and before that Monaco's fee alone.
|
|
512
513
|
*/
|
|
513
514
|
fee?: string;
|
|
@@ -524,8 +525,9 @@ export interface OrderFilledEvent extends OrderEvent {
|
|
|
524
525
|
monacoFeeRaw?: string;
|
|
525
526
|
/**
|
|
526
527
|
* The frontend's builder fee component of `fee`, in normalized decimal
|
|
527
|
-
* QUOTE units
|
|
528
|
-
*
|
|
528
|
+
* QUOTE units: the builder fee for a taker, the maker add-on (charged at
|
|
529
|
+
* the rate the order stored when it was placed) for a maker. Wire:
|
|
530
|
+
* `builder_fee`.
|
|
529
531
|
*/
|
|
530
532
|
builderFee?: string;
|
|
531
533
|
/** `builderFee` in RAW quote-unit precision. Wire: `builder_fee_raw`. */
|
|
@@ -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 ["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_conditional_order", "cancel_order", "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_sub_account", "create_sub_account_limit", "create_twap_order", "delete_sub_account_limit", "get_application_config", "get_application_stats", "get_available_collateral", "get_buildercode_payout_summary", "get_buildercode_rewards_balance", "get_buildercodes_config", "get_candles", "get_conditional_order", "get_faucet_info", "get_follow", "get_funding_state", "get_index_price", "get_lead_trader", "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_pulse", "get_rewards_balance", "get_screener", "get_self_trade_prevention_default", "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_builder_fee_changes", "list_buildercode_payouts", "list_conditional_orders", "list_delegated_agent_owners", "list_delegated_agents", "list_follow_leader_positions", "list_funding_history", "list_funding_payments", "list_invite_codes", "list_lead_trader_closed_trades", "list_lead_trader_open_positions", "list_lead_traders", "list_managed_market_assignments", "list_margin_accounts", "list_my_followers", "list_my_follows", "list_pending_withdrawals", "list_position_history", "list_positions", "list_sub_accounts_with_balances", "list_trading_pairs", "list_twap_order_slices", "list_twap_orders", "mint_tokens", "
|
|
13
|
+
export declare const OPERATION_IDS: readonly ["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_conditional_order", "cancel_order", "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_sub_account", "create_sub_account_limit", "create_twap_order", "delete_sub_account_limit", "get_application_config", "get_application_stats", "get_available_collateral", "get_buildercode_payout_summary", "get_buildercode_rewards_balance", "get_buildercodes_config", "get_candles", "get_conditional_order", "get_faucet_info", "get_follow", "get_funding_state", "get_index_price", "get_lead_trader", "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_pulse", "get_rewards_balance", "get_screener", "get_self_trade_prevention_default", "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_builder_fee_changes", "list_buildercode_payouts", "list_conditional_orders", "list_delegated_agent_owners", "list_delegated_agents", "list_follow_leader_positions", "list_funding_history", "list_funding_payments", "list_invite_codes", "list_lead_trader_closed_trades", "list_lead_trader_open_positions", "list_lead_traders", "list_managed_market_assignments", "list_margin_accounts", "list_my_followers", "list_my_follows", "list_pending_withdrawals", "list_position_history", "list_positions", "list_sub_accounts_with_balances", "list_trading_pairs", "list_twap_order_slices", "list_twap_orders", "mint_tokens", "preview_follow", "refresh_managed_market_quotes", "refresh_session", "register_deposit_address", "replace_order", "request_invite_codes", "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", "submit_whitelist", "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", "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
|
@@ -129,16 +129,6 @@ export const OPERATION_IDS = [
|
|
|
129
129
|
"list_twap_order_slices",
|
|
130
130
|
"list_twap_orders",
|
|
131
131
|
"mint_tokens",
|
|
132
|
-
"pitpass_check_trader_code_availability",
|
|
133
|
-
"pitpass_clear_trader_code",
|
|
134
|
-
"pitpass_get_my_referral_downline",
|
|
135
|
-
"pitpass_get_my_referral_position",
|
|
136
|
-
"pitpass_get_my_referral_tree",
|
|
137
|
-
"pitpass_get_my_trader_code",
|
|
138
|
-
"pitpass_get_rewards_balance",
|
|
139
|
-
"pitpass_get_trader_code_info",
|
|
140
|
-
"pitpass_set_trader_code",
|
|
141
|
-
"pitpass_transfer_rewards",
|
|
142
132
|
"preview_follow",
|
|
143
133
|
"refresh_managed_market_quotes",
|
|
144
134
|
"refresh_session",
|