@proton/wrap-constants 0.2.135 → 0.2.136
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/index.d.ts +50 -4
- package/dist/index.js +21 -2
- package/dist/index.mjs +19 -2
- package/package.json +2 -2
- package/src/parsers/dex.ts +24 -2
package/dist/index.d.ts
CHANGED
|
@@ -6360,6 +6360,7 @@ declare const wrapParser: z.ZodObject<{
|
|
|
6360
6360
|
}>;
|
|
6361
6361
|
declare type Wrap = z.infer<typeof wrapParser>;
|
|
6362
6362
|
|
|
6363
|
+
declare const sortDirectionEnum: z.ZodEnum<["asc", "desc"]>;
|
|
6363
6364
|
/**
|
|
6364
6365
|
* OHLCV
|
|
6365
6366
|
*/
|
|
@@ -10491,7 +10492,7 @@ declare const getHistoryActionsParser: z.ZodObject<{
|
|
|
10491
10492
|
account_seq_to: z.ZodOptional<z.ZodString>;
|
|
10492
10493
|
date_from: z.ZodOptional<z.ZodString>;
|
|
10493
10494
|
date_to: z.ZodOptional<z.ZodString>;
|
|
10494
|
-
direction: z.ZodOptional<z.
|
|
10495
|
+
direction: z.ZodOptional<z.ZodEnum<["asc", "desc"]>>;
|
|
10495
10496
|
limit: z.ZodEffects<z.ZodDefault<z.ZodNumber>, number, number | undefined>;
|
|
10496
10497
|
}, "strip", z.ZodTypeAny, {
|
|
10497
10498
|
account: string;
|
|
@@ -10501,7 +10502,7 @@ declare const getHistoryActionsParser: z.ZodObject<{
|
|
|
10501
10502
|
account_seq_to?: string | undefined;
|
|
10502
10503
|
date_from?: string | undefined;
|
|
10503
10504
|
date_to?: string | undefined;
|
|
10504
|
-
direction?:
|
|
10505
|
+
direction?: "asc" | "desc" | undefined;
|
|
10505
10506
|
}, {
|
|
10506
10507
|
account: string;
|
|
10507
10508
|
contract_filters?: string | string[] | undefined;
|
|
@@ -10509,7 +10510,7 @@ declare const getHistoryActionsParser: z.ZodObject<{
|
|
|
10509
10510
|
account_seq_to?: string | undefined;
|
|
10510
10511
|
date_from?: string | undefined;
|
|
10511
10512
|
date_to?: string | undefined;
|
|
10512
|
-
direction?:
|
|
10513
|
+
direction?: "asc" | "desc" | undefined;
|
|
10513
10514
|
limit?: number | undefined;
|
|
10514
10515
|
}>;
|
|
10515
10516
|
declare type GetHistoryActions = z.input<typeof getHistoryActionsParser>;
|
|
@@ -11126,6 +11127,51 @@ declare const getHistoryActionsResponseParser: z.ZodObject<{
|
|
|
11126
11127
|
last_irreversible_block_num: number;
|
|
11127
11128
|
}>;
|
|
11128
11129
|
declare type GetHistoryActionsResponse = z.infer<typeof getHistoryActionsResponseParser>;
|
|
11130
|
+
/**
|
|
11131
|
+
* History transfers
|
|
11132
|
+
*/
|
|
11133
|
+
declare const getHistoryTransfersParser: z.ZodObject<{
|
|
11134
|
+
transfer_from: z.ZodOptional<z.ZodString>;
|
|
11135
|
+
transfer_to: z.ZodOptional<z.ZodString>;
|
|
11136
|
+
contract: z.ZodOptional<z.ZodString>;
|
|
11137
|
+
symbol: z.ZodOptional<z.ZodString>;
|
|
11138
|
+
amount_min: z.ZodOptional<z.ZodString>;
|
|
11139
|
+
amount_max: z.ZodOptional<z.ZodString>;
|
|
11140
|
+
date_from: z.ZodOptional<z.ZodString>;
|
|
11141
|
+
date_to: z.ZodOptional<z.ZodString>;
|
|
11142
|
+
global_seq_from: z.ZodOptional<z.ZodString>;
|
|
11143
|
+
global_seq_to: z.ZodOptional<z.ZodString>;
|
|
11144
|
+
direction: z.ZodOptional<z.ZodEnum<["asc", "desc"]>>;
|
|
11145
|
+
limit: z.ZodEffects<z.ZodDefault<z.ZodNumber>, number, number | undefined>;
|
|
11146
|
+
}, "strip", z.ZodTypeAny, {
|
|
11147
|
+
limit: number;
|
|
11148
|
+
transfer_from?: string | undefined;
|
|
11149
|
+
transfer_to?: string | undefined;
|
|
11150
|
+
contract?: string | undefined;
|
|
11151
|
+
symbol?: string | undefined;
|
|
11152
|
+
amount_min?: string | undefined;
|
|
11153
|
+
amount_max?: string | undefined;
|
|
11154
|
+
date_from?: string | undefined;
|
|
11155
|
+
date_to?: string | undefined;
|
|
11156
|
+
global_seq_from?: string | undefined;
|
|
11157
|
+
global_seq_to?: string | undefined;
|
|
11158
|
+
direction?: "asc" | "desc" | undefined;
|
|
11159
|
+
}, {
|
|
11160
|
+
transfer_from?: string | undefined;
|
|
11161
|
+
transfer_to?: string | undefined;
|
|
11162
|
+
contract?: string | undefined;
|
|
11163
|
+
symbol?: string | undefined;
|
|
11164
|
+
amount_min?: string | undefined;
|
|
11165
|
+
amount_max?: string | undefined;
|
|
11166
|
+
date_from?: string | undefined;
|
|
11167
|
+
date_to?: string | undefined;
|
|
11168
|
+
global_seq_from?: string | undefined;
|
|
11169
|
+
global_seq_to?: string | undefined;
|
|
11170
|
+
direction?: "asc" | "desc" | undefined;
|
|
11171
|
+
limit?: number | undefined;
|
|
11172
|
+
}>;
|
|
11173
|
+
declare type GetHistoryTransfers = z.input<typeof getHistoryTransfersParser>;
|
|
11174
|
+
declare type GetHistoryTransfersParsed = z.output<typeof getHistoryTransfersParser>;
|
|
11129
11175
|
/**
|
|
11130
11176
|
* Basic Types
|
|
11131
11177
|
*/
|
|
@@ -12172,4 +12218,4 @@ declare const isInputInvalid: (data: string, value: string | number, pool: {
|
|
|
12172
12218
|
}) => boolean;
|
|
12173
12219
|
declare const applyDiscountToFee: (fee: number, staked: number) => number;
|
|
12174
12220
|
|
|
12175
|
-
export { Address, Authorization, Authorizations, BloksRate, BloksRates, Chains, Coin, CoinWallet, CurrencyStat, CurrencyStats, Daily, DbHistoryTransaction, DbMarket, DepositBody, Depth, ExchangeRate, ExchangeRates, ExtendedAsset, ExtendedAssetParser, ExtendedToken, ExtendedTokenWithRate, FEE_FACTOR, GenerateAddressBody, GenerateAddressResponse, GenerateAuth, GenerateAuthBaseAction, GetDailyResponse, GetDepth, GetDepthParsed, GetDepthResponse, GetHistoryActions, GetHistoryActionsParsed, GetHistoryActionsResponse, GetHistoryTransactionResponse, GetLeaderboard, GetLeaderboardParsed, GetLeaderboardResponse, GetMarketsResponse, GetOHLCV, GetOHLCVParsed, GetOHLCVResponse, GetOpenOrders, GetOpenOrdersParsed, GetOpenOrdersResponse, GetOrderHistory, GetOrderHistoryParsed, GetOrderHistoryResponse, GetOrderLifecycle, GetOrderLifecycleParsed, GetOrderLifecycleResponse, GetReferralTotals, GetReferralTotalsParsed, GetReferralTotalsResponse, GetReferrals, GetReferralsParsed, GetReferralsResponse, GetSyncResponse, GetTradeHistory, GetTradeHistoryParsed, GetTradeHistoryResponse, GetTrades, GetTradesParsed, GetTradesResponse, Graph, HistoryAccountRamDelta, HistoryAct, HistoryAction, HistoryActionTrace, HistoryPartial, HistoryReceipt, HistoryTrace, HistoryTransaction, ILink, INode, ITopics, Leaderboard, LoginAccountParamsV3, Market, MetalTransaction, Networks, OHLCV, OpenOrder, OrderHistory, OrderLog, OtcOrderResponse, OtcQuoteBody, OtcQuoteResponse, Pool, PoolTable, PostSerializeOrder, PostSerializeOrderResponse, PostSubmitOrder, PostSubmitOrderResponse, Providers, Rate, RawPool, Referral, ReferralTotal, Status, Sync, TOPICS, Trade, TradeLog, Type, WRAP_AUTH_ACTION, WRAP_CONTRACT, Wallet, WithdrawBody, WithdrawBodyBaseAction, WithdrawHistoryMetalResponse, WithdrawHistoryMetalSwap, WithdrawMetalResponse, WithdrawalFeeQuote, Wrap, WrapSetConf, WrapStart, accountParser, accountRamDeltaParser, actParser, actionTraceParser, addressParser, applyDiscountToFee, authorizationParser, authorizationsParser, baseActionParser, baseActionSerializedParser, bloksRatesParser, compute_liquidity, compute_transfer, compute_transfer_curve, createAbstractAuthParser, dailyParser, dbHistoryTransactionParser, dbMarketParser, depositBodyParser, depthParser, exchangeRateParser, exchangeRatesParser, explorerLinkByChain, fillType, generateAddressBodyParser, generateAddressResponse, generateAuthParser, getDailyResponseParser, getDepthParser, getDepthResponseParser, getHistoryActionsParser, getHistoryActionsResponseParser, getHistoryTransactionResponseParser, getLeaderboardParser, getLeaderboardResponseParser, getMarketsResponseParser, getOhlcvParser, getOhlcvResponseParser, getOpenOrdersParser, getOpenOrdersResponseParser, getOrderHistoryParser, getOrderHistoryResponseParser, getOrderLifecycleParser, getOrderLifecycleResponseParser, getReferralTotalsParser, getReferralTotalsResponseParser, getReferralsParser, getReferralsResponseParser, getSyncResponseParser, getTradeHistoryParser, getTradeHistoryResponseParser, getTradesParser, getTradesResponseParser, historyActionParser, historyPartialParser, historyTransactionParser, initializeCoins, initializeConstants, isInputInvalid, isSameToken, leaderboardParser, logStatus, loginAccountParamsV3Parser, marketParser, median, metalTransactionParser, ohlcvParser, openOrderParser, orderHistoryParser, orderLogParser, orderSide, orderType, otcOrderResponseParser, otcQuoteBodyParser, otcQuoteResponseParser, postSerializeOrderParser, postSerializeOrderResponseParser, postSubmitOrderParser, postSubmitOrderResponseParser, protonExplorerTxUrl, rateParser, receiptParser, refferalParser, refferalTotalParser, similarChains, singleActionTransactionParser, syncParser, traceParser, tradeLogParser, tradeParser, webauthActionParser, withdrawBodyParser, withdrawHistoryMetalResponseParser, withdrawHistoryMetalSwapParser, withdrawMetalResponseParser, withdrawalFeeQuoteParser, wrapParser, wrapSetConfParser, wrapStartParser };
|
|
12221
|
+
export { Address, Authorization, Authorizations, BloksRate, BloksRates, Chains, Coin, CoinWallet, CurrencyStat, CurrencyStats, Daily, DbHistoryTransaction, DbMarket, DepositBody, Depth, ExchangeRate, ExchangeRates, ExtendedAsset, ExtendedAssetParser, ExtendedToken, ExtendedTokenWithRate, FEE_FACTOR, GenerateAddressBody, GenerateAddressResponse, GenerateAuth, GenerateAuthBaseAction, GetDailyResponse, GetDepth, GetDepthParsed, GetDepthResponse, GetHistoryActions, GetHistoryActionsParsed, GetHistoryActionsResponse, GetHistoryTransactionResponse, GetHistoryTransfers, GetHistoryTransfersParsed, GetLeaderboard, GetLeaderboardParsed, GetLeaderboardResponse, GetMarketsResponse, GetOHLCV, GetOHLCVParsed, GetOHLCVResponse, GetOpenOrders, GetOpenOrdersParsed, GetOpenOrdersResponse, GetOrderHistory, GetOrderHistoryParsed, GetOrderHistoryResponse, GetOrderLifecycle, GetOrderLifecycleParsed, GetOrderLifecycleResponse, GetReferralTotals, GetReferralTotalsParsed, GetReferralTotalsResponse, GetReferrals, GetReferralsParsed, GetReferralsResponse, GetSyncResponse, GetTradeHistory, GetTradeHistoryParsed, GetTradeHistoryResponse, GetTrades, GetTradesParsed, GetTradesResponse, Graph, HistoryAccountRamDelta, HistoryAct, HistoryAction, HistoryActionTrace, HistoryPartial, HistoryReceipt, HistoryTrace, HistoryTransaction, ILink, INode, ITopics, Leaderboard, LoginAccountParamsV3, Market, MetalTransaction, Networks, OHLCV, OpenOrder, OrderHistory, OrderLog, OtcOrderResponse, OtcQuoteBody, OtcQuoteResponse, Pool, PoolTable, PostSerializeOrder, PostSerializeOrderResponse, PostSubmitOrder, PostSubmitOrderResponse, Providers, Rate, RawPool, Referral, ReferralTotal, Status, Sync, TOPICS, Trade, TradeLog, Type, WRAP_AUTH_ACTION, WRAP_CONTRACT, Wallet, WithdrawBody, WithdrawBodyBaseAction, WithdrawHistoryMetalResponse, WithdrawHistoryMetalSwap, WithdrawMetalResponse, WithdrawalFeeQuote, Wrap, WrapSetConf, WrapStart, accountParser, accountRamDeltaParser, actParser, actionTraceParser, addressParser, applyDiscountToFee, authorizationParser, authorizationsParser, baseActionParser, baseActionSerializedParser, bloksRatesParser, compute_liquidity, compute_transfer, compute_transfer_curve, createAbstractAuthParser, dailyParser, dbHistoryTransactionParser, dbMarketParser, depositBodyParser, depthParser, exchangeRateParser, exchangeRatesParser, explorerLinkByChain, fillType, generateAddressBodyParser, generateAddressResponse, generateAuthParser, getDailyResponseParser, getDepthParser, getDepthResponseParser, getHistoryActionsParser, getHistoryActionsResponseParser, getHistoryTransactionResponseParser, getHistoryTransfersParser, getLeaderboardParser, getLeaderboardResponseParser, getMarketsResponseParser, getOhlcvParser, getOhlcvResponseParser, getOpenOrdersParser, getOpenOrdersResponseParser, getOrderHistoryParser, getOrderHistoryResponseParser, getOrderLifecycleParser, getOrderLifecycleResponseParser, getReferralTotalsParser, getReferralTotalsResponseParser, getReferralsParser, getReferralsResponseParser, getSyncResponseParser, getTradeHistoryParser, getTradeHistoryResponseParser, getTradesParser, getTradesResponseParser, historyActionParser, historyPartialParser, historyTransactionParser, initializeCoins, initializeConstants, isInputInvalid, isSameToken, leaderboardParser, logStatus, loginAccountParamsV3Parser, marketParser, median, metalTransactionParser, ohlcvParser, openOrderParser, orderHistoryParser, orderLogParser, orderSide, orderType, otcOrderResponseParser, otcQuoteBodyParser, otcQuoteResponseParser, postSerializeOrderParser, postSerializeOrderResponseParser, postSubmitOrderParser, postSubmitOrderResponseParser, protonExplorerTxUrl, rateParser, receiptParser, refferalParser, refferalTotalParser, similarChains, singleActionTransactionParser, sortDirectionEnum, syncParser, traceParser, tradeLogParser, tradeParser, webauthActionParser, withdrawBodyParser, withdrawHistoryMetalResponseParser, withdrawHistoryMetalSwapParser, withdrawMetalResponseParser, withdrawalFeeQuoteParser, wrapParser, wrapSetConfParser, wrapStartParser };
|
package/dist/index.js
CHANGED
|
@@ -77,6 +77,7 @@ __export(src_exports, {
|
|
|
77
77
|
getHistoryActionsParser: () => getHistoryActionsParser,
|
|
78
78
|
getHistoryActionsResponseParser: () => getHistoryActionsResponseParser,
|
|
79
79
|
getHistoryTransactionResponseParser: () => getHistoryTransactionResponseParser,
|
|
80
|
+
getHistoryTransfersParser: () => getHistoryTransfersParser,
|
|
80
81
|
getLeaderboardParser: () => getLeaderboardParser,
|
|
81
82
|
getLeaderboardResponseParser: () => getLeaderboardResponseParser,
|
|
82
83
|
getMarketsResponseParser: () => getMarketsResponseParser,
|
|
@@ -130,6 +131,7 @@ __export(src_exports, {
|
|
|
130
131
|
refferalTotalParser: () => refferalTotalParser,
|
|
131
132
|
similarChains: () => similarChains,
|
|
132
133
|
singleActionTransactionParser: () => singleActionTransactionParser,
|
|
134
|
+
sortDirectionEnum: () => sortDirectionEnum,
|
|
133
135
|
syncParser: () => syncParser,
|
|
134
136
|
traceParser: () => traceParser,
|
|
135
137
|
tradeLogParser: () => tradeLogParser,
|
|
@@ -1912,6 +1914,7 @@ var contractFiltersParser = z11.array(z11.string()).or(z11.string()).optional().
|
|
|
1912
1914
|
return [];
|
|
1913
1915
|
return Array.isArray(oids) ? oids : [oids];
|
|
1914
1916
|
});
|
|
1917
|
+
var sortDirectionEnum = z11.enum(["asc", "desc"]);
|
|
1915
1918
|
var ohlcvParser = z11.object({
|
|
1916
1919
|
time: z11.number(),
|
|
1917
1920
|
open: z11.number(),
|
|
@@ -2333,13 +2336,13 @@ var getHistoryTransactionResponseParser = z11.object({
|
|
|
2333
2336
|
data: historyTransactionParser.nullable()
|
|
2334
2337
|
});
|
|
2335
2338
|
var getHistoryActionsParser = z11.object({
|
|
2336
|
-
account: z11.string(),
|
|
2339
|
+
account: z11.string().min(1, { message: "account is required" }),
|
|
2337
2340
|
contract_filters: contractFiltersParser,
|
|
2338
2341
|
account_seq_from: z11.string().optional(),
|
|
2339
2342
|
account_seq_to: z11.string().optional(),
|
|
2340
2343
|
date_from: z11.string().optional(),
|
|
2341
2344
|
date_to: z11.string().optional(),
|
|
2342
|
-
direction:
|
|
2345
|
+
direction: sortDirectionEnum.optional(),
|
|
2343
2346
|
limit: createLimit(100, 250)
|
|
2344
2347
|
});
|
|
2345
2348
|
var historyActionParser = z11.object({
|
|
@@ -2356,6 +2359,20 @@ var getHistoryActionsResponseParser = z11.object({
|
|
|
2356
2359
|
last_irreversible_block_num: z11.number(),
|
|
2357
2360
|
data: z11.array(historyActionParser)
|
|
2358
2361
|
});
|
|
2362
|
+
var getHistoryTransfersParser = z11.object({
|
|
2363
|
+
transfer_from: z11.string().optional(),
|
|
2364
|
+
transfer_to: z11.string().optional(),
|
|
2365
|
+
contract: z11.string().optional(),
|
|
2366
|
+
symbol: z11.string().optional(),
|
|
2367
|
+
amount_min: z11.string().optional(),
|
|
2368
|
+
amount_max: z11.string().optional(),
|
|
2369
|
+
date_from: z11.string().optional(),
|
|
2370
|
+
date_to: z11.string().optional(),
|
|
2371
|
+
global_seq_from: z11.string().optional(),
|
|
2372
|
+
global_seq_to: z11.string().optional(),
|
|
2373
|
+
direction: sortDirectionEnum.optional(),
|
|
2374
|
+
limit: createLimit(100, 250)
|
|
2375
|
+
});
|
|
2359
2376
|
var orderType = /* @__PURE__ */ ((orderType2) => {
|
|
2360
2377
|
orderType2[orderType2["ORDERBOOK"] = 0] = "ORDERBOOK";
|
|
2361
2378
|
orderType2[orderType2["LIMIT"] = 1] = "LIMIT";
|
|
@@ -4105,6 +4122,7 @@ var applyDiscountToFee = (fee, staked) => {
|
|
|
4105
4122
|
getHistoryActionsParser,
|
|
4106
4123
|
getHistoryActionsResponseParser,
|
|
4107
4124
|
getHistoryTransactionResponseParser,
|
|
4125
|
+
getHistoryTransfersParser,
|
|
4108
4126
|
getLeaderboardParser,
|
|
4109
4127
|
getLeaderboardResponseParser,
|
|
4110
4128
|
getMarketsResponseParser,
|
|
@@ -4158,6 +4176,7 @@ var applyDiscountToFee = (fee, staked) => {
|
|
|
4158
4176
|
refferalTotalParser,
|
|
4159
4177
|
similarChains,
|
|
4160
4178
|
singleActionTransactionParser,
|
|
4179
|
+
sortDirectionEnum,
|
|
4161
4180
|
syncParser,
|
|
4162
4181
|
traceParser,
|
|
4163
4182
|
tradeLogParser,
|
package/dist/index.mjs
CHANGED
|
@@ -1764,6 +1764,7 @@ var contractFiltersParser = z11.array(z11.string()).or(z11.string()).optional().
|
|
|
1764
1764
|
return [];
|
|
1765
1765
|
return Array.isArray(oids) ? oids : [oids];
|
|
1766
1766
|
});
|
|
1767
|
+
var sortDirectionEnum = z11.enum(["asc", "desc"]);
|
|
1767
1768
|
var ohlcvParser = z11.object({
|
|
1768
1769
|
time: z11.number(),
|
|
1769
1770
|
open: z11.number(),
|
|
@@ -2185,13 +2186,13 @@ var getHistoryTransactionResponseParser = z11.object({
|
|
|
2185
2186
|
data: historyTransactionParser.nullable()
|
|
2186
2187
|
});
|
|
2187
2188
|
var getHistoryActionsParser = z11.object({
|
|
2188
|
-
account: z11.string(),
|
|
2189
|
+
account: z11.string().min(1, { message: "account is required" }),
|
|
2189
2190
|
contract_filters: contractFiltersParser,
|
|
2190
2191
|
account_seq_from: z11.string().optional(),
|
|
2191
2192
|
account_seq_to: z11.string().optional(),
|
|
2192
2193
|
date_from: z11.string().optional(),
|
|
2193
2194
|
date_to: z11.string().optional(),
|
|
2194
|
-
direction:
|
|
2195
|
+
direction: sortDirectionEnum.optional(),
|
|
2195
2196
|
limit: createLimit(100, 250)
|
|
2196
2197
|
});
|
|
2197
2198
|
var historyActionParser = z11.object({
|
|
@@ -2208,6 +2209,20 @@ var getHistoryActionsResponseParser = z11.object({
|
|
|
2208
2209
|
last_irreversible_block_num: z11.number(),
|
|
2209
2210
|
data: z11.array(historyActionParser)
|
|
2210
2211
|
});
|
|
2212
|
+
var getHistoryTransfersParser = z11.object({
|
|
2213
|
+
transfer_from: z11.string().optional(),
|
|
2214
|
+
transfer_to: z11.string().optional(),
|
|
2215
|
+
contract: z11.string().optional(),
|
|
2216
|
+
symbol: z11.string().optional(),
|
|
2217
|
+
amount_min: z11.string().optional(),
|
|
2218
|
+
amount_max: z11.string().optional(),
|
|
2219
|
+
date_from: z11.string().optional(),
|
|
2220
|
+
date_to: z11.string().optional(),
|
|
2221
|
+
global_seq_from: z11.string().optional(),
|
|
2222
|
+
global_seq_to: z11.string().optional(),
|
|
2223
|
+
direction: sortDirectionEnum.optional(),
|
|
2224
|
+
limit: createLimit(100, 250)
|
|
2225
|
+
});
|
|
2211
2226
|
var orderType = /* @__PURE__ */ ((orderType2) => {
|
|
2212
2227
|
orderType2[orderType2["ORDERBOOK"] = 0] = "ORDERBOOK";
|
|
2213
2228
|
orderType2[orderType2["LIMIT"] = 1] = "LIMIT";
|
|
@@ -3956,6 +3971,7 @@ export {
|
|
|
3956
3971
|
getHistoryActionsParser,
|
|
3957
3972
|
getHistoryActionsResponseParser,
|
|
3958
3973
|
getHistoryTransactionResponseParser,
|
|
3974
|
+
getHistoryTransfersParser,
|
|
3959
3975
|
getLeaderboardParser,
|
|
3960
3976
|
getLeaderboardResponseParser,
|
|
3961
3977
|
getMarketsResponseParser,
|
|
@@ -4009,6 +4025,7 @@ export {
|
|
|
4009
4025
|
refferalTotalParser,
|
|
4010
4026
|
similarChains,
|
|
4011
4027
|
singleActionTransactionParser,
|
|
4028
|
+
sortDirectionEnum,
|
|
4012
4029
|
syncParser,
|
|
4013
4030
|
traceParser,
|
|
4014
4031
|
tradeLogParser,
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
8
|
-
"version": "0.2.
|
|
8
|
+
"version": "0.2.136",
|
|
9
9
|
"license": "MIT",
|
|
10
10
|
"main": "dist/index.js",
|
|
11
11
|
"typings": "dist/index.d.ts",
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"resolutions": {
|
|
41
41
|
"typescript": "4.5"
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "cba37d8ba47dc048733bc7218b66807587fea938"
|
|
44
44
|
}
|
package/src/parsers/dex.ts
CHANGED
|
@@ -33,6 +33,8 @@ const contractFiltersParser = z
|
|
|
33
33
|
return Array.isArray(oids) ? oids : [oids];
|
|
34
34
|
});
|
|
35
35
|
|
|
36
|
+
export const sortDirectionEnum = z.enum(["asc", "desc"])
|
|
37
|
+
|
|
36
38
|
/**
|
|
37
39
|
* OHLCV
|
|
38
40
|
*/
|
|
@@ -623,13 +625,13 @@ export type GetHistoryTransactionResponse = z.input<
|
|
|
623
625
|
* History Actions
|
|
624
626
|
*/
|
|
625
627
|
export const getHistoryActionsParser = z.object({
|
|
626
|
-
account: z.string(),
|
|
628
|
+
account: z.string().min(1, { message: 'account is required' }),
|
|
627
629
|
contract_filters: contractFiltersParser,
|
|
628
630
|
account_seq_from: z.string().optional(),
|
|
629
631
|
account_seq_to: z.string().optional(),
|
|
630
632
|
date_from: z.string().optional(),
|
|
631
633
|
date_to: z.string().optional(),
|
|
632
|
-
direction:
|
|
634
|
+
direction: sortDirectionEnum.optional(),
|
|
633
635
|
limit: createLimit(100, 250)
|
|
634
636
|
});
|
|
635
637
|
export type GetHistoryActions = z.input<typeof getHistoryActionsParser>;
|
|
@@ -653,6 +655,26 @@ export const getHistoryActionsResponseParser = z.object({
|
|
|
653
655
|
});
|
|
654
656
|
export type GetHistoryActionsResponse = z.infer<typeof getHistoryActionsResponseParser>;
|
|
655
657
|
|
|
658
|
+
/**
|
|
659
|
+
* History transfers
|
|
660
|
+
*/
|
|
661
|
+
export const getHistoryTransfersParser = z.object({
|
|
662
|
+
transfer_from: z.string().optional(),
|
|
663
|
+
transfer_to: z.string().optional(),
|
|
664
|
+
contract: z.string().optional(),
|
|
665
|
+
symbol: z.string().optional(),
|
|
666
|
+
amount_min: z.string().optional(),
|
|
667
|
+
amount_max: z.string().optional(),
|
|
668
|
+
date_from: z.string().optional(),
|
|
669
|
+
date_to: z.string().optional(),
|
|
670
|
+
global_seq_from: z.string().optional(),
|
|
671
|
+
global_seq_to: z.string().optional(),
|
|
672
|
+
direction: sortDirectionEnum.optional(),
|
|
673
|
+
limit: createLimit(100, 250)
|
|
674
|
+
});
|
|
675
|
+
export type GetHistoryTransfers = z.input<typeof getHistoryTransfersParser>;
|
|
676
|
+
export type GetHistoryTransfersParsed = z.output<typeof getHistoryTransfersParser>;
|
|
677
|
+
|
|
656
678
|
/**
|
|
657
679
|
* Basic Types
|
|
658
680
|
*/
|