@pear-protocol/types 1.31.0 → 1.32.0
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/baskets/recommended/entities.d.ts +36 -0
- package/dist/baskets/recommended/entities.js +22 -0
- package/dist/baskets/recommended/index.d.ts +2 -0
- package/dist/baskets/recommended/index.js +2 -0
- package/dist/baskets/recommended/responses.d.ts +28 -0
- package/dist/baskets/recommended/responses.js +8 -0
- package/dist/{saved-baskets → baskets/saved}/entities.d.ts +3 -0
- package/dist/{saved-baskets → baskets/saved}/entities.js +6 -3
- package/dist/{saved-baskets → baskets/saved}/payloads.d.ts +4 -0
- package/dist/{saved-baskets → baskets/saved}/payloads.js +1 -1
- package/dist/{saved-baskets → baskets/saved}/responses.d.ts +6 -0
- package/dist/bundle.d.ts +2 -1
- package/dist/bundle.js +2 -1
- package/dist/common/refinement.d.ts +9 -0
- package/dist/common/refinement.js +9 -1
- package/dist/common/trade-legs.d.ts +2 -0
- package/dist/common/trade-legs.js +7 -3
- package/dist/execution/entities.d.ts +13 -0
- package/dist/execution/entities.js +2 -0
- package/dist/execution/responses.d.ts +8 -0
- package/dist/ladder/entities.d.ts +549 -0
- package/dist/ladder/payloads.d.ts +4 -0
- package/dist/ladder/responses.d.ts +2039 -392
- package/dist/notification/entities.d.ts +176 -3
- package/dist/notification/entities.js +31 -0
- package/dist/notification/responses.d.ts +86 -0
- package/dist/schedule/entities.d.ts +3 -0
- package/dist/schedule/entities.js +2 -0
- package/dist/schedule/payloads.d.ts +2 -0
- package/dist/schedule/payloads.js +6 -29
- package/dist/schedule/responses.d.ts +2 -0
- package/dist/schedule/twap-config.d.ts +41 -0
- package/dist/schedule/twap-config.js +29 -0
- package/dist/trade/payloads.d.ts +8 -0
- package/dist/trade/responses.d.ts +20 -0
- package/dist/trigger/entities/index.d.ts +1707 -54
- package/dist/trigger/entities/index.js +55 -2
- package/dist/trigger/payloads/index.d.ts +898 -91
- package/dist/trigger/payloads/index.js +68 -5
- package/dist/trigger/responses.d.ts +1151 -53
- package/package.json +1 -1
- /package/dist/{saved-baskets → baskets/saved}/index.d.ts +0 -0
- /package/dist/{saved-baskets → baskets/saved}/index.js +0 -0
- /package/dist/{saved-baskets → baskets/saved}/responses.js +0 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const RecommendedBasketLeg: z.ZodObject<{
|
|
3
|
+
id: z.ZodString;
|
|
4
|
+
symbol: z.ZodString;
|
|
5
|
+
side: z.ZodEnum<{
|
|
6
|
+
BUY: "BUY";
|
|
7
|
+
SELL: "SELL";
|
|
8
|
+
}>;
|
|
9
|
+
weight: z.ZodNumber;
|
|
10
|
+
}, z.core.$strip>;
|
|
11
|
+
export declare const RecommendedBasket: z.ZodObject<{
|
|
12
|
+
id: z.ZodUUID;
|
|
13
|
+
name: z.ZodString;
|
|
14
|
+
description: z.ZodOptional<z.ZodString>;
|
|
15
|
+
legs: z.ZodTuple<[z.ZodObject<{
|
|
16
|
+
id: z.ZodString;
|
|
17
|
+
symbol: z.ZodString;
|
|
18
|
+
side: z.ZodEnum<{
|
|
19
|
+
BUY: "BUY";
|
|
20
|
+
SELL: "SELL";
|
|
21
|
+
}>;
|
|
22
|
+
weight: z.ZodNumber;
|
|
23
|
+
}, z.core.$strip>], z.ZodObject<{
|
|
24
|
+
id: z.ZodString;
|
|
25
|
+
symbol: z.ZodString;
|
|
26
|
+
side: z.ZodEnum<{
|
|
27
|
+
BUY: "BUY";
|
|
28
|
+
SELL: "SELL";
|
|
29
|
+
}>;
|
|
30
|
+
weight: z.ZodNumber;
|
|
31
|
+
}, z.core.$strip>>;
|
|
32
|
+
createdAt: z.ZodString;
|
|
33
|
+
updatedAt: z.ZodString;
|
|
34
|
+
}, z.core.$strip>;
|
|
35
|
+
export type RecommendedBasketLeg = z.infer<typeof RecommendedBasketLeg>;
|
|
36
|
+
export type RecommendedBasket = z.infer<typeof RecommendedBasket>;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { Side, AssetWeight } from '../../common/schema';
|
|
3
|
+
import { InstrumentId } from '../../instrument';
|
|
4
|
+
|
|
5
|
+
const RecommendedBasketLeg = z.object({
|
|
6
|
+
id: InstrumentId.describe("Venue instrument id the leg trades"),
|
|
7
|
+
symbol: z.string().min(1).describe("Base asset shown to traders"),
|
|
8
|
+
side: Side,
|
|
9
|
+
weight: AssetWeight.describe("Share of total gross notional as a fraction (legs sum to 1)")
|
|
10
|
+
});
|
|
11
|
+
const RecommendedBasket = z.object({
|
|
12
|
+
id: z.uuid(),
|
|
13
|
+
name: z.string(),
|
|
14
|
+
description: z.string().optional(),
|
|
15
|
+
legs: z.tuple([
|
|
16
|
+
RecommendedBasketLeg
|
|
17
|
+
]).rest(RecommendedBasketLeg),
|
|
18
|
+
createdAt: z.string(),
|
|
19
|
+
updatedAt: z.string()
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
export { RecommendedBasket, RecommendedBasketLeg };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const RecommendedBasketListResponse: z.ZodObject<{
|
|
3
|
+
baskets: z.ZodArray<z.ZodObject<{
|
|
4
|
+
id: z.ZodUUID;
|
|
5
|
+
name: z.ZodString;
|
|
6
|
+
description: z.ZodOptional<z.ZodString>;
|
|
7
|
+
legs: z.ZodTuple<[z.ZodObject<{
|
|
8
|
+
id: z.ZodString;
|
|
9
|
+
symbol: z.ZodString;
|
|
10
|
+
side: z.ZodEnum<{
|
|
11
|
+
BUY: "BUY";
|
|
12
|
+
SELL: "SELL";
|
|
13
|
+
}>;
|
|
14
|
+
weight: z.ZodNumber;
|
|
15
|
+
}, z.core.$strip>], z.ZodObject<{
|
|
16
|
+
id: z.ZodString;
|
|
17
|
+
symbol: z.ZodString;
|
|
18
|
+
side: z.ZodEnum<{
|
|
19
|
+
BUY: "BUY";
|
|
20
|
+
SELL: "SELL";
|
|
21
|
+
}>;
|
|
22
|
+
weight: z.ZodNumber;
|
|
23
|
+
}, z.core.$strip>>;
|
|
24
|
+
createdAt: z.ZodString;
|
|
25
|
+
updatedAt: z.ZodString;
|
|
26
|
+
}, z.core.$strip>>;
|
|
27
|
+
}, z.core.$strip>;
|
|
28
|
+
export type RecommendedBasketListResponse = z.output<typeof RecommendedBasketListResponse>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const SavedBasketLeg: z.ZodObject<{
|
|
3
|
+
id: z.ZodOptional<z.ZodString>;
|
|
3
4
|
symbol: z.ZodString;
|
|
4
5
|
side: z.ZodEnum<{
|
|
5
6
|
BUY: "BUY";
|
|
@@ -11,6 +12,7 @@ export declare const SavedBasket: z.ZodObject<{
|
|
|
11
12
|
id: z.ZodUUID;
|
|
12
13
|
name: z.ZodString;
|
|
13
14
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
15
|
+
id: z.ZodOptional<z.ZodString>;
|
|
14
16
|
symbol: z.ZodString;
|
|
15
17
|
side: z.ZodEnum<{
|
|
16
18
|
BUY: "BUY";
|
|
@@ -18,6 +20,7 @@ export declare const SavedBasket: z.ZodObject<{
|
|
|
18
20
|
}>;
|
|
19
21
|
weight: z.ZodNumber;
|
|
20
22
|
}, z.core.$strip>], z.ZodObject<{
|
|
23
|
+
id: z.ZodOptional<z.ZodString>;
|
|
21
24
|
symbol: z.ZodString;
|
|
22
25
|
side: z.ZodEnum<{
|
|
23
26
|
BUY: "BUY";
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { RefineLegIdMatchesSymbol } from '../../common/refinement';
|
|
3
|
+
import { Side, AssetWeight } from '../../common/schema';
|
|
4
|
+
import { InstrumentId } from '../../instrument';
|
|
4
5
|
|
|
5
6
|
const SavedBasketLeg = z.object({
|
|
7
|
+
// PHASE-1 LEG ID: mirrors `symbol` today; required in phase 3 when `symbol` becomes the ticker.
|
|
8
|
+
id: InstrumentId.optional().describe("Connector-native instrument id"),
|
|
6
9
|
symbol: InstrumentId,
|
|
7
10
|
side: Side,
|
|
8
11
|
weight: AssetWeight.describe("Share of total gross notional as a fraction (legs sum to 1)")
|
|
9
|
-
});
|
|
12
|
+
}).superRefine(RefineLegIdMatchesSymbol);
|
|
10
13
|
const SavedBasket = z.object({
|
|
11
14
|
id: z.uuid(),
|
|
12
15
|
name: z.string(),
|
|
@@ -2,6 +2,7 @@ import { z } from 'zod';
|
|
|
2
2
|
export declare const CreateSavedBasketPayload: z.ZodObject<{
|
|
3
3
|
name: z.ZodString;
|
|
4
4
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
5
|
+
id: z.ZodOptional<z.ZodString>;
|
|
5
6
|
symbol: z.ZodString;
|
|
6
7
|
side: z.ZodEnum<{
|
|
7
8
|
BUY: "BUY";
|
|
@@ -9,6 +10,7 @@ export declare const CreateSavedBasketPayload: z.ZodObject<{
|
|
|
9
10
|
}>;
|
|
10
11
|
weight: z.ZodNumber;
|
|
11
12
|
}, z.core.$strip>], z.ZodObject<{
|
|
13
|
+
id: z.ZodOptional<z.ZodString>;
|
|
12
14
|
symbol: z.ZodString;
|
|
13
15
|
side: z.ZodEnum<{
|
|
14
16
|
BUY: "BUY";
|
|
@@ -20,6 +22,7 @@ export declare const CreateSavedBasketPayload: z.ZodObject<{
|
|
|
20
22
|
export declare const UpdateSavedBasketPayload: z.ZodObject<{
|
|
21
23
|
name: z.ZodOptional<z.ZodString>;
|
|
22
24
|
legs: z.ZodOptional<z.ZodTuple<[z.ZodObject<{
|
|
25
|
+
id: z.ZodOptional<z.ZodString>;
|
|
23
26
|
symbol: z.ZodString;
|
|
24
27
|
side: z.ZodEnum<{
|
|
25
28
|
BUY: "BUY";
|
|
@@ -27,6 +30,7 @@ export declare const UpdateSavedBasketPayload: z.ZodObject<{
|
|
|
27
30
|
}>;
|
|
28
31
|
weight: z.ZodNumber;
|
|
29
32
|
}, z.core.$strip>], z.ZodObject<{
|
|
33
|
+
id: z.ZodOptional<z.ZodString>;
|
|
30
34
|
symbol: z.ZodString;
|
|
31
35
|
side: z.ZodEnum<{
|
|
32
36
|
BUY: "BUY";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { RefineUniqueSymbols, RefineWeightingSum } from '
|
|
2
|
+
import { RefineUniqueSymbols, RefineWeightingSum } from '../../common/refinement';
|
|
3
3
|
import { SavedBasketLeg } from './entities';
|
|
4
4
|
|
|
5
5
|
const SavedBasketName = z.string().trim().min(1, "Name is required").max(48).describe("Display name, unique per trade account (case-insensitive)");
|
|
@@ -4,6 +4,7 @@ export declare const SavedBasketListResponse: z.ZodObject<{
|
|
|
4
4
|
id: z.ZodUUID;
|
|
5
5
|
name: z.ZodString;
|
|
6
6
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
7
|
+
id: z.ZodOptional<z.ZodString>;
|
|
7
8
|
symbol: z.ZodString;
|
|
8
9
|
side: z.ZodEnum<{
|
|
9
10
|
BUY: "BUY";
|
|
@@ -11,6 +12,7 @@ export declare const SavedBasketListResponse: z.ZodObject<{
|
|
|
11
12
|
}>;
|
|
12
13
|
weight: z.ZodNumber;
|
|
13
14
|
}, z.core.$strip>], z.ZodObject<{
|
|
15
|
+
id: z.ZodOptional<z.ZodString>;
|
|
14
16
|
symbol: z.ZodString;
|
|
15
17
|
side: z.ZodEnum<{
|
|
16
18
|
BUY: "BUY";
|
|
@@ -28,6 +30,7 @@ export declare const CreateSavedBasketResponse: z.ZodObject<{
|
|
|
28
30
|
id: z.ZodUUID;
|
|
29
31
|
name: z.ZodString;
|
|
30
32
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
33
|
+
id: z.ZodOptional<z.ZodString>;
|
|
31
34
|
symbol: z.ZodString;
|
|
32
35
|
side: z.ZodEnum<{
|
|
33
36
|
BUY: "BUY";
|
|
@@ -35,6 +38,7 @@ export declare const CreateSavedBasketResponse: z.ZodObject<{
|
|
|
35
38
|
}>;
|
|
36
39
|
weight: z.ZodNumber;
|
|
37
40
|
}, z.core.$strip>], z.ZodObject<{
|
|
41
|
+
id: z.ZodOptional<z.ZodString>;
|
|
38
42
|
symbol: z.ZodString;
|
|
39
43
|
side: z.ZodEnum<{
|
|
40
44
|
BUY: "BUY";
|
|
@@ -52,6 +56,7 @@ export declare const UpdateSavedBasketResponse: z.ZodObject<{
|
|
|
52
56
|
id: z.ZodUUID;
|
|
53
57
|
name: z.ZodString;
|
|
54
58
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
59
|
+
id: z.ZodOptional<z.ZodString>;
|
|
55
60
|
symbol: z.ZodString;
|
|
56
61
|
side: z.ZodEnum<{
|
|
57
62
|
BUY: "BUY";
|
|
@@ -59,6 +64,7 @@ export declare const UpdateSavedBasketResponse: z.ZodObject<{
|
|
|
59
64
|
}>;
|
|
60
65
|
weight: z.ZodNumber;
|
|
61
66
|
}, z.core.$strip>], z.ZodObject<{
|
|
67
|
+
id: z.ZodOptional<z.ZodString>;
|
|
62
68
|
symbol: z.ZodString;
|
|
63
69
|
side: z.ZodEnum<{
|
|
64
70
|
BUY: "BUY";
|
package/dist/bundle.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export * from './auth';
|
|
2
|
+
export * from './baskets/recommended';
|
|
3
|
+
export * from './baskets/saved';
|
|
2
4
|
export * from './common/trade-legs';
|
|
3
5
|
export * from './connector';
|
|
4
6
|
export * from './execution';
|
|
@@ -17,7 +19,6 @@ export * from './portfolio';
|
|
|
17
19
|
export * from './position';
|
|
18
20
|
export * from './price';
|
|
19
21
|
export * from './rebalance';
|
|
20
|
-
export * from './saved-baskets';
|
|
21
22
|
export * from './schedule';
|
|
22
23
|
export * from './statistics';
|
|
23
24
|
export * from './sync';
|
package/dist/bundle.js
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export * from './auth';
|
|
2
|
+
export * from './baskets/recommended';
|
|
3
|
+
export * from './baskets/saved';
|
|
2
4
|
export * from './common/trade-legs';
|
|
3
5
|
export * from './connector';
|
|
4
6
|
export * from './execution';
|
|
@@ -17,7 +19,6 @@ export * from './portfolio';
|
|
|
17
19
|
export * from './position';
|
|
18
20
|
export * from './price';
|
|
19
21
|
export * from './rebalance';
|
|
20
|
-
export * from './saved-baskets';
|
|
21
22
|
export * from './schedule';
|
|
22
23
|
export * from './statistics';
|
|
23
24
|
export * from './sync';
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import z from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* PHASE-1 LEG ID WARNING: these refinements key on `symbol` only. Re-key them on
|
|
4
|
+
* `id ?? symbol` before clients start sending `id` (phase 2).
|
|
5
|
+
*/
|
|
2
6
|
export declare const RefineMinimumOneSymbol: <T extends {
|
|
3
7
|
symbol: string;
|
|
4
8
|
}[]>(basket: T, ctx: z.RefinementCtx) => void;
|
|
@@ -12,6 +16,11 @@ export declare const RefineTwoUniqueSymbols: <T extends {
|
|
|
12
16
|
export declare const RefineUniqueSymbols: <T extends {
|
|
13
17
|
symbol: string;
|
|
14
18
|
}[]>(basket: T, ctx: z.RefinementCtx) => void;
|
|
19
|
+
/** PHASE-1 LEG ID guard: a request's `id` must name the same instrument as `symbol`. Delete in phase 3. */
|
|
20
|
+
export declare const RefineLegIdMatchesSymbol: <T extends {
|
|
21
|
+
id?: string;
|
|
22
|
+
symbol: string;
|
|
23
|
+
}>(leg: T, ctx: z.RefinementCtx) => void;
|
|
15
24
|
export declare const RefineWeightingSum: <T extends {
|
|
16
25
|
weight: number;
|
|
17
26
|
}[]>(basket: T, ctx: z.RefinementCtx) => void;
|
|
@@ -40,6 +40,14 @@ const RefineUniqueSymbols = /* @__PURE__ */ __name((basket, ctx) => {
|
|
|
40
40
|
});
|
|
41
41
|
}
|
|
42
42
|
}, "RefineUniqueSymbols");
|
|
43
|
+
const RefineLegIdMatchesSymbol = /* @__PURE__ */ __name((leg, ctx) => {
|
|
44
|
+
if (leg.id !== void 0 && leg.id !== leg.symbol) {
|
|
45
|
+
ctx.addIssue({
|
|
46
|
+
code: "custom",
|
|
47
|
+
message: `Leg id and symbol must name the same instrument, got id "${leg.id}" and symbol "${leg.symbol}".`
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
}, "RefineLegIdMatchesSymbol");
|
|
43
51
|
const RefineWeightingSum = /* @__PURE__ */ __name((basket, ctx) => {
|
|
44
52
|
const totalWeight = basket.reduce((acc, curr) => acc + curr.weight, 0);
|
|
45
53
|
if (Math.abs(totalWeight - 1) > 1e-9) {
|
|
@@ -61,4 +69,4 @@ const RefineMinimumOneKeyValuePair = /* @__PURE__ */ __name((data, ctx) => {
|
|
|
61
69
|
}
|
|
62
70
|
}, "RefineMinimumOneKeyValuePair");
|
|
63
71
|
|
|
64
|
-
export { RefineMinimumOneKeyValuePair, RefineMinimumOneSymbol, RefineMinimumTwoSymbols, RefineTwoUniqueSymbols, RefineUniqueSymbols, RefineWeightingSum };
|
|
72
|
+
export { RefineLegIdMatchesSymbol, RefineMinimumOneKeyValuePair, RefineMinimumOneSymbol, RefineMinimumTwoSymbols, RefineTwoUniqueSymbols, RefineUniqueSymbols, RefineWeightingSum };
|
|
@@ -5,6 +5,7 @@ declare const TradeLegMode: z.ZodEnum<{
|
|
|
5
5
|
}>;
|
|
6
6
|
export type TradeLegMode = z.infer<typeof TradeLegMode>;
|
|
7
7
|
export declare const TradeLeg: z.ZodObject<{
|
|
8
|
+
id: z.ZodOptional<z.ZodString>;
|
|
8
9
|
symbol: z.ZodString;
|
|
9
10
|
side: z.ZodEnum<{
|
|
10
11
|
BUY: "BUY";
|
|
@@ -19,6 +20,7 @@ export declare const TradeLeg: z.ZodObject<{
|
|
|
19
20
|
}, z.core.$strip>;
|
|
20
21
|
export declare const TradeLegPostOnly: z.ZodObject<{
|
|
21
22
|
symbol: z.ZodString;
|
|
23
|
+
id: z.ZodOptional<z.ZodString>;
|
|
22
24
|
side: z.ZodEnum<{
|
|
23
25
|
BUY: "BUY";
|
|
24
26
|
SELL: "SELL";
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { InstrumentId } from '../instrument';
|
|
3
|
+
import { RefineLegIdMatchesSymbol } from './refinement';
|
|
3
4
|
import { UnsignedDecimalString, Side } from './schema';
|
|
4
5
|
|
|
5
6
|
const TradeLegMode = z.enum([
|
|
6
7
|
"QUANTITY",
|
|
7
8
|
"USD"
|
|
8
9
|
]);
|
|
9
|
-
const
|
|
10
|
+
const TradeLegShape = z.object({
|
|
11
|
+
/** PHASE-1 LEG ID: mirrors `symbol` today; required in phase 3 when `symbol` becomes the ticker. */
|
|
12
|
+
id: InstrumentId.optional(),
|
|
10
13
|
/**
|
|
11
14
|
* Instrument ID
|
|
12
15
|
*/
|
|
@@ -28,8 +31,9 @@ const TradeLeg = z.object({
|
|
|
28
31
|
*/
|
|
29
32
|
reduceOnly: z.boolean()
|
|
30
33
|
});
|
|
31
|
-
const
|
|
34
|
+
const TradeLeg = TradeLegShape.superRefine(RefineLegIdMatchesSymbol);
|
|
35
|
+
const TradeLegPostOnly = TradeLegShape.omit({
|
|
32
36
|
reduceOnly: true
|
|
33
|
-
});
|
|
37
|
+
}).superRefine(RefineLegIdMatchesSymbol);
|
|
34
38
|
|
|
35
39
|
export { TradeLeg, TradeLegPostOnly };
|
|
@@ -24,6 +24,7 @@ export declare const ExecutionLegMode: z.ZodEnum<{
|
|
|
24
24
|
}>;
|
|
25
25
|
export type ExecutionLegMode = z.infer<typeof ExecutionLegMode>;
|
|
26
26
|
declare const ExecutionLeg: z.ZodObject<{
|
|
27
|
+
id: z.ZodOptional<z.ZodString>;
|
|
27
28
|
symbol: z.ZodString;
|
|
28
29
|
side: z.ZodEnum<{
|
|
29
30
|
BUY: "BUY";
|
|
@@ -151,6 +152,7 @@ export declare const MarketOpenExecution: z.ZodObject<{
|
|
|
151
152
|
intent: z.ZodLiteral<"OPEN">;
|
|
152
153
|
orderType: z.ZodLiteral<"MARKET">;
|
|
153
154
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
155
|
+
id: z.ZodOptional<z.ZodString>;
|
|
154
156
|
symbol: z.ZodString;
|
|
155
157
|
side: z.ZodEnum<{
|
|
156
158
|
BUY: "BUY";
|
|
@@ -163,6 +165,7 @@ export declare const MarketOpenExecution: z.ZodObject<{
|
|
|
163
165
|
amount: z.ZodString;
|
|
164
166
|
reduceOnly: z.ZodBoolean;
|
|
165
167
|
}, z.core.$strip>], z.ZodObject<{
|
|
168
|
+
id: z.ZodOptional<z.ZodString>;
|
|
166
169
|
symbol: z.ZodString;
|
|
167
170
|
side: z.ZodEnum<{
|
|
168
171
|
BUY: "BUY";
|
|
@@ -234,6 +237,7 @@ export declare const MarketAdjustExecution: z.ZodObject<{
|
|
|
234
237
|
exposure: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`-${string}` | `+${string}`, string>>>;
|
|
235
238
|
}, z.core.$strip>;
|
|
236
239
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
240
|
+
id: z.ZodOptional<z.ZodString>;
|
|
237
241
|
symbol: z.ZodString;
|
|
238
242
|
side: z.ZodEnum<{
|
|
239
243
|
BUY: "BUY";
|
|
@@ -246,6 +250,7 @@ export declare const MarketAdjustExecution: z.ZodObject<{
|
|
|
246
250
|
amount: z.ZodString;
|
|
247
251
|
reduceOnly: z.ZodBoolean;
|
|
248
252
|
}, z.core.$strip>], z.ZodObject<{
|
|
253
|
+
id: z.ZodOptional<z.ZodString>;
|
|
249
254
|
symbol: z.ZodString;
|
|
250
255
|
side: z.ZodEnum<{
|
|
251
256
|
BUY: "BUY";
|
|
@@ -429,6 +434,7 @@ export declare const MarketExecution: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
429
434
|
intent: z.ZodLiteral<"OPEN">;
|
|
430
435
|
orderType: z.ZodLiteral<"MARKET">;
|
|
431
436
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
437
|
+
id: z.ZodOptional<z.ZodString>;
|
|
432
438
|
symbol: z.ZodString;
|
|
433
439
|
side: z.ZodEnum<{
|
|
434
440
|
BUY: "BUY";
|
|
@@ -441,6 +447,7 @@ export declare const MarketExecution: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
441
447
|
amount: z.ZodString;
|
|
442
448
|
reduceOnly: z.ZodBoolean;
|
|
443
449
|
}, z.core.$strip>], z.ZodObject<{
|
|
450
|
+
id: z.ZodOptional<z.ZodString>;
|
|
444
451
|
symbol: z.ZodString;
|
|
445
452
|
side: z.ZodEnum<{
|
|
446
453
|
BUY: "BUY";
|
|
@@ -511,6 +518,7 @@ export declare const MarketExecution: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
511
518
|
exposure: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`-${string}` | `+${string}`, string>>>;
|
|
512
519
|
}, z.core.$strip>;
|
|
513
520
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
521
|
+
id: z.ZodOptional<z.ZodString>;
|
|
514
522
|
symbol: z.ZodString;
|
|
515
523
|
side: z.ZodEnum<{
|
|
516
524
|
BUY: "BUY";
|
|
@@ -523,6 +531,7 @@ export declare const MarketExecution: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
523
531
|
amount: z.ZodString;
|
|
524
532
|
reduceOnly: z.ZodBoolean;
|
|
525
533
|
}, z.core.$strip>], z.ZodObject<{
|
|
534
|
+
id: z.ZodOptional<z.ZodString>;
|
|
526
535
|
symbol: z.ZodString;
|
|
527
536
|
side: z.ZodEnum<{
|
|
528
537
|
BUY: "BUY";
|
|
@@ -704,6 +713,7 @@ export declare const Execution: z.ZodDiscriminatedUnion<[z.ZodDiscriminatedUnion
|
|
|
704
713
|
intent: z.ZodLiteral<"OPEN">;
|
|
705
714
|
orderType: z.ZodLiteral<"MARKET">;
|
|
706
715
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
716
|
+
id: z.ZodOptional<z.ZodString>;
|
|
707
717
|
symbol: z.ZodString;
|
|
708
718
|
side: z.ZodEnum<{
|
|
709
719
|
BUY: "BUY";
|
|
@@ -716,6 +726,7 @@ export declare const Execution: z.ZodDiscriminatedUnion<[z.ZodDiscriminatedUnion
|
|
|
716
726
|
amount: z.ZodString;
|
|
717
727
|
reduceOnly: z.ZodBoolean;
|
|
718
728
|
}, z.core.$strip>], z.ZodObject<{
|
|
729
|
+
id: z.ZodOptional<z.ZodString>;
|
|
719
730
|
symbol: z.ZodString;
|
|
720
731
|
side: z.ZodEnum<{
|
|
721
732
|
BUY: "BUY";
|
|
@@ -786,6 +797,7 @@ export declare const Execution: z.ZodDiscriminatedUnion<[z.ZodDiscriminatedUnion
|
|
|
786
797
|
exposure: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`-${string}` | `+${string}`, string>>>;
|
|
787
798
|
}, z.core.$strip>;
|
|
788
799
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
800
|
+
id: z.ZodOptional<z.ZodString>;
|
|
789
801
|
symbol: z.ZodString;
|
|
790
802
|
side: z.ZodEnum<{
|
|
791
803
|
BUY: "BUY";
|
|
@@ -798,6 +810,7 @@ export declare const Execution: z.ZodDiscriminatedUnion<[z.ZodDiscriminatedUnion
|
|
|
798
810
|
amount: z.ZodString;
|
|
799
811
|
reduceOnly: z.ZodBoolean;
|
|
800
812
|
}, z.core.$strip>], z.ZodObject<{
|
|
813
|
+
id: z.ZodOptional<z.ZodString>;
|
|
801
814
|
symbol: z.ZodString;
|
|
802
815
|
side: z.ZodEnum<{
|
|
803
816
|
BUY: "BUY";
|
|
@@ -56,6 +56,7 @@ export declare const ExecutionListResponse: z.ZodObject<{
|
|
|
56
56
|
intent: z.ZodLiteral<"OPEN">;
|
|
57
57
|
orderType: z.ZodLiteral<"MARKET">;
|
|
58
58
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
59
|
+
id: z.ZodOptional<z.ZodString>;
|
|
59
60
|
symbol: z.ZodString;
|
|
60
61
|
side: z.ZodEnum<{
|
|
61
62
|
BUY: "BUY";
|
|
@@ -68,6 +69,7 @@ export declare const ExecutionListResponse: z.ZodObject<{
|
|
|
68
69
|
amount: z.ZodString;
|
|
69
70
|
reduceOnly: z.ZodBoolean;
|
|
70
71
|
}, z.core.$strip>], z.ZodObject<{
|
|
72
|
+
id: z.ZodOptional<z.ZodString>;
|
|
71
73
|
symbol: z.ZodString;
|
|
72
74
|
side: z.ZodEnum<{
|
|
73
75
|
BUY: "BUY";
|
|
@@ -138,6 +140,7 @@ export declare const ExecutionListResponse: z.ZodObject<{
|
|
|
138
140
|
exposure: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`-${string}` | `+${string}`, string>>>;
|
|
139
141
|
}, z.core.$strip>;
|
|
140
142
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
143
|
+
id: z.ZodOptional<z.ZodString>;
|
|
141
144
|
symbol: z.ZodString;
|
|
142
145
|
side: z.ZodEnum<{
|
|
143
146
|
BUY: "BUY";
|
|
@@ -150,6 +153,7 @@ export declare const ExecutionListResponse: z.ZodObject<{
|
|
|
150
153
|
amount: z.ZodString;
|
|
151
154
|
reduceOnly: z.ZodBoolean;
|
|
152
155
|
}, z.core.$strip>], z.ZodObject<{
|
|
156
|
+
id: z.ZodOptional<z.ZodString>;
|
|
153
157
|
symbol: z.ZodString;
|
|
154
158
|
side: z.ZodEnum<{
|
|
155
159
|
BUY: "BUY";
|
|
@@ -334,6 +338,7 @@ export declare const GetExecutionResponse: z.ZodObject<{
|
|
|
334
338
|
intent: z.ZodLiteral<"OPEN">;
|
|
335
339
|
orderType: z.ZodLiteral<"MARKET">;
|
|
336
340
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
341
|
+
id: z.ZodOptional<z.ZodString>;
|
|
337
342
|
symbol: z.ZodString;
|
|
338
343
|
side: z.ZodEnum<{
|
|
339
344
|
BUY: "BUY";
|
|
@@ -346,6 +351,7 @@ export declare const GetExecutionResponse: z.ZodObject<{
|
|
|
346
351
|
amount: z.ZodString;
|
|
347
352
|
reduceOnly: z.ZodBoolean;
|
|
348
353
|
}, z.core.$strip>], z.ZodObject<{
|
|
354
|
+
id: z.ZodOptional<z.ZodString>;
|
|
349
355
|
symbol: z.ZodString;
|
|
350
356
|
side: z.ZodEnum<{
|
|
351
357
|
BUY: "BUY";
|
|
@@ -416,6 +422,7 @@ export declare const GetExecutionResponse: z.ZodObject<{
|
|
|
416
422
|
exposure: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`-${string}` | `+${string}`, string>>>;
|
|
417
423
|
}, z.core.$strip>;
|
|
418
424
|
legs: z.ZodTuple<[z.ZodObject<{
|
|
425
|
+
id: z.ZodOptional<z.ZodString>;
|
|
419
426
|
symbol: z.ZodString;
|
|
420
427
|
side: z.ZodEnum<{
|
|
421
428
|
BUY: "BUY";
|
|
@@ -428,6 +435,7 @@ export declare const GetExecutionResponse: z.ZodObject<{
|
|
|
428
435
|
amount: z.ZodString;
|
|
429
436
|
reduceOnly: z.ZodBoolean;
|
|
430
437
|
}, z.core.$strip>], z.ZodObject<{
|
|
438
|
+
id: z.ZodOptional<z.ZodString>;
|
|
431
439
|
symbol: z.ZodString;
|
|
432
440
|
side: z.ZodEnum<{
|
|
433
441
|
BUY: "BUY";
|