@swapkit/core 1.0.0-rc.8 → 1.0.0-rc.80
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.cjs +3 -2
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +9 -4
- package/dist/index.es.js +6047 -816
- package/dist/index.es.js.map +1 -0
- package/package.json +21 -24
- package/src/aggregator/contracts/index.ts +2 -0
- package/src/aggregator/contracts/routers/index.ts +58 -0
- package/src/aggregator/contracts/routers/kyber.ts +402 -0
- package/src/aggregator/contracts/routers/oneinch.ts +2188 -0
- package/src/aggregator/contracts/routers/pancakeswap.ts +340 -0
- package/src/aggregator/contracts/routers/pangolin.ts +340 -0
- package/src/aggregator/contracts/routers/sushiswap.ts +340 -0
- package/src/aggregator/contracts/routers/traderJoe.ts +340 -0
- package/src/aggregator/contracts/routers/uniswapv2.ts +340 -0
- package/src/aggregator/contracts/routers/uniswapv3.ts +254 -0
- package/src/aggregator/contracts/routers/woofi.ts +171 -0
- package/src/client/__tests__/helpers.test.ts +41 -33
- package/src/client/explorerUrls.ts +7 -8
- package/src/client/index.ts +141 -73
- package/src/client/thornode.ts +3 -3
- package/dist/index-9e36735e.cjs +0 -1
- package/dist/index-cf1865cd.js +0 -649
package/dist/index.d.ts
CHANGED
|
@@ -69,9 +69,9 @@ export declare class SwapKitCore<T = ''> {
|
|
|
69
69
|
getExplorerTxUrl: (chain: Chain, txHash: string) => string;
|
|
70
70
|
getWallet: <T_1 extends Chain>(chain: Chain) => WalletMethods[T_1];
|
|
71
71
|
getExplorerAddressUrl: (chain: Chain, address: string) => string;
|
|
72
|
-
getBalance: (chain: Chain,
|
|
72
|
+
getBalance: (chain: Chain, potentialScamFilter?: boolean) => Promise<AssetValue[]>;
|
|
73
73
|
swap: ({ streamSwap, recipient, route, feeOptionKey }: SwapParams) => Promise<string>;
|
|
74
|
-
getWalletByChain: (chain: Chain) => Promise<{
|
|
74
|
+
getWalletByChain: (chain: Chain, potentialScamFilter?: boolean) => Promise<{
|
|
75
75
|
address?: string | undefined;
|
|
76
76
|
balance?: AssetValue[] | undefined;
|
|
77
77
|
walletType?: WalletOption | undefined;
|
|
@@ -98,8 +98,7 @@ export declare class SwapKitCore<T = ''> {
|
|
|
98
98
|
runeTx: string;
|
|
99
99
|
assetTx: string;
|
|
100
100
|
}>;
|
|
101
|
-
addLiquidity: ({
|
|
102
|
-
poolIdentifier: string;
|
|
101
|
+
addLiquidity: ({ runeAssetValue, assetValue, runeAddr, assetAddr, isPendingSymmAsset, mode, }: {
|
|
103
102
|
runeAssetValue: AssetValue;
|
|
104
103
|
assetValue: AssetValue;
|
|
105
104
|
isPendingSymmAsset?: boolean | undefined;
|
|
@@ -110,6 +109,12 @@ export declare class SwapKitCore<T = ''> {
|
|
|
110
109
|
runeTx: string | undefined;
|
|
111
110
|
assetTx: string | undefined;
|
|
112
111
|
}>;
|
|
112
|
+
addLiquidityPart: ({ assetValue, poolAddress, address, symmetric, }: {
|
|
113
|
+
assetValue: AssetValue;
|
|
114
|
+
address?: string | undefined;
|
|
115
|
+
poolAddress: string;
|
|
116
|
+
symmetric: boolean;
|
|
117
|
+
}) => Promise<string>;
|
|
113
118
|
withdraw: ({ memo, assetValue, percent, from, to, }: {
|
|
114
119
|
memo?: string | undefined;
|
|
115
120
|
assetValue: AssetValue;
|