@liberfi.io/client 0.3.12 → 0.3.14

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/README.md CHANGED
@@ -6,7 +6,7 @@ DEX API client for the Liberfi React SDK. This package wraps `@chainstream-io/sd
6
6
 
7
7
  - **Adapter pattern** — `Client` wraps `ChainStreamClient` and translates between upstream DTOs and Liberfi domain types, keeping consumers decoupled from the backend SDK.
8
8
  - **Centralized DTO conversion** — All mapping functions live in `utils.ts`, separating data transformation from client orchestration.
9
- - **Interface conformance** — `Client implements API.IClient, API.ISubscribeClient` ensures compile-time contract enforcement.
9
+ - **Interface conformance** — `Client implements IClient, ISubscribeClient` ensures compile-time contract enforcement.
10
10
  - **Composite subscriptions** — WebSocket methods compose multiple backend channels into a single `ISubscription` with a unified `unsubscribe()`.
11
11
  - **Phase 3 bypass layer** — For endpoints the upstream `@chainstream-io/sdk` has not yet upgraded (`getTokenHolders`, `getTokenActivities`, `getWalletActivities`, `getWalletPortfoliosByTokens`, `getWalletPortfolioPnls`), `Client` uses an internal `phase3Http` fetch helper that calls the server directly and maps the raw DTOs back to domain types. Consumers keep the same `IClient` interface.
12
12
 
@@ -28,7 +28,7 @@ This package depends on:
28
28
 
29
29
  #### `Client`
30
30
 
31
- Main API client implementing both `API.IClient` (REST) and `API.ISubscribeClient` (WebSocket).
31
+ Main API client implementing both `IClient` (REST) and `ISubscribeClient` (WebSocket).
32
32
 
33
33
  ```typescript
34
34
  import { Client } from "@liberfi.io/client";
@@ -105,12 +105,6 @@ const client = new Client("your-access-token", {
105
105
  | `ClientTokenProviderFn` | `{ getToken(): Promise<string> \| string }` | Async/sync token provider interface. |
106
106
  | `ClientOptions` | `{ debug?, serverUrl?, streamUrl?, autoConnectWebSocket? }` | Client configuration. |
107
107
 
108
- ### Constants
109
-
110
- | Name | Type | Description |
111
- | --------- | -------- | ------------------------------------- |
112
- | `version` | `string` | Current package version (`"0.1.37"`). |
113
-
114
108
  ### Utility Functions
115
109
 
116
110
  The following DTO conversion functions are also exported. They are primarily intended for internal use by `Client` but are available for advanced scenarios (e.g. custom data pipelines).
@@ -200,7 +194,7 @@ const route = await client.swapRoute({
200
194
  userAddress: "0xe778D43627387448Ccf2285B6FA1CA60Eb629750",
201
195
  input: "0x0000000000000000000000000000000000000000", // ETH native
202
196
  output: "0xfF541139c60bB38CE2159A13d656f0f38aA96ff4",
203
- mode: API.SwapMode.EXACT_IN,
197
+ mode: SwapMode.EXACT_IN,
204
198
  amount: "100000000000000",
205
199
  slippage: 20,
206
200
  });
@@ -217,4 +211,3 @@ const route = await client.swapRoute({
217
211
  - Add explicit `ClientOptions` to `ChainStreamClient` option mapping in the constructor.
218
212
  - Deduplicate `fromTradeDetailDTO` / `fromActivityDetailDTO` logic.
219
213
  - Add runtime validation in `fromTokenSecurity` instead of `as` casts.
220
- - Consolidate `version.ts` global side effect into a shared utility.
package/dist/index.d.mts CHANGED
@@ -1,15 +1,6 @@
1
1
  import * as _liberfi_io_types from '@liberfi.io/types';
2
- import { API, Chain, Token, TokenResolution, TokenCandle, TokenSecurity, TokenStats, TokenHolder, TokenMarketData, WalletPortfolios, WalletPnl, WalletPortfolioPnls, Portfolio, PortfolioPnl, Trade, Activity, TokenCreator as TokenCreator$1, TokenLiquidity } from '@liberfi.io/types';
3
- import { ChainSymbol, Resolution, RangeFilterCondition, TokenCreator, Token as Token$1, TokenStats as TokenStats$1, DexPool, TokenMarketData as TokenMarketData$1, TokenCandle as TokenCandle$1, SwapRouteInput, SendTxInput, TokenPage, SwapRouteResponse, BlockchainLatestBlock, SendTxResponse, WalletNetWorthPage, WalletPnlSummary, PnlDetailsResult, PageResponseTradeDetail, WsNewToken, WsTokenMetadata, WsCandle, WsTokenStat, WsTokenSupply, WsTokenHolder, WsTokenLiquidity, WsTokenBondingCurve, WsTokenMaxLiquidity, WsTokenTotalLiquidity, WsTradeActivity } from '@chainstream-io/sdk';
4
-
5
- declare global {
6
- interface Window {
7
- __LIBERFI_VERSION__?: {
8
- [key: string]: string;
9
- };
10
- }
11
- }
12
- declare const _default: "0.3.12";
2
+ import { IClient, ISubscribeClient, Chain, Token, TokenResolution, GetTokenCandlesOptions, TokenCandle, TokenSecurity, TokenStats, GetTokenHoldersOptions, CursorList, TokenHolder, TokenMarketData, GetTokenListOptions, SearchTokensOptions, SearchTokenCursorList, SwapParams, SwapRoute, LatestBlockParams, BlockchainLatestBlock, SendTxParams, SendTxResult, WalletPortfolios, WalletPnlResolution, WalletPnl, GetWalletPortfolioPnlsOptions, WalletPortfolioPnls, Portfolio, PortfolioPnl, GetTradesOptions, Trade, GetActivitiesOptions, Activity, GetWalletLimitOrdersOptions, GetTokensByCreatorOptions, TokenSubscribed, ISubscription, WalletPnlSubscribed, PortfolioSubscribed, PortfolioPnlSubscribed, TokenFieldOption, TokenFilterOption, TokenCreator as TokenCreator$1, TokenLiquidity } from '@liberfi.io/types';
3
+ import { ChainSymbol, Resolution, RangeFilterCondition, TokenCreator, Token as Token$1, TokenStats as TokenStats$1, DexPool, TokenMarketData as TokenMarketData$1, TokenCandle as TokenCandle$1, SwapRouteInput, SendTxInput, TokenPage, SwapRouteResponse, BlockchainLatestBlock as BlockchainLatestBlock$1, SendTxResponse, WalletNetWorthPage, WalletPnlSummary, PnlDetailsResult, PageResponseTradeDetail, WsNewToken, WsTokenMetadata, WsCandle, WsTokenStat, WsTokenSupply, WsTokenHolder, WsTokenLiquidity, WsTokenBondingCurve, WsTokenMaxLiquidity, WsTokenTotalLiquidity, WsTradeActivity } from '@chainstream-io/sdk';
13
4
 
14
5
  /** Async or sync token provider for authentication. */
15
6
  interface ClientTokenProviderFn {
@@ -30,7 +21,7 @@ interface ClientOptions {
30
21
  */
31
22
  nativeBalanceApiUrl?: string;
32
23
  }
33
- declare class Client implements API.IClient, API.ISubscribeClient {
24
+ declare class Client implements IClient, ISubscribeClient {
34
25
  private readonly accessToken;
35
26
  private readonly options?;
36
27
  private readonly _client;
@@ -38,50 +29,50 @@ declare class Client implements API.IClient, API.ISubscribeClient {
38
29
  constructor(accessToken: ClientTokenProvider, options?: ClientOptions | undefined);
39
30
  getToken(chain: Chain, address: string): Promise<Token>;
40
31
  getTokens(chain: Chain, addresses: Array<string>): Promise<Array<Token>>;
41
- getTokenCandles(chain: Chain, address: string, resolution: TokenResolution, options?: API.GetTokenCandlesOptions): Promise<Array<TokenCandle>>;
32
+ getTokenCandles(chain: Chain, address: string, resolution: TokenResolution, options?: GetTokenCandlesOptions): Promise<Array<TokenCandle>>;
42
33
  getTokenSecurity(chain: Chain, address: string): Promise<TokenSecurity>;
43
34
  getTokenStats(chain: Chain, address: string): Promise<TokenStats>;
44
- getTokenHolders(chain: Chain, address: string, options?: API.GetTokenHoldersOptions): Promise<API.CursorList<TokenHolder>>;
35
+ getTokenHolders(chain: Chain, address: string, options?: GetTokenHoldersOptions): Promise<CursorList<TokenHolder>>;
45
36
  getTokenMarketData(chain: Chain, address: string): Promise<TokenMarketData>;
46
- getNewTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
47
- getFinalStretchTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
48
- getMigratedTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
49
- getTrendingTokens(chain: Chain, resolution: "1m" | "5m" | "1h" | "4h" | "24h", options?: API.GetTokenListOptions): Promise<Array<Token>>;
50
- getStockTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
51
- searchTokens(options?: API.SearchTokensOptions): Promise<API.SearchTokenCursorList>;
52
- swapRoute(params: API.SwapParams): Promise<API.SwapRoute>;
53
- getLatestBlock(params: API.LatestBlockParams): Promise<API.BlockchainLatestBlock>;
54
- sendTx(params: API.SendTxParams): Promise<API.SendTxResult>;
37
+ getNewTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
38
+ getFinalStretchTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
39
+ getMigratedTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
40
+ getTrendingTokens(chain: Chain, resolution: "1m" | "5m" | "1h" | "4h" | "24h", options?: GetTokenListOptions): Promise<Array<Token>>;
41
+ getStockTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
42
+ searchTokens(options?: SearchTokensOptions): Promise<SearchTokenCursorList>;
43
+ swapRoute(params: SwapParams): Promise<SwapRoute>;
44
+ getLatestBlock(params: LatestBlockParams): Promise<BlockchainLatestBlock>;
45
+ sendTx(params: SendTxParams): Promise<SendTxResult>;
55
46
  checkTxSuccess(chain: Chain, txHash: string, timeout?: number): Promise<boolean>;
56
47
  getWalletPortfolios(chain: Chain, address: string, options?: {
57
48
  cursor?: string;
58
49
  limit?: number;
59
50
  }): Promise<WalletPortfolios>;
60
- getWalletPnl(chain: Chain, address: string, resolution?: string): Promise<WalletPnl>;
61
- getWalletPortfolioPnls(chain: Chain, address: string, options?: API.GetWalletPortfolioPnlsOptions): Promise<WalletPortfolioPnls>;
51
+ getWalletPnl(chain: Chain, address: string, resolution?: WalletPnlResolution): Promise<WalletPnl>;
52
+ getWalletPortfolioPnls(chain: Chain, address: string, options?: GetWalletPortfolioPnlsOptions): Promise<WalletPortfolioPnls>;
62
53
  getWalletPortfoliosByTokens(chain: Chain, address: string, tokenAddresses: Array<string>): Promise<Array<Portfolio>>;
63
54
  getWalletPortfolioPnlsByTokens(chain: Chain, address: string, tokenAddresses: Array<string>): Promise<Array<PortfolioPnl>>;
64
- getWalletTrades(chain: Chain, address: string, options?: API.GetTradesOptions): Promise<API.CursorList<Trade>>;
65
- getTokenTrades(chain: Chain, address: string, options?: API.GetTradesOptions): Promise<API.CursorList<Trade>>;
66
- getWalletActivities(chain: Chain, address: string, options?: API.GetActivitiesOptions): Promise<API.CursorList<Activity>>;
67
- getTokenActivities(chain: Chain, address: string, options?: API.GetActivitiesOptions): Promise<API.CursorList<Activity>>;
55
+ getWalletTrades(chain: Chain, address: string, options?: GetTradesOptions): Promise<CursorList<Trade>>;
56
+ getTokenTrades(chain: Chain, address: string, options?: GetTradesOptions): Promise<CursorList<Trade>>;
57
+ getWalletActivities(chain: Chain, address: string, options?: GetActivitiesOptions): Promise<CursorList<Activity>>;
58
+ getTokenActivities(chain: Chain, address: string, options?: GetActivitiesOptions): Promise<CursorList<Activity>>;
68
59
  getPresignedUploadUrl(): Promise<string>;
69
- getWalletLimitOrders(_chain: Chain, _address: string, _options?: API.GetWalletLimitOrdersOptions): Promise<API.CursorList<_liberfi_io_types.LimitOrder>>;
70
- getTokensByCreator(_chain: Chain, _creator: string, _options?: API.GetTokensByCreatorOptions): Promise<API.CursorList<Token>>;
71
- subscribeToken(chain: Chain, address: string, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
72
- subscribeTokenCandles(chain: Chain, address: string, resolution: TokenResolution, callback: (candles: Array<TokenCandle>) => void): API.ISubscription;
73
- subscribeWalletPnl(chain: Chain, address: string, callback: (pnls: Array<API.WalletPnlSubscribed>) => void): API.ISubscription;
74
- subscribeWalletPortfolios(chain: Chain, address: string, callback: (portfolios: Array<API.PortfolioSubscribed>) => void): API.ISubscription;
75
- subscribeWalletPortfolioPnls(chain: Chain, address: string, callback: (portfolioPnls: Array<API.PortfolioPnlSubscribed>) => void): API.ISubscription;
76
- subscribeWalletTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): API.ISubscription;
77
- subscribeTokenTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): API.ISubscription;
78
- subscribeWalletActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): API.ISubscription;
79
- subscribeTokenActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): API.ISubscription;
80
- subscribeNewTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
81
- subscribeTrendingTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
82
- subscribeMigratedTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
83
- subscribeFinalStretchTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
84
- subscribeStockTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
60
+ getWalletLimitOrders(_chain: Chain, _address: string, _options?: GetWalletLimitOrdersOptions): Promise<CursorList<_liberfi_io_types.LimitOrder>>;
61
+ getTokensByCreator(_chain: Chain, _creator: string, _options?: GetTokensByCreatorOptions): Promise<CursorList<Token>>;
62
+ subscribeToken(chain: Chain, address: string, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
63
+ subscribeTokenCandles(chain: Chain, address: string, resolution: TokenResolution, callback: (candles: Array<TokenCandle>) => void): ISubscription;
64
+ subscribeWalletPnl(chain: Chain, address: string, callback: (pnls: Array<WalletPnlSubscribed>) => void): ISubscription;
65
+ subscribeWalletPortfolios(chain: Chain, address: string, callback: (portfolios: Array<PortfolioSubscribed>) => void): ISubscription;
66
+ subscribeWalletPortfolioPnls(chain: Chain, address: string, callback: (portfolioPnls: Array<PortfolioPnlSubscribed>) => void): ISubscription;
67
+ subscribeWalletTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): ISubscription;
68
+ subscribeTokenTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): ISubscription;
69
+ subscribeWalletActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): ISubscription;
70
+ subscribeTokenActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): ISubscription;
71
+ subscribeNewTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
72
+ subscribeTrendingTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
73
+ subscribeMigratedTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
74
+ subscribeFinalStretchTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
75
+ subscribeStockTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
85
76
  private static readonly _CHAIN_TO_BALANCE_PARAM;
86
77
  private static readonly _NATIVE_TOKEN_ADDRESS;
87
78
  /**
@@ -263,9 +254,9 @@ interface Phase3PnlDetailsDTO extends CursorPageDTO<Phase3PnlItemDTO> {
263
254
  declare function toChainDTO(chain: Chain): ChainSymbol;
264
255
  declare function toResolutionDTO(resolution: TokenResolution): Resolution;
265
256
  declare function toSortDirectionDTO(direction: "asc" | "desc"): string;
266
- declare function toSearchFieldDTO(field: API.TokenFieldOption): string;
267
- declare function toFieldDTO(field: API.TokenFieldOption): string;
268
- declare function toRangeFiltersDTO(filters: Array<API.TokenFilterOption>): Array<RangeFilterCondition>;
257
+ declare function toSearchFieldDTO(field: TokenFieldOption): string;
258
+ declare function toFieldDTO(field: TokenFieldOption): string;
259
+ declare function toRangeFiltersDTO(filters: Array<TokenFilterOption>): Array<RangeFilterCondition>;
269
260
  declare function fromChainDTO(chain: string): Chain;
270
261
  declare function fromTokenCreatorDTO(input: TokenCreator): TokenCreator$1;
271
262
  declare function fromTokenDTO(input: Token$1): Token;
@@ -286,34 +277,34 @@ declare const KYBERSWAP_NATIVE_SENTINEL = "0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeee
286
277
  * For KyberSwap, EVM native (0x0) is converted to KYBERSWAP_NATIVE_SENTINEL.
287
278
  */
288
279
  declare function toMintForRoute(dex: "jupiter" | "kyberswap", address: string): string;
289
- declare function toSwapRouteInput(params: API.SwapParams): SwapRouteInput;
290
- declare function toSendTxInput(params: API.SendTxParams): SendTxInput;
291
- declare function fromTokenHolderPage(input: CursorPageDTO<Phase3TokenHolderDTO>): API.CursorList<TokenHolder>;
292
- declare function fromTokenPage(input: TokenPage): API.SearchTokenCursorList;
293
- declare function fromSwapRoute(input: SwapRouteResponse): API.SwapRoute;
294
- declare function fromLatestBlock(input: BlockchainLatestBlock): API.BlockchainLatestBlock;
295
- declare function fromSendTxResult(input: SendTxResponse): API.SendTxResult;
280
+ declare function toSwapRouteInput(params: SwapParams): SwapRouteInput;
281
+ declare function toSendTxInput(params: SendTxParams): SendTxInput;
282
+ declare function fromTokenHolderPage(input: CursorPageDTO<Phase3TokenHolderDTO>): CursorList<TokenHolder>;
283
+ declare function fromTokenPage(input: TokenPage): SearchTokenCursorList;
284
+ declare function fromSwapRoute(input: SwapRouteResponse): SwapRoute;
285
+ declare function fromLatestBlock(input: BlockchainLatestBlock$1): BlockchainLatestBlock;
286
+ declare function fromSendTxResult(input: SendTxResponse): SendTxResult;
296
287
  declare function fromWalletPortfolios(chain: Chain, input: WalletNetWorthPage): WalletPortfolios;
297
288
  declare function fromWalletPnlSummary(chain: Chain, address: string, input: WalletPnlSummary): WalletPnl;
298
289
  declare function fromPnlDetailsPage(chain: Chain, address: string, input: Phase3PnlDetailsDTO): WalletPortfolioPnls;
299
290
  declare function fromWalletNetWorthByTokens(chain: Chain, input: Phase3NetWorthByTokensDTO): Portfolio[];
300
291
  declare function fromPnlDetailItems(chain: Chain, input: PnlDetailsResult): PortfolioPnl[];
301
- declare function fromTradePage(input: PageResponseTradeDetail): API.CursorList<Trade>;
302
- declare function fromActivityPage(input: CursorPageDTO<Phase3ActivityDTO>): API.CursorList<Activity>;
303
- declare function fromTokenSubscribed(chain: Chain, input: WsNewToken): API.TokenSubscribed;
304
- declare function fromTokenMetadataSubscribed(chain: Chain, input: WsTokenMetadata): API.TokenSubscribed;
292
+ declare function fromTradePage(input: PageResponseTradeDetail): CursorList<Trade>;
293
+ declare function fromActivityPage(input: CursorPageDTO<Phase3ActivityDTO>): CursorList<Activity>;
294
+ declare function fromTokenSubscribed(chain: Chain, input: WsNewToken): TokenSubscribed;
295
+ declare function fromTokenMetadataSubscribed(chain: Chain, input: WsTokenMetadata): TokenSubscribed;
305
296
  declare function fromWsCandle(input: WsCandle): TokenCandle;
306
297
  declare function fromWsTokenStats(input: WsTokenStat): TokenStats;
307
298
  declare function fromWsTokenMarketDataFromStats(input: WsTokenStat): TokenMarketData;
308
- declare function fromWsTokenDataSubscribed(chain: Chain, input: WsTokenStat): API.TokenSubscribed;
309
- declare function fromWsTokenSupplyToSubscribed(chain: Chain, address: string, input: WsTokenSupply): API.TokenSubscribed;
310
- declare function fromWsTokenHolderToSubscribed(chain: Chain, address: string, input: WsTokenHolder): API.TokenSubscribed;
311
- declare function fromWsTokenLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenLiquidity): API.TokenSubscribed;
312
- declare function fromWsTokenBondingCurveToSubscribed(chain: Chain, input: WsTokenBondingCurve): API.TokenSubscribed;
313
- declare function fromWsTokenMaxLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenMaxLiquidity): API.TokenSubscribed;
314
- declare function fromWsTokenTotalLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenTotalLiquidity): API.TokenSubscribed;
299
+ declare function fromWsTokenDataSubscribed(chain: Chain, input: WsTokenStat): TokenSubscribed;
300
+ declare function fromWsTokenSupplyToSubscribed(chain: Chain, address: string, input: WsTokenSupply): TokenSubscribed;
301
+ declare function fromWsTokenHolderToSubscribed(chain: Chain, address: string, input: WsTokenHolder): TokenSubscribed;
302
+ declare function fromWsTokenLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenLiquidity): TokenSubscribed;
303
+ declare function fromWsTokenBondingCurveToSubscribed(chain: Chain, input: WsTokenBondingCurve): TokenSubscribed;
304
+ declare function fromWsTokenMaxLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenMaxLiquidity): TokenSubscribed;
305
+ declare function fromWsTokenTotalLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenTotalLiquidity): TokenSubscribed;
315
306
  declare function fromWsTokenMarketDataFromHolder(input: WsTokenHolder): Partial<TokenMarketData>;
316
307
  declare function fromWsTradeActivity(chain: Chain, input: WsTradeActivity): Trade;
317
308
  declare function fromWsActivity(chain: Chain, input: WsTradeActivity): Activity;
318
309
 
319
- export { Client, type ClientOptions, type ClientTokenProvider, type ClientTokenProviderFn, KYBERSWAP_NATIVE_SENTINEL, NotImplementedError, fromActivityPage, fromChainDTO, fromLatestBlock, fromPnlDetailItems, fromPnlDetailsPage, fromSendTxResult, fromSwapRoute, fromTokenCandle, fromTokenCreatorDTO, fromTokenDTO, fromTokenHolderPage, fromTokenLiquidityDTO, fromTokenMarketDataDTO, fromTokenMetadataSubscribed, fromTokenPage, fromTokenSecurity, fromTokenStatsDTO, fromTokenSubscribed, fromTradePage, fromWalletNetWorthByTokens, fromWalletPnlSummary, fromWalletPortfolios, fromWsActivity, fromWsCandle, fromWsTokenBondingCurveToSubscribed, fromWsTokenDataSubscribed, fromWsTokenHolderToSubscribed, fromWsTokenLiquidityToSubscribed, fromWsTokenMarketDataFromHolder, fromWsTokenMarketDataFromStats, fromWsTokenMaxLiquidityToSubscribed, fromWsTokenStats, fromWsTokenSupplyToSubscribed, fromWsTokenTotalLiquidityToSubscribed, fromWsTradeActivity, isNotImplementedError, toChainDTO, toFieldDTO, toMintForRoute, toRangeFiltersDTO, toResolutionDTO, toSearchFieldDTO, toSendTxInput, toSortDirectionDTO, toSwapRouteInput, _default as version };
310
+ export { Client, type ClientOptions, type ClientTokenProvider, type ClientTokenProviderFn, KYBERSWAP_NATIVE_SENTINEL, NotImplementedError, fromActivityPage, fromChainDTO, fromLatestBlock, fromPnlDetailItems, fromPnlDetailsPage, fromSendTxResult, fromSwapRoute, fromTokenCandle, fromTokenCreatorDTO, fromTokenDTO, fromTokenHolderPage, fromTokenLiquidityDTO, fromTokenMarketDataDTO, fromTokenMetadataSubscribed, fromTokenPage, fromTokenSecurity, fromTokenStatsDTO, fromTokenSubscribed, fromTradePage, fromWalletNetWorthByTokens, fromWalletPnlSummary, fromWalletPortfolios, fromWsActivity, fromWsCandle, fromWsTokenBondingCurveToSubscribed, fromWsTokenDataSubscribed, fromWsTokenHolderToSubscribed, fromWsTokenLiquidityToSubscribed, fromWsTokenMarketDataFromHolder, fromWsTokenMarketDataFromStats, fromWsTokenMaxLiquidityToSubscribed, fromWsTokenStats, fromWsTokenSupplyToSubscribed, fromWsTokenTotalLiquidityToSubscribed, fromWsTradeActivity, isNotImplementedError, toChainDTO, toFieldDTO, toMintForRoute, toRangeFiltersDTO, toResolutionDTO, toSearchFieldDTO, toSendTxInput, toSortDirectionDTO, toSwapRouteInput };
package/dist/index.d.ts CHANGED
@@ -1,15 +1,6 @@
1
1
  import * as _liberfi_io_types from '@liberfi.io/types';
2
- import { API, Chain, Token, TokenResolution, TokenCandle, TokenSecurity, TokenStats, TokenHolder, TokenMarketData, WalletPortfolios, WalletPnl, WalletPortfolioPnls, Portfolio, PortfolioPnl, Trade, Activity, TokenCreator as TokenCreator$1, TokenLiquidity } from '@liberfi.io/types';
3
- import { ChainSymbol, Resolution, RangeFilterCondition, TokenCreator, Token as Token$1, TokenStats as TokenStats$1, DexPool, TokenMarketData as TokenMarketData$1, TokenCandle as TokenCandle$1, SwapRouteInput, SendTxInput, TokenPage, SwapRouteResponse, BlockchainLatestBlock, SendTxResponse, WalletNetWorthPage, WalletPnlSummary, PnlDetailsResult, PageResponseTradeDetail, WsNewToken, WsTokenMetadata, WsCandle, WsTokenStat, WsTokenSupply, WsTokenHolder, WsTokenLiquidity, WsTokenBondingCurve, WsTokenMaxLiquidity, WsTokenTotalLiquidity, WsTradeActivity } from '@chainstream-io/sdk';
4
-
5
- declare global {
6
- interface Window {
7
- __LIBERFI_VERSION__?: {
8
- [key: string]: string;
9
- };
10
- }
11
- }
12
- declare const _default: "0.3.12";
2
+ import { IClient, ISubscribeClient, Chain, Token, TokenResolution, GetTokenCandlesOptions, TokenCandle, TokenSecurity, TokenStats, GetTokenHoldersOptions, CursorList, TokenHolder, TokenMarketData, GetTokenListOptions, SearchTokensOptions, SearchTokenCursorList, SwapParams, SwapRoute, LatestBlockParams, BlockchainLatestBlock, SendTxParams, SendTxResult, WalletPortfolios, WalletPnlResolution, WalletPnl, GetWalletPortfolioPnlsOptions, WalletPortfolioPnls, Portfolio, PortfolioPnl, GetTradesOptions, Trade, GetActivitiesOptions, Activity, GetWalletLimitOrdersOptions, GetTokensByCreatorOptions, TokenSubscribed, ISubscription, WalletPnlSubscribed, PortfolioSubscribed, PortfolioPnlSubscribed, TokenFieldOption, TokenFilterOption, TokenCreator as TokenCreator$1, TokenLiquidity } from '@liberfi.io/types';
3
+ import { ChainSymbol, Resolution, RangeFilterCondition, TokenCreator, Token as Token$1, TokenStats as TokenStats$1, DexPool, TokenMarketData as TokenMarketData$1, TokenCandle as TokenCandle$1, SwapRouteInput, SendTxInput, TokenPage, SwapRouteResponse, BlockchainLatestBlock as BlockchainLatestBlock$1, SendTxResponse, WalletNetWorthPage, WalletPnlSummary, PnlDetailsResult, PageResponseTradeDetail, WsNewToken, WsTokenMetadata, WsCandle, WsTokenStat, WsTokenSupply, WsTokenHolder, WsTokenLiquidity, WsTokenBondingCurve, WsTokenMaxLiquidity, WsTokenTotalLiquidity, WsTradeActivity } from '@chainstream-io/sdk';
13
4
 
14
5
  /** Async or sync token provider for authentication. */
15
6
  interface ClientTokenProviderFn {
@@ -30,7 +21,7 @@ interface ClientOptions {
30
21
  */
31
22
  nativeBalanceApiUrl?: string;
32
23
  }
33
- declare class Client implements API.IClient, API.ISubscribeClient {
24
+ declare class Client implements IClient, ISubscribeClient {
34
25
  private readonly accessToken;
35
26
  private readonly options?;
36
27
  private readonly _client;
@@ -38,50 +29,50 @@ declare class Client implements API.IClient, API.ISubscribeClient {
38
29
  constructor(accessToken: ClientTokenProvider, options?: ClientOptions | undefined);
39
30
  getToken(chain: Chain, address: string): Promise<Token>;
40
31
  getTokens(chain: Chain, addresses: Array<string>): Promise<Array<Token>>;
41
- getTokenCandles(chain: Chain, address: string, resolution: TokenResolution, options?: API.GetTokenCandlesOptions): Promise<Array<TokenCandle>>;
32
+ getTokenCandles(chain: Chain, address: string, resolution: TokenResolution, options?: GetTokenCandlesOptions): Promise<Array<TokenCandle>>;
42
33
  getTokenSecurity(chain: Chain, address: string): Promise<TokenSecurity>;
43
34
  getTokenStats(chain: Chain, address: string): Promise<TokenStats>;
44
- getTokenHolders(chain: Chain, address: string, options?: API.GetTokenHoldersOptions): Promise<API.CursorList<TokenHolder>>;
35
+ getTokenHolders(chain: Chain, address: string, options?: GetTokenHoldersOptions): Promise<CursorList<TokenHolder>>;
45
36
  getTokenMarketData(chain: Chain, address: string): Promise<TokenMarketData>;
46
- getNewTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
47
- getFinalStretchTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
48
- getMigratedTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
49
- getTrendingTokens(chain: Chain, resolution: "1m" | "5m" | "1h" | "4h" | "24h", options?: API.GetTokenListOptions): Promise<Array<Token>>;
50
- getStockTokens(chain: Chain, options?: API.GetTokenListOptions): Promise<Array<Token>>;
51
- searchTokens(options?: API.SearchTokensOptions): Promise<API.SearchTokenCursorList>;
52
- swapRoute(params: API.SwapParams): Promise<API.SwapRoute>;
53
- getLatestBlock(params: API.LatestBlockParams): Promise<API.BlockchainLatestBlock>;
54
- sendTx(params: API.SendTxParams): Promise<API.SendTxResult>;
37
+ getNewTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
38
+ getFinalStretchTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
39
+ getMigratedTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
40
+ getTrendingTokens(chain: Chain, resolution: "1m" | "5m" | "1h" | "4h" | "24h", options?: GetTokenListOptions): Promise<Array<Token>>;
41
+ getStockTokens(chain: Chain, options?: GetTokenListOptions): Promise<Array<Token>>;
42
+ searchTokens(options?: SearchTokensOptions): Promise<SearchTokenCursorList>;
43
+ swapRoute(params: SwapParams): Promise<SwapRoute>;
44
+ getLatestBlock(params: LatestBlockParams): Promise<BlockchainLatestBlock>;
45
+ sendTx(params: SendTxParams): Promise<SendTxResult>;
55
46
  checkTxSuccess(chain: Chain, txHash: string, timeout?: number): Promise<boolean>;
56
47
  getWalletPortfolios(chain: Chain, address: string, options?: {
57
48
  cursor?: string;
58
49
  limit?: number;
59
50
  }): Promise<WalletPortfolios>;
60
- getWalletPnl(chain: Chain, address: string, resolution?: string): Promise<WalletPnl>;
61
- getWalletPortfolioPnls(chain: Chain, address: string, options?: API.GetWalletPortfolioPnlsOptions): Promise<WalletPortfolioPnls>;
51
+ getWalletPnl(chain: Chain, address: string, resolution?: WalletPnlResolution): Promise<WalletPnl>;
52
+ getWalletPortfolioPnls(chain: Chain, address: string, options?: GetWalletPortfolioPnlsOptions): Promise<WalletPortfolioPnls>;
62
53
  getWalletPortfoliosByTokens(chain: Chain, address: string, tokenAddresses: Array<string>): Promise<Array<Portfolio>>;
63
54
  getWalletPortfolioPnlsByTokens(chain: Chain, address: string, tokenAddresses: Array<string>): Promise<Array<PortfolioPnl>>;
64
- getWalletTrades(chain: Chain, address: string, options?: API.GetTradesOptions): Promise<API.CursorList<Trade>>;
65
- getTokenTrades(chain: Chain, address: string, options?: API.GetTradesOptions): Promise<API.CursorList<Trade>>;
66
- getWalletActivities(chain: Chain, address: string, options?: API.GetActivitiesOptions): Promise<API.CursorList<Activity>>;
67
- getTokenActivities(chain: Chain, address: string, options?: API.GetActivitiesOptions): Promise<API.CursorList<Activity>>;
55
+ getWalletTrades(chain: Chain, address: string, options?: GetTradesOptions): Promise<CursorList<Trade>>;
56
+ getTokenTrades(chain: Chain, address: string, options?: GetTradesOptions): Promise<CursorList<Trade>>;
57
+ getWalletActivities(chain: Chain, address: string, options?: GetActivitiesOptions): Promise<CursorList<Activity>>;
58
+ getTokenActivities(chain: Chain, address: string, options?: GetActivitiesOptions): Promise<CursorList<Activity>>;
68
59
  getPresignedUploadUrl(): Promise<string>;
69
- getWalletLimitOrders(_chain: Chain, _address: string, _options?: API.GetWalletLimitOrdersOptions): Promise<API.CursorList<_liberfi_io_types.LimitOrder>>;
70
- getTokensByCreator(_chain: Chain, _creator: string, _options?: API.GetTokensByCreatorOptions): Promise<API.CursorList<Token>>;
71
- subscribeToken(chain: Chain, address: string, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
72
- subscribeTokenCandles(chain: Chain, address: string, resolution: TokenResolution, callback: (candles: Array<TokenCandle>) => void): API.ISubscription;
73
- subscribeWalletPnl(chain: Chain, address: string, callback: (pnls: Array<API.WalletPnlSubscribed>) => void): API.ISubscription;
74
- subscribeWalletPortfolios(chain: Chain, address: string, callback: (portfolios: Array<API.PortfolioSubscribed>) => void): API.ISubscription;
75
- subscribeWalletPortfolioPnls(chain: Chain, address: string, callback: (portfolioPnls: Array<API.PortfolioPnlSubscribed>) => void): API.ISubscription;
76
- subscribeWalletTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): API.ISubscription;
77
- subscribeTokenTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): API.ISubscription;
78
- subscribeWalletActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): API.ISubscription;
79
- subscribeTokenActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): API.ISubscription;
80
- subscribeNewTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
81
- subscribeTrendingTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
82
- subscribeMigratedTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
83
- subscribeFinalStretchTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
84
- subscribeStockTokens(chain: Chain, callback: (data: Array<API.TokenSubscribed>) => void): API.ISubscription;
60
+ getWalletLimitOrders(_chain: Chain, _address: string, _options?: GetWalletLimitOrdersOptions): Promise<CursorList<_liberfi_io_types.LimitOrder>>;
61
+ getTokensByCreator(_chain: Chain, _creator: string, _options?: GetTokensByCreatorOptions): Promise<CursorList<Token>>;
62
+ subscribeToken(chain: Chain, address: string, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
63
+ subscribeTokenCandles(chain: Chain, address: string, resolution: TokenResolution, callback: (candles: Array<TokenCandle>) => void): ISubscription;
64
+ subscribeWalletPnl(chain: Chain, address: string, callback: (pnls: Array<WalletPnlSubscribed>) => void): ISubscription;
65
+ subscribeWalletPortfolios(chain: Chain, address: string, callback: (portfolios: Array<PortfolioSubscribed>) => void): ISubscription;
66
+ subscribeWalletPortfolioPnls(chain: Chain, address: string, callback: (portfolioPnls: Array<PortfolioPnlSubscribed>) => void): ISubscription;
67
+ subscribeWalletTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): ISubscription;
68
+ subscribeTokenTrades(chain: Chain, address: string, callback: (trades: Array<Trade>) => void): ISubscription;
69
+ subscribeWalletActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): ISubscription;
70
+ subscribeTokenActivities(chain: Chain, address: string, callback: (activities: Array<Activity>) => void): ISubscription;
71
+ subscribeNewTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
72
+ subscribeTrendingTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
73
+ subscribeMigratedTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
74
+ subscribeFinalStretchTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
75
+ subscribeStockTokens(chain: Chain, callback: (data: Array<TokenSubscribed>) => void): ISubscription;
85
76
  private static readonly _CHAIN_TO_BALANCE_PARAM;
86
77
  private static readonly _NATIVE_TOKEN_ADDRESS;
87
78
  /**
@@ -263,9 +254,9 @@ interface Phase3PnlDetailsDTO extends CursorPageDTO<Phase3PnlItemDTO> {
263
254
  declare function toChainDTO(chain: Chain): ChainSymbol;
264
255
  declare function toResolutionDTO(resolution: TokenResolution): Resolution;
265
256
  declare function toSortDirectionDTO(direction: "asc" | "desc"): string;
266
- declare function toSearchFieldDTO(field: API.TokenFieldOption): string;
267
- declare function toFieldDTO(field: API.TokenFieldOption): string;
268
- declare function toRangeFiltersDTO(filters: Array<API.TokenFilterOption>): Array<RangeFilterCondition>;
257
+ declare function toSearchFieldDTO(field: TokenFieldOption): string;
258
+ declare function toFieldDTO(field: TokenFieldOption): string;
259
+ declare function toRangeFiltersDTO(filters: Array<TokenFilterOption>): Array<RangeFilterCondition>;
269
260
  declare function fromChainDTO(chain: string): Chain;
270
261
  declare function fromTokenCreatorDTO(input: TokenCreator): TokenCreator$1;
271
262
  declare function fromTokenDTO(input: Token$1): Token;
@@ -286,34 +277,34 @@ declare const KYBERSWAP_NATIVE_SENTINEL = "0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeee
286
277
  * For KyberSwap, EVM native (0x0) is converted to KYBERSWAP_NATIVE_SENTINEL.
287
278
  */
288
279
  declare function toMintForRoute(dex: "jupiter" | "kyberswap", address: string): string;
289
- declare function toSwapRouteInput(params: API.SwapParams): SwapRouteInput;
290
- declare function toSendTxInput(params: API.SendTxParams): SendTxInput;
291
- declare function fromTokenHolderPage(input: CursorPageDTO<Phase3TokenHolderDTO>): API.CursorList<TokenHolder>;
292
- declare function fromTokenPage(input: TokenPage): API.SearchTokenCursorList;
293
- declare function fromSwapRoute(input: SwapRouteResponse): API.SwapRoute;
294
- declare function fromLatestBlock(input: BlockchainLatestBlock): API.BlockchainLatestBlock;
295
- declare function fromSendTxResult(input: SendTxResponse): API.SendTxResult;
280
+ declare function toSwapRouteInput(params: SwapParams): SwapRouteInput;
281
+ declare function toSendTxInput(params: SendTxParams): SendTxInput;
282
+ declare function fromTokenHolderPage(input: CursorPageDTO<Phase3TokenHolderDTO>): CursorList<TokenHolder>;
283
+ declare function fromTokenPage(input: TokenPage): SearchTokenCursorList;
284
+ declare function fromSwapRoute(input: SwapRouteResponse): SwapRoute;
285
+ declare function fromLatestBlock(input: BlockchainLatestBlock$1): BlockchainLatestBlock;
286
+ declare function fromSendTxResult(input: SendTxResponse): SendTxResult;
296
287
  declare function fromWalletPortfolios(chain: Chain, input: WalletNetWorthPage): WalletPortfolios;
297
288
  declare function fromWalletPnlSummary(chain: Chain, address: string, input: WalletPnlSummary): WalletPnl;
298
289
  declare function fromPnlDetailsPage(chain: Chain, address: string, input: Phase3PnlDetailsDTO): WalletPortfolioPnls;
299
290
  declare function fromWalletNetWorthByTokens(chain: Chain, input: Phase3NetWorthByTokensDTO): Portfolio[];
300
291
  declare function fromPnlDetailItems(chain: Chain, input: PnlDetailsResult): PortfolioPnl[];
301
- declare function fromTradePage(input: PageResponseTradeDetail): API.CursorList<Trade>;
302
- declare function fromActivityPage(input: CursorPageDTO<Phase3ActivityDTO>): API.CursorList<Activity>;
303
- declare function fromTokenSubscribed(chain: Chain, input: WsNewToken): API.TokenSubscribed;
304
- declare function fromTokenMetadataSubscribed(chain: Chain, input: WsTokenMetadata): API.TokenSubscribed;
292
+ declare function fromTradePage(input: PageResponseTradeDetail): CursorList<Trade>;
293
+ declare function fromActivityPage(input: CursorPageDTO<Phase3ActivityDTO>): CursorList<Activity>;
294
+ declare function fromTokenSubscribed(chain: Chain, input: WsNewToken): TokenSubscribed;
295
+ declare function fromTokenMetadataSubscribed(chain: Chain, input: WsTokenMetadata): TokenSubscribed;
305
296
  declare function fromWsCandle(input: WsCandle): TokenCandle;
306
297
  declare function fromWsTokenStats(input: WsTokenStat): TokenStats;
307
298
  declare function fromWsTokenMarketDataFromStats(input: WsTokenStat): TokenMarketData;
308
- declare function fromWsTokenDataSubscribed(chain: Chain, input: WsTokenStat): API.TokenSubscribed;
309
- declare function fromWsTokenSupplyToSubscribed(chain: Chain, address: string, input: WsTokenSupply): API.TokenSubscribed;
310
- declare function fromWsTokenHolderToSubscribed(chain: Chain, address: string, input: WsTokenHolder): API.TokenSubscribed;
311
- declare function fromWsTokenLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenLiquidity): API.TokenSubscribed;
312
- declare function fromWsTokenBondingCurveToSubscribed(chain: Chain, input: WsTokenBondingCurve): API.TokenSubscribed;
313
- declare function fromWsTokenMaxLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenMaxLiquidity): API.TokenSubscribed;
314
- declare function fromWsTokenTotalLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenTotalLiquidity): API.TokenSubscribed;
299
+ declare function fromWsTokenDataSubscribed(chain: Chain, input: WsTokenStat): TokenSubscribed;
300
+ declare function fromWsTokenSupplyToSubscribed(chain: Chain, address: string, input: WsTokenSupply): TokenSubscribed;
301
+ declare function fromWsTokenHolderToSubscribed(chain: Chain, address: string, input: WsTokenHolder): TokenSubscribed;
302
+ declare function fromWsTokenLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenLiquidity): TokenSubscribed;
303
+ declare function fromWsTokenBondingCurveToSubscribed(chain: Chain, input: WsTokenBondingCurve): TokenSubscribed;
304
+ declare function fromWsTokenMaxLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenMaxLiquidity): TokenSubscribed;
305
+ declare function fromWsTokenTotalLiquidityToSubscribed(chain: Chain, address: string, input: WsTokenTotalLiquidity): TokenSubscribed;
315
306
  declare function fromWsTokenMarketDataFromHolder(input: WsTokenHolder): Partial<TokenMarketData>;
316
307
  declare function fromWsTradeActivity(chain: Chain, input: WsTradeActivity): Trade;
317
308
  declare function fromWsActivity(chain: Chain, input: WsTradeActivity): Activity;
318
309
 
319
- export { Client, type ClientOptions, type ClientTokenProvider, type ClientTokenProviderFn, KYBERSWAP_NATIVE_SENTINEL, NotImplementedError, fromActivityPage, fromChainDTO, fromLatestBlock, fromPnlDetailItems, fromPnlDetailsPage, fromSendTxResult, fromSwapRoute, fromTokenCandle, fromTokenCreatorDTO, fromTokenDTO, fromTokenHolderPage, fromTokenLiquidityDTO, fromTokenMarketDataDTO, fromTokenMetadataSubscribed, fromTokenPage, fromTokenSecurity, fromTokenStatsDTO, fromTokenSubscribed, fromTradePage, fromWalletNetWorthByTokens, fromWalletPnlSummary, fromWalletPortfolios, fromWsActivity, fromWsCandle, fromWsTokenBondingCurveToSubscribed, fromWsTokenDataSubscribed, fromWsTokenHolderToSubscribed, fromWsTokenLiquidityToSubscribed, fromWsTokenMarketDataFromHolder, fromWsTokenMarketDataFromStats, fromWsTokenMaxLiquidityToSubscribed, fromWsTokenStats, fromWsTokenSupplyToSubscribed, fromWsTokenTotalLiquidityToSubscribed, fromWsTradeActivity, isNotImplementedError, toChainDTO, toFieldDTO, toMintForRoute, toRangeFiltersDTO, toResolutionDTO, toSearchFieldDTO, toSendTxInput, toSortDirectionDTO, toSwapRouteInput, _default as version };
310
+ export { Client, type ClientOptions, type ClientTokenProvider, type ClientTokenProviderFn, KYBERSWAP_NATIVE_SENTINEL, NotImplementedError, fromActivityPage, fromChainDTO, fromLatestBlock, fromPnlDetailItems, fromPnlDetailsPage, fromSendTxResult, fromSwapRoute, fromTokenCandle, fromTokenCreatorDTO, fromTokenDTO, fromTokenHolderPage, fromTokenLiquidityDTO, fromTokenMarketDataDTO, fromTokenMetadataSubscribed, fromTokenPage, fromTokenSecurity, fromTokenStatsDTO, fromTokenSubscribed, fromTradePage, fromWalletNetWorthByTokens, fromWalletPnlSummary, fromWalletPortfolios, fromWsActivity, fromWsCandle, fromWsTokenBondingCurveToSubscribed, fromWsTokenDataSubscribed, fromWsTokenHolderToSubscribed, fromWsTokenLiquidityToSubscribed, fromWsTokenMarketDataFromHolder, fromWsTokenMarketDataFromStats, fromWsTokenMaxLiquidityToSubscribed, fromWsTokenStats, fromWsTokenSupplyToSubscribed, fromWsTokenTotalLiquidityToSubscribed, fromWsTradeActivity, isNotImplementedError, toChainDTO, toFieldDTO, toMintForRoute, toRangeFiltersDTO, toResolutionDTO, toSearchFieldDTO, toSendTxInput, toSortDirectionDTO, toSwapRouteInput };