@proton/wrap-constants 0.2.60 → 0.2.62
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/parsers/dex.d.ts +20 -0
- package/dist/wrap-constants.cjs.development.js +11 -1
- package/dist/wrap-constants.cjs.development.js.map +1 -1
- package/dist/wrap-constants.cjs.production.min.js +1 -1
- package/dist/wrap-constants.cjs.production.min.js.map +1 -1
- package/dist/wrap-constants.esm.js +11 -2
- package/dist/wrap-constants.esm.js.map +1 -1
- package/package.json +2 -2
- package/src/parsers/dex.ts +9 -0
package/dist/parsers/dex.d.ts
CHANGED
|
@@ -163,13 +163,32 @@ export declare const orderHistoryParser: z.ZodObject<{
|
|
|
163
163
|
trx_id: string;
|
|
164
164
|
}>;
|
|
165
165
|
export declare type OrderHistory = z.infer<typeof orderHistoryParser>;
|
|
166
|
+
export declare const getOpenOrdersParser: z.ZodObject<{
|
|
167
|
+
account: z.ZodString;
|
|
168
|
+
symbol: z.ZodOptional<z.ZodString>;
|
|
169
|
+
offset: z.ZodDefault<z.ZodString>;
|
|
170
|
+
limit: z.ZodEffects<z.ZodDefault<z.ZodString>, string, string | undefined>;
|
|
171
|
+
}, "strip", z.ZodTypeAny, {
|
|
172
|
+
symbol?: string | undefined;
|
|
173
|
+
limit: string;
|
|
174
|
+
account: string;
|
|
175
|
+
offset: string;
|
|
176
|
+
}, {
|
|
177
|
+
symbol?: string | undefined;
|
|
178
|
+
limit?: string | undefined;
|
|
179
|
+
offset?: string | undefined;
|
|
180
|
+
account: string;
|
|
181
|
+
}>;
|
|
182
|
+
export declare type GetOpenOrders = z.infer<typeof getOpenOrdersParser>;
|
|
166
183
|
export declare const getOrderHistoryParser: z.ZodObject<{
|
|
167
184
|
account: z.ZodString;
|
|
168
185
|
symbol: z.ZodOptional<z.ZodString>;
|
|
169
186
|
offset: z.ZodDefault<z.ZodString>;
|
|
170
187
|
limit: z.ZodEffects<z.ZodDefault<z.ZodString>, string, string | undefined>;
|
|
188
|
+
transaction_id: z.ZodOptional<z.ZodString>;
|
|
171
189
|
}, "strip", z.ZodTypeAny, {
|
|
172
190
|
symbol?: string | undefined;
|
|
191
|
+
transaction_id?: string | undefined;
|
|
173
192
|
limit: string;
|
|
174
193
|
account: string;
|
|
175
194
|
offset: string;
|
|
@@ -177,6 +196,7 @@ export declare const getOrderHistoryParser: z.ZodObject<{
|
|
|
177
196
|
symbol?: string | undefined;
|
|
178
197
|
limit?: string | undefined;
|
|
179
198
|
offset?: string | undefined;
|
|
199
|
+
transaction_id?: string | undefined;
|
|
180
200
|
account: string;
|
|
181
201
|
}>;
|
|
182
202
|
export declare type GetOrderHistory = z.infer<typeof getOrderHistoryParser>;
|
|
@@ -1533,7 +1533,7 @@ var orderHistoryParser = /*#__PURE__*/z.object({
|
|
|
1533
1533
|
quantity_change: /*#__PURE__*/z.number(),
|
|
1534
1534
|
trx_id: /*#__PURE__*/z.string()
|
|
1535
1535
|
});
|
|
1536
|
-
var
|
|
1536
|
+
var getOpenOrdersParser = /*#__PURE__*/z.object({
|
|
1537
1537
|
account: /*#__PURE__*/z.string(),
|
|
1538
1538
|
symbol: /*#__PURE__*/z.string().optional(),
|
|
1539
1539
|
offset: /*#__PURE__*/z.string()["default"]("0"),
|
|
@@ -1541,6 +1541,15 @@ var getOrderHistoryParser = /*#__PURE__*/z.object({
|
|
|
1541
1541
|
return +n <= 250;
|
|
1542
1542
|
}, 'Max limit is 250')
|
|
1543
1543
|
});
|
|
1544
|
+
var getOrderHistoryParser = /*#__PURE__*/z.object({
|
|
1545
|
+
account: /*#__PURE__*/z.string(),
|
|
1546
|
+
symbol: /*#__PURE__*/z.string().optional(),
|
|
1547
|
+
offset: /*#__PURE__*/z.string()["default"]("0"),
|
|
1548
|
+
limit: /*#__PURE__*/z.string()["default"]("100").refine(function (n) {
|
|
1549
|
+
return +n <= 250;
|
|
1550
|
+
}, 'Max limit is 250'),
|
|
1551
|
+
transaction_id: /*#__PURE__*/z.string().optional()
|
|
1552
|
+
});
|
|
1544
1553
|
var getOrderHistoryResponseParser = /*#__PURE__*/z.object({
|
|
1545
1554
|
sync: /*#__PURE__*/z.number(),
|
|
1546
1555
|
count: /*#__PURE__*/z.number(),
|
|
@@ -2113,6 +2122,7 @@ exports.getLeaderboardResponseParser = getLeaderboardResponseParser;
|
|
|
2113
2122
|
exports.getMarketsResponseParser = getMarketsResponseParser;
|
|
2114
2123
|
exports.getOhlcvParser = getOhlcvParser;
|
|
2115
2124
|
exports.getOhlcvResponseParser = getOhlcvResponseParser;
|
|
2125
|
+
exports.getOpenOrdersParser = getOpenOrdersParser;
|
|
2116
2126
|
exports.getOrderHistoryParser = getOrderHistoryParser;
|
|
2117
2127
|
exports.getOrderHistoryResponseParser = getOrderHistoryResponseParser;
|
|
2118
2128
|
exports.getOrderParser = getOrderParser;
|