@0xmonaco/types 1.0.67 → 1.0.70

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/dist/buildercodes/index.d.ts +4 -4
  2. package/dist/buildercodes/index.js +1 -1
  3. package/dist/buildercodes/responses.d.ts +45 -1
  4. package/dist/buildercodes/responses.js +25 -1
  5. package/dist/copy-trading/index.d.ts +95 -0
  6. package/dist/copy-trading/index.js +8 -0
  7. package/dist/copy-trading/responses.d.ts +373 -0
  8. package/dist/copy-trading/responses.js +268 -0
  9. package/dist/delegated-agents/index.d.ts +7 -0
  10. package/dist/faucet/index.d.ts +3 -2
  11. package/dist/index.d.ts +1 -0
  12. package/dist/index.js +1 -0
  13. package/dist/margin-accounts/index.d.ts +18 -0
  14. package/dist/portfolio/index.d.ts +12 -0
  15. package/dist/positions/index.d.ts +8 -2
  16. package/dist/profile/index.d.ts +44 -41
  17. package/dist/sdk/index.d.ts +4 -1
  18. package/dist/trading/orders.d.ts +6 -0
  19. package/dist/trading/responses.d.ts +10 -57
  20. package/dist/validation/copy-trading.d.ts +113 -0
  21. package/dist/validation/copy-trading.js +141 -0
  22. package/dist/validation/index.d.ts +1 -0
  23. package/dist/validation/index.js +1 -0
  24. package/dist/validation/positions.d.ts +1 -1
  25. package/dist/validation/profile.d.ts +1 -1
  26. package/dist/validation/profile.js +8 -16
  27. package/dist/validation/trading.d.ts +4 -5
  28. package/dist/validation/trading.js +25 -50
  29. package/dist/websocket/client.d.ts +9 -1
  30. package/dist/websocket/events/conditional-order-events.d.ts +34 -14
  31. package/dist/websocket/events/copy-events.d.ts +133 -0
  32. package/dist/websocket/events/copy-events.js +17 -0
  33. package/dist/websocket/events/index.d.ts +1 -0
  34. package/dist/websocket/events/index.js +1 -0
  35. package/dist/websocket/events/orders-events.d.ts +125 -18
  36. package/dist/websocket/snapshots.d.ts +32 -3
  37. package/dist/whitelist/index.d.ts +5 -16
  38. package/dist/whitelist/index.js +2 -8
  39. package/dist/wire/operations.d.ts +1 -1
  40. package/dist/wire/operations.js +13 -0
  41. package/dist/wire/schema.d.ts +1851 -320
  42. package/package.json +2 -2
@@ -18,9 +18,9 @@ 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
- /** List this authenticated frontend's per-trade BuilderCodes credits. */
21
+ /** List this authenticated frontend's per-trade BuilderCodes credits, optionally of one payout `kind`. */
22
22
  listPayouts(params?: ListBuildercodePayoutsParams): Promise<ListBuildercodePayoutsResponse>;
23
- /** Summarize this authenticated frontend's BuilderCodes credits by token. */
23
+ /** Summarize this authenticated frontend's BuilderCodes credits by token, and by token and payout kind. */
24
24
  getPayoutSummary(): Promise<GetBuildercodePayoutSummaryResponse>;
25
25
  /** Read the authenticated wallet's available reserved reward balances. */
26
26
  getRewardsBalance(): Promise<GetBuildercodeRewardsBalanceResponse>;
@@ -67,5 +67,5 @@ export interface BuildercodesAPI extends BaseAPI {
67
67
  */
68
68
  claimBuildercodeRewards(params: ClaimBuildercodeRewardsParams): Promise<ClaimBuildercodeRewardsResponse>;
69
69
  }
70
- export type { BuildercodePayout, BuildercodePayoutTokenTotal, BuildercodeRewardsBalance, ClaimBuildercodeRewardsParams, ClaimBuildercodeRewardsResponse, GetBuildercodePayoutSummaryResponse, GetBuildercodeRewardsBalanceResponse, GetBuildercodesConfigResponse, ListBuildercodePayoutsParams, ListBuildercodePayoutsResponse, } from "./responses";
71
- export { BuildercodePayoutSchema, BuildercodePayoutTokenTotalSchema, BuildercodeRewardsBalanceSchema, ClaimBuildercodeRewardsParamsSchema, ClaimBuildercodeRewardsResponseSchema, GetBuildercodePayoutSummaryResponseSchema, GetBuildercodeRewardsBalanceResponseSchema, GetBuildercodesConfigResponseSchema, ListBuildercodePayoutsParamsSchema, ListBuildercodePayoutsResponseSchema, } from "./responses";
70
+ export type { BuildercodePayout, BuildercodePayoutKind, BuildercodePayoutTokenKindTotal, BuildercodePayoutTokenTotal, BuildercodeRewardsBalance, ClaimBuildercodeRewardsParams, ClaimBuildercodeRewardsResponse, GetBuildercodePayoutSummaryResponse, GetBuildercodeRewardsBalanceResponse, GetBuildercodesConfigResponse, ListBuildercodePayoutsParams, ListBuildercodePayoutsResponse, } from "./responses";
71
+ export { BuildercodePayoutKindSchema, BuildercodePayoutSchema, BuildercodePayoutTokenKindTotalSchema, BuildercodePayoutTokenTotalSchema, BuildercodeRewardsBalanceSchema, ClaimBuildercodeRewardsParamsSchema, ClaimBuildercodeRewardsResponseSchema, GetBuildercodePayoutSummaryResponseSchema, GetBuildercodeRewardsBalanceResponseSchema, GetBuildercodesConfigResponseSchema, ListBuildercodePayoutsParamsSchema, ListBuildercodePayoutsResponseSchema, } from "./responses";
@@ -4,4 +4,4 @@
4
4
  * Types for the BuilderCodes API: reading and claiming an enrolled frontend's
5
5
  * per-trade revenue share.
6
6
  */
7
- export { BuildercodePayoutSchema, BuildercodePayoutTokenTotalSchema, BuildercodeRewardsBalanceSchema, ClaimBuildercodeRewardsParamsSchema, ClaimBuildercodeRewardsResponseSchema, GetBuildercodePayoutSummaryResponseSchema, GetBuildercodeRewardsBalanceResponseSchema, GetBuildercodesConfigResponseSchema, ListBuildercodePayoutsParamsSchema, ListBuildercodePayoutsResponseSchema, } from "./responses";
7
+ export { BuildercodePayoutKindSchema, BuildercodePayoutSchema, BuildercodePayoutTokenKindTotalSchema, BuildercodePayoutTokenTotalSchema, BuildercodeRewardsBalanceSchema, ClaimBuildercodeRewardsParamsSchema, ClaimBuildercodeRewardsResponseSchema, GetBuildercodePayoutSummaryResponseSchema, GetBuildercodeRewardsBalanceResponseSchema, GetBuildercodesConfigResponseSchema, ListBuildercodePayoutsParamsSchema, ListBuildercodePayoutsResponseSchema, } from "./responses";
@@ -13,10 +13,23 @@ export declare const GetBuildercodesConfigResponseSchema: z.ZodObject<{
13
13
  buildercodesEnabled: z.ZodBoolean;
14
14
  buildercodesBudgetBps: z.ZodNumber;
15
15
  }, z.core.$strip>;
16
- /** Pagination accepted by the per-trade payout history endpoint. */
16
+ /**
17
+ * The payout stream a BuilderCodes credit belongs to. `REVENUE_SHARE` is the
18
+ * frontend's share of Monaco's fee; `BUILDER_FEE` is the frontend's own builder
19
+ * fee, paid by the taker. Both land in the same claimable balance.
20
+ */
21
+ export declare const BuildercodePayoutKindSchema: z.ZodEnum<{
22
+ REVENUE_SHARE: "REVENUE_SHARE";
23
+ BUILDER_FEE: "BUILDER_FEE";
24
+ }>;
25
+ /** Pagination and filter accepted by the per-trade payout history endpoint. */
17
26
  export declare const ListBuildercodePayoutsParamsSchema: z.ZodObject<{
18
27
  page: z.ZodOptional<z.ZodNumber>;
19
28
  pageSize: z.ZodOptional<z.ZodNumber>;
29
+ kind: z.ZodOptional<z.ZodEnum<{
30
+ REVENUE_SHARE: "REVENUE_SHARE";
31
+ BUILDER_FEE: "BUILDER_FEE";
32
+ }>>;
20
33
  }, z.core.$strip>;
21
34
  /** One per-trade BuilderCodes credit. Amounts are RAW atomic units. */
22
35
  export declare const BuildercodePayoutSchema: z.ZodObject<{
@@ -26,6 +39,10 @@ export declare const BuildercodePayoutSchema: z.ZodObject<{
26
39
  amount: z.ZodString;
27
40
  appliedBps: z.ZodNumber;
28
41
  createdAt: z.ZodString;
42
+ kind: z.ZodOptional<z.ZodEnum<{
43
+ REVENUE_SHARE: "REVENUE_SHARE";
44
+ BUILDER_FEE: "BUILDER_FEE";
45
+ }>>;
29
46
  }, z.core.$strip>;
30
47
  /** Schema for the paginated per-trade payout history. */
31
48
  export declare const ListBuildercodePayoutsResponseSchema: z.ZodObject<{
@@ -36,6 +53,10 @@ export declare const ListBuildercodePayoutsResponseSchema: z.ZodObject<{
36
53
  amount: z.ZodString;
37
54
  appliedBps: z.ZodNumber;
38
55
  createdAt: z.ZodString;
56
+ kind: z.ZodOptional<z.ZodEnum<{
57
+ REVENUE_SHARE: "REVENUE_SHARE";
58
+ BUILDER_FEE: "BUILDER_FEE";
59
+ }>>;
39
60
  }, z.core.$strip>>;
40
61
  total: z.ZodNumber;
41
62
  page: z.ZodNumber;
@@ -49,6 +70,17 @@ export declare const BuildercodePayoutTokenTotalSchema: z.ZodObject<{
49
70
  payoutCount: z.ZodNumber;
50
71
  lastCreditedAt: z.ZodString;
51
72
  }, z.core.$strip>;
73
+ /** One token-denominated BuilderCodes earnings total for one payout kind. */
74
+ export declare const BuildercodePayoutTokenKindTotalSchema: z.ZodObject<{
75
+ token: z.ZodString;
76
+ kind: z.ZodEnum<{
77
+ REVENUE_SHARE: "REVENUE_SHARE";
78
+ BUILDER_FEE: "BUILDER_FEE";
79
+ }>;
80
+ totalAmount: z.ZodString;
81
+ payoutCount: z.ZodNumber;
82
+ lastCreditedAt: z.ZodString;
83
+ }, z.core.$strip>;
52
84
  /** Schema for this frontend's payout summary. */
53
85
  export declare const GetBuildercodePayoutSummaryResponseSchema: z.ZodObject<{
54
86
  totalPayouts: z.ZodNumber;
@@ -59,6 +91,16 @@ export declare const GetBuildercodePayoutSummaryResponseSchema: z.ZodObject<{
59
91
  payoutCount: z.ZodNumber;
60
92
  lastCreditedAt: z.ZodString;
61
93
  }, z.core.$strip>>;
94
+ byTokenAndKind: z.ZodOptional<z.ZodArray<z.ZodObject<{
95
+ token: z.ZodString;
96
+ kind: z.ZodEnum<{
97
+ REVENUE_SHARE: "REVENUE_SHARE";
98
+ BUILDER_FEE: "BUILDER_FEE";
99
+ }>;
100
+ totalAmount: z.ZodString;
101
+ payoutCount: z.ZodNumber;
102
+ lastCreditedAt: z.ZodString;
103
+ }, z.core.$strip>>>;
62
104
  }, z.core.$strip>;
63
105
  /** One available balance in the reserved BuilderCodes reward bucket. */
64
106
  export declare const BuildercodeRewardsBalanceSchema: z.ZodObject<{
@@ -86,9 +128,11 @@ export type ClaimBuildercodeRewardsParams = z.infer<typeof ClaimBuildercodeRewar
86
128
  export type ClaimBuildercodeRewardsResponse = z.infer<typeof ClaimBuildercodeRewardsResponseSchema>;
87
129
  export type GetBuildercodesConfigResponse = z.infer<typeof GetBuildercodesConfigResponseSchema>;
88
130
  export type ListBuildercodePayoutsParams = z.infer<typeof ListBuildercodePayoutsParamsSchema>;
131
+ export type BuildercodePayoutKind = z.infer<typeof BuildercodePayoutKindSchema>;
89
132
  export type BuildercodePayout = z.infer<typeof BuildercodePayoutSchema>;
90
133
  export type ListBuildercodePayoutsResponse = z.infer<typeof ListBuildercodePayoutsResponseSchema>;
91
134
  export type BuildercodePayoutTokenTotal = z.infer<typeof BuildercodePayoutTokenTotalSchema>;
135
+ export type BuildercodePayoutTokenKindTotal = z.infer<typeof BuildercodePayoutTokenKindTotalSchema>;
92
136
  export type GetBuildercodePayoutSummaryResponse = z.infer<typeof GetBuildercodePayoutSummaryResponseSchema>;
93
137
  export type BuildercodeRewardsBalance = z.infer<typeof BuildercodeRewardsBalanceSchema>;
94
138
  export type GetBuildercodeRewardsBalanceResponse = z.infer<typeof GetBuildercodeRewardsBalanceResponseSchema>;
@@ -17,10 +17,18 @@ export const GetBuildercodesConfigResponseSchema = z.object({
17
17
  buildercodesEnabled: z.boolean(),
18
18
  buildercodesBudgetBps: z.number().int().min(0).max(10_000),
19
19
  });
20
- /** Pagination accepted by the per-trade payout history endpoint. */
20
+ /**
21
+ * The payout stream a BuilderCodes credit belongs to. `REVENUE_SHARE` is the
22
+ * frontend's share of Monaco's fee; `BUILDER_FEE` is the frontend's own builder
23
+ * fee, paid by the taker. Both land in the same claimable balance.
24
+ */
25
+ export const BuildercodePayoutKindSchema = z.enum(["REVENUE_SHARE", "BUILDER_FEE"]);
26
+ /** Pagination and filter accepted by the per-trade payout history endpoint. */
21
27
  export const ListBuildercodePayoutsParamsSchema = z.object({
22
28
  page: z.number().int().min(1).max(10_000).optional(),
23
29
  pageSize: z.number().int().min(1).max(100).optional(),
30
+ /** Only return credits of this kind; `total` counts the filtered rows. Omit for every kind. */
31
+ kind: BuildercodePayoutKindSchema.optional(),
24
32
  });
25
33
  /** One per-trade BuilderCodes credit. Amounts are RAW atomic units. */
26
34
  export const BuildercodePayoutSchema = z.object({
@@ -30,6 +38,8 @@ export const BuildercodePayoutSchema = z.object({
30
38
  amount: z.string(),
31
39
  appliedBps: z.number().int(),
32
40
  createdAt: z.string(),
41
+ /** Payout stream of this credit. Absent from servers older than this field, whose credits are all `REVENUE_SHARE`. */
42
+ kind: BuildercodePayoutKindSchema.optional(),
33
43
  });
34
44
  /** Schema for the paginated per-trade payout history. */
35
45
  export const ListBuildercodePayoutsResponseSchema = z.object({
@@ -46,11 +56,25 @@ export const BuildercodePayoutTokenTotalSchema = z.object({
46
56
  payoutCount: z.number().int().nonnegative(),
47
57
  lastCreditedAt: z.string(),
48
58
  });
59
+ /** One token-denominated BuilderCodes earnings total for one payout kind. */
60
+ export const BuildercodePayoutTokenKindTotalSchema = z.object({
61
+ token: z.string(),
62
+ kind: BuildercodePayoutKindSchema,
63
+ totalAmount: z.string(),
64
+ payoutCount: z.number().int().nonnegative(),
65
+ lastCreditedAt: z.string(),
66
+ });
49
67
  /** Schema for this frontend's payout summary. */
50
68
  export const GetBuildercodePayoutSummaryResponseSchema = z.object({
51
69
  totalPayouts: z.number().int().nonnegative(),
52
70
  lastCreditedAt: z.string().nullable().optional(),
71
+ /** Per-token totals, summed across every payout kind. */
53
72
  byToken: z.array(BuildercodePayoutTokenTotalSchema),
73
+ /**
74
+ * The same totals split by token AND kind; a token's rows sum to its
75
+ * `byToken` total. Absent from servers older than this field.
76
+ */
77
+ byTokenAndKind: z.array(BuildercodePayoutTokenKindTotalSchema).optional(),
54
78
  });
55
79
  /** One available balance in the reserved BuilderCodes reward bucket. */
56
80
  export const BuildercodeRewardsBalanceSchema = z.object({
@@ -0,0 +1,95 @@
1
+ /**
2
+ * Copy Trading Types (0XM-2851)
3
+ *
4
+ * Followers allocate collateral to a per-leader copy account (a cross risk
5
+ * bucket in their margin account) and every fill the leader makes is mirrored
6
+ * into it. Leaders are addressed by their custom TraderCode handle.
7
+ */
8
+ import type { BaseAPI } from "../api";
9
+ import type { ListLeadTraderClosedTradesParams, ListLeadTradersParams, ListMyFollowersParams, ListMyFollowsParams, PreviewFollowParams, UpsertFollowParams, UpsertLeadTraderParams } from "../validation/copy-trading";
10
+ import type { GetFollowResponse, GetLeadTraderResponse, ListFollowLeaderPositionsResponse, ListLeadTraderClosedTradesResponse, ListLeadTraderOpenPositionsResponse, ListLeadTradersResponse, ListMyFollowersResponse, ListMyFollowsResponse, PreviewFollowResponse, StopFollowResponse, UpsertFollowResponse, UpsertLeadTraderResponse } from "./responses";
11
+ /**
12
+ * Copy trading API.
13
+ *
14
+ * Public reads (no session needed): {@link listLeadTraders},
15
+ * {@link getLeadTrader}, {@link listLeadTraderClosedTrades}. Everything else
16
+ * is self-scoped to the authenticated caller. Delegated agent and sub-account
17
+ * sessions cannot register as a leader or follow (403).
18
+ */
19
+ export interface CopyTradingAPI extends BaseAPI {
20
+ /**
21
+ * List lead traders (the public leaderboard), highest first by `sort`
22
+ * (default `roi`) over `window` (default `30d`). Cursor paged: pass the
23
+ * previous response's `nextPageToken` with the SAME sort and window; an
24
+ * empty token means the end.
25
+ */
26
+ listLeadTraders(params?: ListLeadTradersParams): Promise<ListLeadTradersResponse>;
27
+ /**
28
+ * Get one lead trader by custom TraderCode handle: profile, follow summary
29
+ * and stats for 7d, 30d, 90d and all. 404 for an unknown or suspended
30
+ * leader.
31
+ */
32
+ getLeadTrader(handle: string): Promise<GetLeadTraderResponse>;
33
+ /** List a lead trader's closed trades (reducing executions), newest first, cursor paged. */
34
+ listLeadTraderClosedTrades(handle: string, params?: ListLeadTraderClosedTradesParams): Promise<ListLeadTraderClosedTradesResponse>;
35
+ /** List a lead trader's open positions. Only current followers of that leader may read them (403 otherwise). */
36
+ listLeadTraderOpenPositions(handle: string): Promise<ListLeadTraderOpenPositionsResponse>;
37
+ /**
38
+ * Register as a lead trader, or edit your profile. A registration is
39
+ * checked against the platform's eligibility rules (account equity, trading
40
+ * history, closed positions, and a claimed custom TraderCode handle, which
41
+ * followers address you by); a refusal is a 400 naming the rule. A follower
42
+ * with a live follow cannot register.
43
+ *
44
+ * The profile is replaced as sent: an omitted `bio` or `minAllocation`
45
+ * clears it and an omitted `status` means `ACTIVE`; an omitted `shareBps`
46
+ * keeps the current share (the platform default on a registration).
47
+ */
48
+ upsertLeadTrader(params?: UpsertLeadTraderParams): Promise<UpsertLeadTraderResponse>;
49
+ /** Get your own lead trader profile (404 when you are not a lead trader). */
50
+ getMyLeadTrader(): Promise<GetLeadTraderResponse>;
51
+ /** List your followers, as a leader. Cursor paged, up to 1000 per page. */
52
+ listMyFollowers(params?: ListMyFollowersParams): Promise<ListMyFollowersResponse>;
53
+ /**
54
+ * Follow a lead trader (no `followId`), or edit one of your follows
55
+ * (`followId` set). A create moves `allocation` from your margin account
56
+ * into a new copy account: a cross risk bucket that holds this follow's
57
+ * collateral and positions.
58
+ *
59
+ * An edit REPLACES the follow's settings: every optional setting you leave
60
+ * out reverts to its default, so an edit that omits `slPct` removes the
61
+ * stop-loss. Pass the full desired configuration on every edit. The leader
62
+ * comes from the stored follow, so `leader` may be omitted on an edit; a
63
+ * handle naming a different leader is refused.
64
+ */
65
+ upsertFollow(params: UpsertFollowParams): Promise<UpsertFollowResponse>;
66
+ /**
67
+ * Stop one of your follows: the leader's fills stop being mirrored. An exit
68
+ * is never gated beyond ownership, except that a delegated agent session
69
+ * cannot stop a follow (403).
70
+ */
71
+ stopFollow(followId: string): Promise<StopFollowResponse>;
72
+ /** List your follows, newest first. Cursor paged, up to 1000 per page. */
73
+ listMyFollows(params?: ListMyFollowsParams): Promise<ListMyFollowsResponse>;
74
+ /**
75
+ * Get one of your follows with its most recent skipped mirrors (up to 100)
76
+ * and the copy account's marked equity. 404 for a follow that is not yours.
77
+ */
78
+ getFollow(followId: string): Promise<GetFollowResponse>;
79
+ /**
80
+ * List the open positions of the leader one of your follows copies. The
81
+ * leader comes from the follow, so this works after the leader releases
82
+ * their handle. 404 for a follow that is not yours; 403 for a stopped one.
83
+ */
84
+ listFollowLeaderPositions(followId: string): Promise<ListFollowLeaderPositionsResponse>;
85
+ /**
86
+ * Preview what a follow with these terms would open if it set
87
+ * `copyExisting`, as totals only: the estimated margin and fees, and how
88
+ * many of the leader's positions would and would not be copied (no pair,
89
+ * side or reason). Read-only. Delegated agent and sub-account sessions get
90
+ * 403, as for following.
91
+ */
92
+ previewFollow(params: PreviewFollowParams): Promise<PreviewFollowResponse>;
93
+ }
94
+ export type { ClosedTrade, ClosedTradeAction, CopySkip, Follow, Follower, GetFollowResponse, GetLeadTraderResponse, LeadTraderFollowSummary, LeadTraderListing, LeadTraderOpenPosition, LeadTraderProfile, LeadTraderRef, LeadTraderSort, LeadTraderStats, LeadTraderStatsWindow, LeadTraderStatus, ListFollowLeaderPositionsResponse, ListLeadTraderClosedTradesResponse, ListLeadTraderOpenPositionsResponse, ListLeadTradersResponse, ListMyFollowersResponse, ListMyFollowsResponse, PreviewFollowResponse, StopFollowResponse, UpsertFollowResponse, UpsertLeadTraderResponse, } from "./responses";
95
+ export { ClosedTradeSchema, CopySkipSchema, FollowerSchema, FollowSchema, GetFollowResponseSchema, GetLeadTraderResponseSchema, LeadTraderFollowSummarySchema, LeadTraderListingSchema, LeadTraderOpenPositionSchema, LeadTraderProfileSchema, LeadTraderRefSchema, LeadTraderStatsSchema, ListFollowLeaderPositionsResponseSchema, ListLeadTraderClosedTradesResponseSchema, ListLeadTraderOpenPositionsResponseSchema, ListLeadTradersResponseSchema, ListMyFollowersResponseSchema, ListMyFollowsResponseSchema, PreviewFollowResponseSchema, StopFollowResponseSchema, UpsertFollowResponseSchema, UpsertLeadTraderResponseSchema, } from "./responses";
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copy Trading Types (0XM-2851)
3
+ *
4
+ * Followers allocate collateral to a per-leader copy account (a cross risk
5
+ * bucket in their margin account) and every fill the leader makes is mirrored
6
+ * into it. Leaders are addressed by their custom TraderCode handle.
7
+ */
8
+ export { ClosedTradeSchema, CopySkipSchema, FollowerSchema, FollowSchema, GetFollowResponseSchema, GetLeadTraderResponseSchema, LeadTraderFollowSummarySchema, LeadTraderListingSchema, LeadTraderOpenPositionSchema, LeadTraderProfileSchema, LeadTraderRefSchema, LeadTraderStatsSchema, ListFollowLeaderPositionsResponseSchema, ListLeadTraderClosedTradesResponseSchema, ListLeadTraderOpenPositionsResponseSchema, ListLeadTradersResponseSchema, ListMyFollowersResponseSchema, ListMyFollowsResponseSchema, PreviewFollowResponseSchema, StopFollowResponseSchema, UpsertFollowResponseSchema, UpsertLeadTraderResponseSchema, } from "./responses";
@@ -0,0 +1,373 @@
1
+ /**
2
+ * Copy trading response types (0XM-2851).
3
+ *
4
+ * Zod schemas for every copy trading REST/gRPC response, with the inferred
5
+ * TypeScript types. The REST API returns camelCase JSON; an optional field the
6
+ * server has no value for arrives as `null`, so optional fields are typed
7
+ * `T | null | undefined` (`.nullish()`).
8
+ *
9
+ * Leaders are only ever identified by their public wallet address and custom
10
+ * TraderCode handle, never by an internal id.
11
+ *
12
+ * Label fields (statuses, modes, reasons) are typed `Union | (string & {})`:
13
+ * the unions name the values the server sends today, and the schemas accept
14
+ * any string so a value added server-side later does not fail parsing.
15
+ */
16
+ import { z } from "zod";
17
+ import type { CopyLeverageMode, CopyMarginModePolicy, CopyRelationshipStatus, CopySizingMode, CopySkipReason, CopyStopReason } from "../websocket/events/copy-events";
18
+ /** Lead trader profile status. `SUSPENDED` appears only on your own profile. */
19
+ export type LeadTraderStatus = "ACTIVE" | "PAUSED" | "SUSPENDED";
20
+ /** Leaderboard stats window. */
21
+ export type LeadTraderStatsWindow = "7d" | "30d" | "90d" | "all";
22
+ /** Leaderboard sort metric (highest first). */
23
+ export type LeadTraderSort = "roi" | "pnl" | "followers" | "allocated" | "aum" | "win_rate";
24
+ /** The kind of reducing execution a closed trade records. */
25
+ export type ClosedTradeAction = "DECREASE" | "CLOSE" | "LIQUIDATE" | "ADL";
26
+ /** A lead trader as the public sees them: wallet and handle, never an internal id. */
27
+ export declare const LeadTraderRefSchema: z.ZodObject<{
28
+ walletAddress: z.ZodString;
29
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
30
+ display: z.ZodString;
31
+ }, z.core.$strip>;
32
+ /** A lead trader's public profile. */
33
+ export declare const LeadTraderProfileSchema: z.ZodObject<{
34
+ leader: z.ZodObject<{
35
+ walletAddress: z.ZodString;
36
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
37
+ display: z.ZodString;
38
+ }, z.core.$strip>;
39
+ status: z.ZodType<(string & {}) | LeadTraderStatus, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatus, unknown>>;
40
+ shareBps: z.ZodNumber;
41
+ bio: z.ZodString;
42
+ minAllocation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
43
+ registeredAt: z.ZodString;
44
+ }, z.core.$strip>;
45
+ /** Live follows of a leader. */
46
+ export declare const LeadTraderFollowSummarySchema: z.ZodObject<{
47
+ followerCount: z.ZodNumber;
48
+ allocated: z.ZodString;
49
+ aumEquity: z.ZodOptional<z.ZodNullable<z.ZodString>>;
50
+ }, z.core.$strip>;
51
+ /** A leader's trading stats over one window. */
52
+ export declare const LeadTraderStatsSchema: z.ZodObject<{
53
+ window: z.ZodType<(string & {}) | LeadTraderStatsWindow, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatsWindow, unknown>>;
54
+ pnl: z.ZodString;
55
+ roiPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
56
+ maxDrawdownPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
57
+ winRatePct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
58
+ closedTrades: z.ZodNumber;
59
+ }, z.core.$strip>;
60
+ /** One lead trader: profile, follow summary and stats for every window (7d, 30d, 90d, all). */
61
+ export declare const GetLeadTraderResponseSchema: z.ZodObject<{
62
+ profile: z.ZodObject<{
63
+ leader: z.ZodObject<{
64
+ walletAddress: z.ZodString;
65
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
66
+ display: z.ZodString;
67
+ }, z.core.$strip>;
68
+ status: z.ZodType<(string & {}) | LeadTraderStatus, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatus, unknown>>;
69
+ shareBps: z.ZodNumber;
70
+ bio: z.ZodString;
71
+ minAllocation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
72
+ registeredAt: z.ZodString;
73
+ }, z.core.$strip>;
74
+ followSummary: z.ZodObject<{
75
+ followerCount: z.ZodNumber;
76
+ allocated: z.ZodString;
77
+ aumEquity: z.ZodOptional<z.ZodNullable<z.ZodString>>;
78
+ }, z.core.$strip>;
79
+ stats: z.ZodArray<z.ZodObject<{
80
+ window: z.ZodType<(string & {}) | LeadTraderStatsWindow, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatsWindow, unknown>>;
81
+ pnl: z.ZodString;
82
+ roiPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
83
+ maxDrawdownPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
84
+ winRatePct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
85
+ closedTrades: z.ZodNumber;
86
+ }, z.core.$strip>>;
87
+ }, z.core.$strip>;
88
+ /** One leaderboard row: stats for the requested window only. */
89
+ export declare const LeadTraderListingSchema: z.ZodObject<{
90
+ profile: z.ZodObject<{
91
+ leader: z.ZodObject<{
92
+ walletAddress: z.ZodString;
93
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
94
+ display: z.ZodString;
95
+ }, z.core.$strip>;
96
+ status: z.ZodType<(string & {}) | LeadTraderStatus, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatus, unknown>>;
97
+ shareBps: z.ZodNumber;
98
+ bio: z.ZodString;
99
+ minAllocation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
100
+ registeredAt: z.ZodString;
101
+ }, z.core.$strip>;
102
+ followSummary: z.ZodObject<{
103
+ followerCount: z.ZodNumber;
104
+ allocated: z.ZodString;
105
+ aumEquity: z.ZodOptional<z.ZodNullable<z.ZodString>>;
106
+ }, z.core.$strip>;
107
+ stats: z.ZodObject<{
108
+ window: z.ZodType<(string & {}) | LeadTraderStatsWindow, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatsWindow, unknown>>;
109
+ pnl: z.ZodString;
110
+ roiPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
111
+ maxDrawdownPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
112
+ winRatePct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
113
+ closedTrades: z.ZodNumber;
114
+ }, z.core.$strip>;
115
+ }, z.core.$strip>;
116
+ /** A page of the public leaderboard. */
117
+ export declare const ListLeadTradersResponseSchema: z.ZodObject<{
118
+ leaders: z.ZodArray<z.ZodObject<{
119
+ profile: z.ZodObject<{
120
+ leader: z.ZodObject<{
121
+ walletAddress: z.ZodString;
122
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
123
+ display: z.ZodString;
124
+ }, z.core.$strip>;
125
+ status: z.ZodType<(string & {}) | LeadTraderStatus, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatus, unknown>>;
126
+ shareBps: z.ZodNumber;
127
+ bio: z.ZodString;
128
+ minAllocation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
129
+ registeredAt: z.ZodString;
130
+ }, z.core.$strip>;
131
+ followSummary: z.ZodObject<{
132
+ followerCount: z.ZodNumber;
133
+ allocated: z.ZodString;
134
+ aumEquity: z.ZodOptional<z.ZodNullable<z.ZodString>>;
135
+ }, z.core.$strip>;
136
+ stats: z.ZodObject<{
137
+ window: z.ZodType<(string & {}) | LeadTraderStatsWindow, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatsWindow, unknown>>;
138
+ pnl: z.ZodString;
139
+ roiPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
140
+ maxDrawdownPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
141
+ winRatePct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
142
+ closedTrades: z.ZodNumber;
143
+ }, z.core.$strip>;
144
+ }, z.core.$strip>>;
145
+ nextPageToken: z.ZodString;
146
+ asOf: z.ZodString;
147
+ }, z.core.$strip>;
148
+ /** Result of registering as, or editing, a lead trader. */
149
+ export declare const UpsertLeadTraderResponseSchema: z.ZodObject<{
150
+ created: z.ZodBoolean;
151
+ status: z.ZodType<(string & {}) | LeadTraderStatus, unknown, z.core.$ZodTypeInternals<(string & {}) | LeadTraderStatus, unknown>>;
152
+ shareBps: z.ZodNumber;
153
+ }, z.core.$strip>;
154
+ /** One of your followers, as a leader sees them. */
155
+ export declare const FollowerSchema: z.ZodObject<{
156
+ walletAddress: z.ZodString;
157
+ display: z.ZodString;
158
+ status: z.ZodType<CopyRelationshipStatus | (string & {}), unknown, z.core.$ZodTypeInternals<CopyRelationshipStatus | (string & {}), unknown>>;
159
+ allocation: z.ZodString;
160
+ startedAt: z.ZodString;
161
+ }, z.core.$strip>;
162
+ /** A page of your followers. */
163
+ export declare const ListMyFollowersResponseSchema: z.ZodObject<{
164
+ followers: z.ZodArray<z.ZodObject<{
165
+ walletAddress: z.ZodString;
166
+ display: z.ZodString;
167
+ status: z.ZodType<CopyRelationshipStatus | (string & {}), unknown, z.core.$ZodTypeInternals<CopyRelationshipStatus | (string & {}), unknown>>;
168
+ allocation: z.ZodString;
169
+ startedAt: z.ZodString;
170
+ }, z.core.$strip>>;
171
+ nextPageToken: z.ZodString;
172
+ }, z.core.$strip>;
173
+ /** One reducing execution of a leader's position. */
174
+ export declare const ClosedTradeSchema: z.ZodObject<{
175
+ tradingPairId: z.ZodString;
176
+ positionSide: z.ZodString;
177
+ action: z.ZodType<(string & {}) | ClosedTradeAction, unknown, z.core.$ZodTypeInternals<(string & {}) | ClosedTradeAction, unknown>>;
178
+ size: z.ZodOptional<z.ZodNullable<z.ZodString>>;
179
+ exitPrice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
180
+ entryPrice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
181
+ realizedPnl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
182
+ netRealizedPnl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
183
+ realizedRoe: z.ZodOptional<z.ZodNullable<z.ZodString>>;
184
+ closedAt: z.ZodString;
185
+ }, z.core.$strip>;
186
+ /** A page of a leader's closed trades. */
187
+ export declare const ListLeadTraderClosedTradesResponseSchema: z.ZodObject<{
188
+ closedTrades: z.ZodArray<z.ZodObject<{
189
+ tradingPairId: z.ZodString;
190
+ positionSide: z.ZodString;
191
+ action: z.ZodType<(string & {}) | ClosedTradeAction, unknown, z.core.$ZodTypeInternals<(string & {}) | ClosedTradeAction, unknown>>;
192
+ size: z.ZodOptional<z.ZodNullable<z.ZodString>>;
193
+ exitPrice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
194
+ entryPrice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
195
+ realizedPnl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
196
+ netRealizedPnl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
197
+ realizedRoe: z.ZodOptional<z.ZodNullable<z.ZodString>>;
198
+ closedAt: z.ZodString;
199
+ }, z.core.$strip>>;
200
+ nextPageToken: z.ZodString;
201
+ }, z.core.$strip>;
202
+ /** One open position of a leader you follow. */
203
+ export declare const LeadTraderOpenPositionSchema: z.ZodObject<{
204
+ tradingPairId: z.ZodString;
205
+ side: z.ZodString;
206
+ size: z.ZodString;
207
+ entryPrice: z.ZodString;
208
+ markPrice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
209
+ unrealizedPnl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
210
+ leverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
211
+ marginMode: z.ZodString;
212
+ }, z.core.$strip>;
213
+ /** A followed leader's open positions (current followers only). */
214
+ export declare const ListLeadTraderOpenPositionsResponseSchema: z.ZodObject<{
215
+ positions: z.ZodArray<z.ZodObject<{
216
+ tradingPairId: z.ZodString;
217
+ side: z.ZodString;
218
+ size: z.ZodString;
219
+ entryPrice: z.ZodString;
220
+ markPrice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
221
+ unrealizedPnl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
222
+ leverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
223
+ marginMode: z.ZodString;
224
+ }, z.core.$strip>>;
225
+ }, z.core.$strip>;
226
+ /** One of your follows. */
227
+ export declare const FollowSchema: z.ZodObject<{
228
+ followId: z.ZodString;
229
+ leader: z.ZodObject<{
230
+ walletAddress: z.ZodString;
231
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
232
+ display: z.ZodString;
233
+ }, z.core.$strip>;
234
+ status: z.ZodType<CopyRelationshipStatus | (string & {}), unknown, z.core.$ZodTypeInternals<CopyRelationshipStatus | (string & {}), unknown>>;
235
+ marginModePolicy: z.ZodType<CopyMarginModePolicy | (string & {}), unknown, z.core.$ZodTypeInternals<CopyMarginModePolicy | (string & {}), unknown>>;
236
+ sizingMode: z.ZodType<CopySizingMode | (string & {}), unknown, z.core.$ZodTypeInternals<CopySizingMode | (string & {}), unknown>>;
237
+ sizingParam: z.ZodOptional<z.ZodNullable<z.ZodString>>;
238
+ leverageMode: z.ZodType<CopyLeverageMode | (string & {}), unknown, z.core.$ZodTypeInternals<CopyLeverageMode | (string & {}), unknown>>;
239
+ fixedLeverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
240
+ allocation: z.ZodString;
241
+ slPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
242
+ copyExisting: z.ZodBoolean;
243
+ tradingPairIds: z.ZodArray<z.ZodString>;
244
+ consecutiveSkips: z.ZodNumber;
245
+ copyRiskBucketId: z.ZodString;
246
+ startedAt: z.ZodString;
247
+ stoppedAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
248
+ stopReason: z.ZodOptional<z.ZodNullable<z.ZodType<CopyStopReason | (string & {}), unknown, z.core.$ZodTypeInternals<CopyStopReason | (string & {}), unknown>>>>;
249
+ }, z.core.$strip>;
250
+ /** A page of your follows. */
251
+ export declare const ListMyFollowsResponseSchema: z.ZodObject<{
252
+ follows: z.ZodArray<z.ZodObject<{
253
+ followId: z.ZodString;
254
+ leader: z.ZodObject<{
255
+ walletAddress: z.ZodString;
256
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
257
+ display: z.ZodString;
258
+ }, z.core.$strip>;
259
+ status: z.ZodType<CopyRelationshipStatus | (string & {}), unknown, z.core.$ZodTypeInternals<CopyRelationshipStatus | (string & {}), unknown>>;
260
+ marginModePolicy: z.ZodType<CopyMarginModePolicy | (string & {}), unknown, z.core.$ZodTypeInternals<CopyMarginModePolicy | (string & {}), unknown>>;
261
+ sizingMode: z.ZodType<CopySizingMode | (string & {}), unknown, z.core.$ZodTypeInternals<CopySizingMode | (string & {}), unknown>>;
262
+ sizingParam: z.ZodOptional<z.ZodNullable<z.ZodString>>;
263
+ leverageMode: z.ZodType<CopyLeverageMode | (string & {}), unknown, z.core.$ZodTypeInternals<CopyLeverageMode | (string & {}), unknown>>;
264
+ fixedLeverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
265
+ allocation: z.ZodString;
266
+ slPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
267
+ copyExisting: z.ZodBoolean;
268
+ tradingPairIds: z.ZodArray<z.ZodString>;
269
+ consecutiveSkips: z.ZodNumber;
270
+ copyRiskBucketId: z.ZodString;
271
+ startedAt: z.ZodString;
272
+ stoppedAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
273
+ stopReason: z.ZodOptional<z.ZodNullable<z.ZodType<CopyStopReason | (string & {}), unknown, z.core.$ZodTypeInternals<CopyStopReason | (string & {}), unknown>>>>;
274
+ }, z.core.$strip>>;
275
+ nextPageToken: z.ZodString;
276
+ }, z.core.$strip>;
277
+ /** A leader fill one of your follows did not mirror. */
278
+ export declare const CopySkipSchema: z.ZodObject<{
279
+ tradingPairId: z.ZodString;
280
+ reason: z.ZodType<CopySkipReason | (string & {}), unknown, z.core.$ZodTypeInternals<CopySkipReason | (string & {}), unknown>>;
281
+ requestedQuantity: z.ZodString;
282
+ skippedAt: z.ZodString;
283
+ }, z.core.$strip>;
284
+ /** One of your follows with its most recent skips (up to 100). */
285
+ export declare const GetFollowResponseSchema: z.ZodObject<{
286
+ follow: z.ZodObject<{
287
+ followId: z.ZodString;
288
+ leader: z.ZodObject<{
289
+ walletAddress: z.ZodString;
290
+ handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
291
+ display: z.ZodString;
292
+ }, z.core.$strip>;
293
+ status: z.ZodType<CopyRelationshipStatus | (string & {}), unknown, z.core.$ZodTypeInternals<CopyRelationshipStatus | (string & {}), unknown>>;
294
+ marginModePolicy: z.ZodType<CopyMarginModePolicy | (string & {}), unknown, z.core.$ZodTypeInternals<CopyMarginModePolicy | (string & {}), unknown>>;
295
+ sizingMode: z.ZodType<CopySizingMode | (string & {}), unknown, z.core.$ZodTypeInternals<CopySizingMode | (string & {}), unknown>>;
296
+ sizingParam: z.ZodOptional<z.ZodNullable<z.ZodString>>;
297
+ leverageMode: z.ZodType<CopyLeverageMode | (string & {}), unknown, z.core.$ZodTypeInternals<CopyLeverageMode | (string & {}), unknown>>;
298
+ fixedLeverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
299
+ allocation: z.ZodString;
300
+ slPct: z.ZodOptional<z.ZodNullable<z.ZodString>>;
301
+ copyExisting: z.ZodBoolean;
302
+ tradingPairIds: z.ZodArray<z.ZodString>;
303
+ consecutiveSkips: z.ZodNumber;
304
+ copyRiskBucketId: z.ZodString;
305
+ startedAt: z.ZodString;
306
+ stoppedAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
307
+ stopReason: z.ZodOptional<z.ZodNullable<z.ZodType<CopyStopReason | (string & {}), unknown, z.core.$ZodTypeInternals<CopyStopReason | (string & {}), unknown>>>>;
308
+ }, z.core.$strip>;
309
+ recentSkips: z.ZodArray<z.ZodObject<{
310
+ tradingPairId: z.ZodString;
311
+ reason: z.ZodType<CopySkipReason | (string & {}), unknown, z.core.$ZodTypeInternals<CopySkipReason | (string & {}), unknown>>;
312
+ requestedQuantity: z.ZodString;
313
+ skippedAt: z.ZodString;
314
+ }, z.core.$strip>>;
315
+ copyAccountEquity: z.ZodOptional<z.ZodNullable<z.ZodString>>;
316
+ }, z.core.$strip>;
317
+ /** The open positions of the leader one of your follows copies. */
318
+ export declare const ListFollowLeaderPositionsResponseSchema: z.ZodObject<{
319
+ positions: z.ZodArray<z.ZodObject<{
320
+ tradingPairId: z.ZodString;
321
+ side: z.ZodString;
322
+ size: z.ZodString;
323
+ entryPrice: z.ZodString;
324
+ markPrice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
325
+ unrealizedPnl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
326
+ leverage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
327
+ marginMode: z.ZodString;
328
+ }, z.core.$strip>>;
329
+ }, z.core.$strip>;
330
+ /** Result of following a leader or editing a follow. */
331
+ export declare const UpsertFollowResponseSchema: z.ZodObject<{
332
+ followId: z.ZodString;
333
+ copyRiskBucketId: z.ZodString;
334
+ created: z.ZodBoolean;
335
+ }, z.core.$strip>;
336
+ /**
337
+ * What following with `copyExisting` would open, as totals only. The caller
338
+ * is never a follower of the leader, so the preview names no pair, side,
339
+ * size, mark or skip reason. Totals are rounded up to cents.
340
+ */
341
+ export declare const PreviewFollowResponseSchema: z.ZodObject<{
342
+ estimatedMargin: z.ZodString;
343
+ estimatedFee: z.ZodString;
344
+ copiedPositions: z.ZodNumber;
345
+ skippedPositions: z.ZodNumber;
346
+ truncated: z.ZodBoolean;
347
+ }, z.core.$strip>;
348
+ /** Result of stopping a follow. */
349
+ export declare const StopFollowResponseSchema: z.ZodObject<{
350
+ followId: z.ZodString;
351
+ }, z.core.$strip>;
352
+ export type LeadTraderRef = z.infer<typeof LeadTraderRefSchema>;
353
+ export type LeadTraderProfile = z.infer<typeof LeadTraderProfileSchema>;
354
+ export type LeadTraderFollowSummary = z.infer<typeof LeadTraderFollowSummarySchema>;
355
+ export type LeadTraderStats = z.infer<typeof LeadTraderStatsSchema>;
356
+ export type GetLeadTraderResponse = z.infer<typeof GetLeadTraderResponseSchema>;
357
+ export type LeadTraderListing = z.infer<typeof LeadTraderListingSchema>;
358
+ export type ListLeadTradersResponse = z.infer<typeof ListLeadTradersResponseSchema>;
359
+ export type UpsertLeadTraderResponse = z.infer<typeof UpsertLeadTraderResponseSchema>;
360
+ export type Follower = z.infer<typeof FollowerSchema>;
361
+ export type ListMyFollowersResponse = z.infer<typeof ListMyFollowersResponseSchema>;
362
+ export type ClosedTrade = z.infer<typeof ClosedTradeSchema>;
363
+ export type ListLeadTraderClosedTradesResponse = z.infer<typeof ListLeadTraderClosedTradesResponseSchema>;
364
+ export type LeadTraderOpenPosition = z.infer<typeof LeadTraderOpenPositionSchema>;
365
+ export type ListLeadTraderOpenPositionsResponse = z.infer<typeof ListLeadTraderOpenPositionsResponseSchema>;
366
+ export type Follow = z.infer<typeof FollowSchema>;
367
+ export type ListMyFollowsResponse = z.infer<typeof ListMyFollowsResponseSchema>;
368
+ export type CopySkip = z.infer<typeof CopySkipSchema>;
369
+ export type GetFollowResponse = z.infer<typeof GetFollowResponseSchema>;
370
+ export type ListFollowLeaderPositionsResponse = z.infer<typeof ListFollowLeaderPositionsResponseSchema>;
371
+ export type UpsertFollowResponse = z.infer<typeof UpsertFollowResponseSchema>;
372
+ export type StopFollowResponse = z.infer<typeof StopFollowResponseSchema>;
373
+ export type PreviewFollowResponse = z.infer<typeof PreviewFollowResponseSchema>;