@dzapio/sdk 2.0.29 → 2.0.31
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.mts +16 -10
- package/dist/index.d.ts +16 -10
- package/dist/index.js +45 -2
- package/dist/index.mjs +46 -4
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as viem from 'viem';
|
|
2
|
-
import { WalletCallReceipt as WalletCallReceipt$1, TypedDataDomain, Prettify, WalletClient, TransactionReceipt } from 'viem';
|
|
2
|
+
import { WalletCallReceipt as WalletCallReceipt$1, TypedDataDomain, Prettify, WalletClient, TransactionReceipt, ChainFormatters, Chain as Chain$1, Assign } from 'viem';
|
|
3
3
|
import { Signer } from 'ethers';
|
|
4
4
|
|
|
5
5
|
declare const STATUS: {
|
|
@@ -268,6 +268,7 @@ type ProtocolFilter = {
|
|
|
268
268
|
type TradeQuotesRequest = {
|
|
269
269
|
fromChain: number;
|
|
270
270
|
gasless?: boolean;
|
|
271
|
+
private?: boolean;
|
|
271
272
|
data: TradeQuotesRequestData[];
|
|
272
273
|
disableEstimation?: boolean;
|
|
273
274
|
account?: string;
|
|
@@ -393,6 +394,7 @@ type TradeBuildTxnRequest = {
|
|
|
393
394
|
refundee: HexString;
|
|
394
395
|
fromChain: number;
|
|
395
396
|
gasless: boolean;
|
|
397
|
+
private?: boolean;
|
|
396
398
|
disableEstimation?: boolean;
|
|
397
399
|
data: TradeBuildTxnRequestData[];
|
|
398
400
|
hasPermit2ApprovalForAllTokens?: boolean;
|
|
@@ -438,7 +440,12 @@ type BtcTxData = {
|
|
|
438
440
|
outputs: PsbtOutput[];
|
|
439
441
|
feeRate: number;
|
|
440
442
|
};
|
|
441
|
-
type
|
|
443
|
+
type BtclnTxData = {
|
|
444
|
+
paymentRequestType: 'bolt11';
|
|
445
|
+
paymentRequest: string;
|
|
446
|
+
paymentExpiry: number;
|
|
447
|
+
};
|
|
448
|
+
type TxData = EvmTxData | SvmTxData | BtcTxData | BtclnTxData;
|
|
442
449
|
type TxRequestData<T> = {
|
|
443
450
|
status: typeof STATUS.success;
|
|
444
451
|
txId: string;
|
|
@@ -464,6 +471,7 @@ type TradeBuildTxnResponse = TradeGasBuildTxnResponse & {
|
|
|
464
471
|
outputs: PsbtOutput[];
|
|
465
472
|
feeRate: number;
|
|
466
473
|
};
|
|
474
|
+
btclnTxData?: BtclnTxData;
|
|
467
475
|
additionalInfo: Record<string, Record<string, unknown>>;
|
|
468
476
|
updatedQuotes: Record<string, string>;
|
|
469
477
|
};
|
|
@@ -651,7 +659,7 @@ type ZapPath = {
|
|
|
651
659
|
asset: ZapPathAsset;
|
|
652
660
|
amount: string;
|
|
653
661
|
amountUSD: string;
|
|
654
|
-
|
|
662
|
+
minAmount: string;
|
|
655
663
|
}[];
|
|
656
664
|
};
|
|
657
665
|
|
|
@@ -720,12 +728,8 @@ type ZapBuildTxnResponse = {
|
|
|
720
728
|
approveTo: HexString;
|
|
721
729
|
amount: string;
|
|
722
730
|
}[];
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
amount: string;
|
|
726
|
-
chainId: number;
|
|
727
|
-
minAmount: string;
|
|
728
|
-
}[];
|
|
731
|
+
dust: ZapPath['output'];
|
|
732
|
+
output: ZapPath['output'];
|
|
729
733
|
steps: ZapStep[];
|
|
730
734
|
path: ZapPath[];
|
|
731
735
|
};
|
|
@@ -1958,6 +1962,8 @@ declare const checkEIP2612PermitSupport: ({ address, chainId, rpcUrls, owner, pe
|
|
|
1958
1962
|
};
|
|
1959
1963
|
}>;
|
|
1960
1964
|
|
|
1965
|
+
declare function extendViemChain<Formatters extends ChainFormatters, const Base extends Chain$1<ChainFormatters>, const Extension extends Partial<Chain$1<Formatters>>>(base: Base, extension: Extension): Prettify<Assign<Chain$1<undefined>, Assign<Base, Extension>>>;
|
|
1966
|
+
|
|
1961
1967
|
declare const formatToken: <T extends HexString | string = string>(token: T, nativeTokenAddress?: T) => T;
|
|
1962
1968
|
|
|
1963
|
-
export { type AllowanceType, AllowanceTypes, type ApiRpcResponse, type ApprovalMode, ApprovalModes, type BatchPermitCallbackParams, type BtcTxData, type Chain, type ChainData, type ContractErrorResponse, DZapClient, DZapPermitMode, type DZapTransactionResponse, type EvmTxData, type Fee, type FeeDetails, type GaslessTradeBuildTxnResponse, type HexString, OtherAbis, type ParamQuotes, type PermitMode, PermitTypes, type ProviderDetails, type PsbtInput, type PsbtOutput, type QuoteFilter, QuoteFilters, STATUS, type SVMTxnDetails, Services, type SignPermitResponse, type SignatureCallbackParams, SignatureExpiryInSecs, type SinglePermitCallbackParams, StatusCodes, type StepAction, type SvmTxData, type SwapInfo, SwapInputDataDecoder, type Token, type TokenInfo, type TokenPermitData, type TokenResponse, type TradeBuildTxnRequest, type TradeBuildTxnRequestData, type TradeBuildTxnResponse, type TradeGasBuildTxnResponse, type TradePath, type TradeQuotesRequest, type TradeQuotesRequestData, type TradeQuotesResponse, type TradeStatusResponse, type TradeStep, TxnStatus, type ZapBuildTxnRequest, type ZapBuildTxnResponse, type ZapBundleAction, type ZapBundleRequest, type ZapBundleSrcToken, type ZapBvmTxnDetails, type ZapChains, type ZapEvmTxnDetails, type ZapFee, type ZapIntegratorConfig, type ZapPath, type ZapPathAction, type ZapPathAsset, type ZapPool, type ZapPoolDetails, type ZapPoolDetailsRequest, type ZapPoolsRequest, type ZapPoolsResponse, type ZapPosition, type ZapPositionsRequest, type ZapPositionsResponse, type ZapProviders, type ZapQuoteRequest, type ZapQuoteResponse, type ZapRouteRequestPoolDetails, type ZapRouteRequestPositionDetails, type ZapStatus, type ZapStatusAsset, type ZapStatusRequest, type ZapStatusResponse, type ZapStatusStep, type ZapStep, type ZapTransactionStep, type ZapTxnDetails, type ZapUnderlyingToken, type ZapUnderlyingTokenWithAmount, checkEIP2612PermitSupport, contractErrorActions, erc20Functions, formatToken, getTokensPairKey, zapPathAction, zapStepAction };
|
|
1969
|
+
export { type AllowanceType, AllowanceTypes, type ApiRpcResponse, type ApprovalMode, ApprovalModes, type BatchPermitCallbackParams, type BtcTxData, type BtclnTxData, type Chain, type ChainData, type ContractErrorResponse, DZapClient, DZapPermitMode, type DZapTransactionResponse, type EvmTxData, type Fee, type FeeDetails, type GaslessTradeBuildTxnResponse, type HexString, OtherAbis, type ParamQuotes, type PermitMode, PermitTypes, type ProviderDetails, type PsbtInput, type PsbtOutput, type QuoteFilter, QuoteFilters, STATUS, type SVMTxnDetails, Services, type SignPermitResponse, type SignatureCallbackParams, SignatureExpiryInSecs, type SinglePermitCallbackParams, StatusCodes, type StepAction, type SvmTxData, type SwapInfo, SwapInputDataDecoder, type Token, type TokenInfo, type TokenPermitData, type TokenResponse, type TradeBuildTxnRequest, type TradeBuildTxnRequestData, type TradeBuildTxnResponse, type TradeGasBuildTxnResponse, type TradePath, type TradeQuotesRequest, type TradeQuotesRequestData, type TradeQuotesResponse, type TradeStatusResponse, type TradeStep, TxnStatus, type ZapBuildTxnRequest, type ZapBuildTxnResponse, type ZapBundleAction, type ZapBundleRequest, type ZapBundleSrcToken, type ZapBvmTxnDetails, type ZapChains, type ZapEvmTxnDetails, type ZapFee, type ZapIntegratorConfig, type ZapPath, type ZapPathAction, type ZapPathAsset, type ZapPool, type ZapPoolDetails, type ZapPoolDetailsRequest, type ZapPoolsRequest, type ZapPoolsResponse, type ZapPosition, type ZapPositionsRequest, type ZapPositionsResponse, type ZapProviders, type ZapQuoteRequest, type ZapQuoteResponse, type ZapRouteRequestPoolDetails, type ZapRouteRequestPositionDetails, type ZapStatus, type ZapStatusAsset, type ZapStatusRequest, type ZapStatusResponse, type ZapStatusStep, type ZapStep, type ZapTransactionStep, type ZapTxnDetails, type ZapUnderlyingToken, type ZapUnderlyingTokenWithAmount, checkEIP2612PermitSupport, contractErrorActions, erc20Functions, extendViemChain, formatToken, getTokensPairKey, zapPathAction, zapStepAction };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as viem from 'viem';
|
|
2
|
-
import { WalletCallReceipt as WalletCallReceipt$1, TypedDataDomain, Prettify, WalletClient, TransactionReceipt } from 'viem';
|
|
2
|
+
import { WalletCallReceipt as WalletCallReceipt$1, TypedDataDomain, Prettify, WalletClient, TransactionReceipt, ChainFormatters, Chain as Chain$1, Assign } from 'viem';
|
|
3
3
|
import { Signer } from 'ethers';
|
|
4
4
|
|
|
5
5
|
declare const STATUS: {
|
|
@@ -268,6 +268,7 @@ type ProtocolFilter = {
|
|
|
268
268
|
type TradeQuotesRequest = {
|
|
269
269
|
fromChain: number;
|
|
270
270
|
gasless?: boolean;
|
|
271
|
+
private?: boolean;
|
|
271
272
|
data: TradeQuotesRequestData[];
|
|
272
273
|
disableEstimation?: boolean;
|
|
273
274
|
account?: string;
|
|
@@ -393,6 +394,7 @@ type TradeBuildTxnRequest = {
|
|
|
393
394
|
refundee: HexString;
|
|
394
395
|
fromChain: number;
|
|
395
396
|
gasless: boolean;
|
|
397
|
+
private?: boolean;
|
|
396
398
|
disableEstimation?: boolean;
|
|
397
399
|
data: TradeBuildTxnRequestData[];
|
|
398
400
|
hasPermit2ApprovalForAllTokens?: boolean;
|
|
@@ -438,7 +440,12 @@ type BtcTxData = {
|
|
|
438
440
|
outputs: PsbtOutput[];
|
|
439
441
|
feeRate: number;
|
|
440
442
|
};
|
|
441
|
-
type
|
|
443
|
+
type BtclnTxData = {
|
|
444
|
+
paymentRequestType: 'bolt11';
|
|
445
|
+
paymentRequest: string;
|
|
446
|
+
paymentExpiry: number;
|
|
447
|
+
};
|
|
448
|
+
type TxData = EvmTxData | SvmTxData | BtcTxData | BtclnTxData;
|
|
442
449
|
type TxRequestData<T> = {
|
|
443
450
|
status: typeof STATUS.success;
|
|
444
451
|
txId: string;
|
|
@@ -464,6 +471,7 @@ type TradeBuildTxnResponse = TradeGasBuildTxnResponse & {
|
|
|
464
471
|
outputs: PsbtOutput[];
|
|
465
472
|
feeRate: number;
|
|
466
473
|
};
|
|
474
|
+
btclnTxData?: BtclnTxData;
|
|
467
475
|
additionalInfo: Record<string, Record<string, unknown>>;
|
|
468
476
|
updatedQuotes: Record<string, string>;
|
|
469
477
|
};
|
|
@@ -651,7 +659,7 @@ type ZapPath = {
|
|
|
651
659
|
asset: ZapPathAsset;
|
|
652
660
|
amount: string;
|
|
653
661
|
amountUSD: string;
|
|
654
|
-
|
|
662
|
+
minAmount: string;
|
|
655
663
|
}[];
|
|
656
664
|
};
|
|
657
665
|
|
|
@@ -720,12 +728,8 @@ type ZapBuildTxnResponse = {
|
|
|
720
728
|
approveTo: HexString;
|
|
721
729
|
amount: string;
|
|
722
730
|
}[];
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
amount: string;
|
|
726
|
-
chainId: number;
|
|
727
|
-
minAmount: string;
|
|
728
|
-
}[];
|
|
731
|
+
dust: ZapPath['output'];
|
|
732
|
+
output: ZapPath['output'];
|
|
729
733
|
steps: ZapStep[];
|
|
730
734
|
path: ZapPath[];
|
|
731
735
|
};
|
|
@@ -1958,6 +1962,8 @@ declare const checkEIP2612PermitSupport: ({ address, chainId, rpcUrls, owner, pe
|
|
|
1958
1962
|
};
|
|
1959
1963
|
}>;
|
|
1960
1964
|
|
|
1965
|
+
declare function extendViemChain<Formatters extends ChainFormatters, const Base extends Chain$1<ChainFormatters>, const Extension extends Partial<Chain$1<Formatters>>>(base: Base, extension: Extension): Prettify<Assign<Chain$1<undefined>, Assign<Base, Extension>>>;
|
|
1966
|
+
|
|
1961
1967
|
declare const formatToken: <T extends HexString | string = string>(token: T, nativeTokenAddress?: T) => T;
|
|
1962
1968
|
|
|
1963
|
-
export { type AllowanceType, AllowanceTypes, type ApiRpcResponse, type ApprovalMode, ApprovalModes, type BatchPermitCallbackParams, type BtcTxData, type Chain, type ChainData, type ContractErrorResponse, DZapClient, DZapPermitMode, type DZapTransactionResponse, type EvmTxData, type Fee, type FeeDetails, type GaslessTradeBuildTxnResponse, type HexString, OtherAbis, type ParamQuotes, type PermitMode, PermitTypes, type ProviderDetails, type PsbtInput, type PsbtOutput, type QuoteFilter, QuoteFilters, STATUS, type SVMTxnDetails, Services, type SignPermitResponse, type SignatureCallbackParams, SignatureExpiryInSecs, type SinglePermitCallbackParams, StatusCodes, type StepAction, type SvmTxData, type SwapInfo, SwapInputDataDecoder, type Token, type TokenInfo, type TokenPermitData, type TokenResponse, type TradeBuildTxnRequest, type TradeBuildTxnRequestData, type TradeBuildTxnResponse, type TradeGasBuildTxnResponse, type TradePath, type TradeQuotesRequest, type TradeQuotesRequestData, type TradeQuotesResponse, type TradeStatusResponse, type TradeStep, TxnStatus, type ZapBuildTxnRequest, type ZapBuildTxnResponse, type ZapBundleAction, type ZapBundleRequest, type ZapBundleSrcToken, type ZapBvmTxnDetails, type ZapChains, type ZapEvmTxnDetails, type ZapFee, type ZapIntegratorConfig, type ZapPath, type ZapPathAction, type ZapPathAsset, type ZapPool, type ZapPoolDetails, type ZapPoolDetailsRequest, type ZapPoolsRequest, type ZapPoolsResponse, type ZapPosition, type ZapPositionsRequest, type ZapPositionsResponse, type ZapProviders, type ZapQuoteRequest, type ZapQuoteResponse, type ZapRouteRequestPoolDetails, type ZapRouteRequestPositionDetails, type ZapStatus, type ZapStatusAsset, type ZapStatusRequest, type ZapStatusResponse, type ZapStatusStep, type ZapStep, type ZapTransactionStep, type ZapTxnDetails, type ZapUnderlyingToken, type ZapUnderlyingTokenWithAmount, checkEIP2612PermitSupport, contractErrorActions, erc20Functions, formatToken, getTokensPairKey, zapPathAction, zapStepAction };
|
|
1969
|
+
export { type AllowanceType, AllowanceTypes, type ApiRpcResponse, type ApprovalMode, ApprovalModes, type BatchPermitCallbackParams, type BtcTxData, type BtclnTxData, type Chain, type ChainData, type ContractErrorResponse, DZapClient, DZapPermitMode, type DZapTransactionResponse, type EvmTxData, type Fee, type FeeDetails, type GaslessTradeBuildTxnResponse, type HexString, OtherAbis, type ParamQuotes, type PermitMode, PermitTypes, type ProviderDetails, type PsbtInput, type PsbtOutput, type QuoteFilter, QuoteFilters, STATUS, type SVMTxnDetails, Services, type SignPermitResponse, type SignatureCallbackParams, SignatureExpiryInSecs, type SinglePermitCallbackParams, StatusCodes, type StepAction, type SvmTxData, type SwapInfo, SwapInputDataDecoder, type Token, type TokenInfo, type TokenPermitData, type TokenResponse, type TradeBuildTxnRequest, type TradeBuildTxnRequestData, type TradeBuildTxnResponse, type TradeGasBuildTxnResponse, type TradePath, type TradeQuotesRequest, type TradeQuotesRequestData, type TradeQuotesResponse, type TradeStatusResponse, type TradeStep, TxnStatus, type ZapBuildTxnRequest, type ZapBuildTxnResponse, type ZapBundleAction, type ZapBundleRequest, type ZapBundleSrcToken, type ZapBvmTxnDetails, type ZapChains, type ZapEvmTxnDetails, type ZapFee, type ZapIntegratorConfig, type ZapPath, type ZapPathAction, type ZapPathAsset, type ZapPool, type ZapPoolDetails, type ZapPoolDetailsRequest, type ZapPoolsRequest, type ZapPoolsResponse, type ZapPosition, type ZapPositionsRequest, type ZapPositionsResponse, type ZapProviders, type ZapQuoteRequest, type ZapQuoteResponse, type ZapRouteRequestPoolDetails, type ZapRouteRequestPositionDetails, type ZapStatus, type ZapStatusAsset, type ZapStatusRequest, type ZapStatusResponse, type ZapStatusStep, type ZapStep, type ZapTransactionStep, type ZapTxnDetails, type ZapUnderlyingToken, type ZapUnderlyingTokenWithAmount, checkEIP2612PermitSupport, contractErrorActions, erc20Functions, extendViemChain, formatToken, getTokensPairKey, zapPathAction, zapStepAction };
|
package/dist/index.js
CHANGED
|
@@ -10680,6 +10680,28 @@ var fiveIre = /* @__PURE__ */ viem.defineChain({
|
|
|
10680
10680
|
}
|
|
10681
10681
|
}
|
|
10682
10682
|
});
|
|
10683
|
+
|
|
10684
|
+
// src/utils/extendViemChain.ts
|
|
10685
|
+
function extendViemChain(base, extension) {
|
|
10686
|
+
const chain = {
|
|
10687
|
+
formatters: void 0,
|
|
10688
|
+
fees: void 0,
|
|
10689
|
+
serializers: void 0,
|
|
10690
|
+
...base,
|
|
10691
|
+
...extension
|
|
10692
|
+
};
|
|
10693
|
+
return chain;
|
|
10694
|
+
}
|
|
10695
|
+
|
|
10696
|
+
// src/chains/definitions/hemi.ts
|
|
10697
|
+
var hemi = extendViemChain(viemChains.hemi, {
|
|
10698
|
+
contracts: {
|
|
10699
|
+
multicall3: {
|
|
10700
|
+
address: "0xcA11bde05977b3631167028862bE2a173976CA11",
|
|
10701
|
+
blockCreated: 4502791
|
|
10702
|
+
}
|
|
10703
|
+
}
|
|
10704
|
+
});
|
|
10683
10705
|
var hyperEvm = /* @__PURE__ */ viem.defineChain({
|
|
10684
10706
|
id: 999,
|
|
10685
10707
|
name: "HyperEVM",
|
|
@@ -10784,9 +10806,28 @@ var tempo = viemChains.tempo.extend({
|
|
|
10784
10806
|
}
|
|
10785
10807
|
}
|
|
10786
10808
|
});
|
|
10809
|
+
var citrea = extendViemChain(viemChains.citrea, {
|
|
10810
|
+
contracts: {
|
|
10811
|
+
multicall3: {
|
|
10812
|
+
address: "0xA738e84fdE890Bc60b99AF7ccE43990E534304de",
|
|
10813
|
+
blockCreated: 2450100
|
|
10814
|
+
}
|
|
10815
|
+
}
|
|
10816
|
+
});
|
|
10787
10817
|
|
|
10788
10818
|
// src/chains/index.ts
|
|
10789
|
-
var customViemChains = [
|
|
10819
|
+
var customViemChains = [
|
|
10820
|
+
fiveIre,
|
|
10821
|
+
arthera,
|
|
10822
|
+
hyperEvm,
|
|
10823
|
+
hyperliquid,
|
|
10824
|
+
stableChain,
|
|
10825
|
+
pushTestnet,
|
|
10826
|
+
astralisTestnet,
|
|
10827
|
+
tempo,
|
|
10828
|
+
hemi,
|
|
10829
|
+
citrea
|
|
10830
|
+
];
|
|
10790
10831
|
var viemChainsById = [...Object.values(viemChains__namespace), ...customViemChains].reduce((acc, chainData) => {
|
|
10791
10832
|
return chainData.id ? {
|
|
10792
10833
|
...acc,
|
|
@@ -12846,7 +12887,8 @@ var exclusiveChainIds = {
|
|
|
12846
12887
|
hyperLiquid: 998,
|
|
12847
12888
|
citrea: 4114,
|
|
12848
12889
|
pushTestnet: 42101,
|
|
12849
|
-
astralisTestnet: 71261
|
|
12890
|
+
astralisTestnet: 71261,
|
|
12891
|
+
btcln: 1002
|
|
12850
12892
|
};
|
|
12851
12893
|
|
|
12852
12894
|
// src/constants/contract.ts
|
|
@@ -16399,6 +16441,7 @@ exports.TxnStatus = TxnStatus;
|
|
|
16399
16441
|
exports.checkEIP2612PermitSupport = checkEIP2612PermitSupport;
|
|
16400
16442
|
exports.contractErrorActions = contractErrorActions;
|
|
16401
16443
|
exports.erc20Functions = erc20Functions;
|
|
16444
|
+
exports.extendViemChain = extendViemChain;
|
|
16402
16445
|
exports.formatToken = formatToken;
|
|
16403
16446
|
exports.getTokensPairKey = getTokensPairKey;
|
|
16404
16447
|
exports.zapPathAction = zapPathAction;
|
package/dist/index.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import { encodeAbiParameters, parseAbiParameters, keccak256, encodePacked, strin
|
|
|
2
2
|
import Axios from 'axios';
|
|
3
3
|
import { Signer, ethers } from 'ethers';
|
|
4
4
|
import * as viemChains from 'viem/chains';
|
|
5
|
-
import { tempo as tempo$1 } from 'viem/chains';
|
|
5
|
+
import { tempo as tempo$1, hemi as hemi$1, citrea as citrea$1 } from 'viem/chains';
|
|
6
6
|
import { decodeFunctionData, getAction } from 'viem/utils';
|
|
7
7
|
import { waitForCallsStatus, sendCalls } from 'viem/actions';
|
|
8
8
|
import Decimal from 'decimal.js';
|
|
@@ -10655,6 +10655,28 @@ var fiveIre = /* @__PURE__ */ defineChain({
|
|
|
10655
10655
|
}
|
|
10656
10656
|
}
|
|
10657
10657
|
});
|
|
10658
|
+
|
|
10659
|
+
// src/utils/extendViemChain.ts
|
|
10660
|
+
function extendViemChain(base, extension) {
|
|
10661
|
+
const chain = {
|
|
10662
|
+
formatters: void 0,
|
|
10663
|
+
fees: void 0,
|
|
10664
|
+
serializers: void 0,
|
|
10665
|
+
...base,
|
|
10666
|
+
...extension
|
|
10667
|
+
};
|
|
10668
|
+
return chain;
|
|
10669
|
+
}
|
|
10670
|
+
|
|
10671
|
+
// src/chains/definitions/hemi.ts
|
|
10672
|
+
var hemi = extendViemChain(hemi$1, {
|
|
10673
|
+
contracts: {
|
|
10674
|
+
multicall3: {
|
|
10675
|
+
address: "0xcA11bde05977b3631167028862bE2a173976CA11",
|
|
10676
|
+
blockCreated: 4502791
|
|
10677
|
+
}
|
|
10678
|
+
}
|
|
10679
|
+
});
|
|
10658
10680
|
var hyperEvm = /* @__PURE__ */ defineChain({
|
|
10659
10681
|
id: 999,
|
|
10660
10682
|
name: "HyperEVM",
|
|
@@ -10759,9 +10781,28 @@ var tempo = tempo$1.extend({
|
|
|
10759
10781
|
}
|
|
10760
10782
|
}
|
|
10761
10783
|
});
|
|
10784
|
+
var citrea = extendViemChain(citrea$1, {
|
|
10785
|
+
contracts: {
|
|
10786
|
+
multicall3: {
|
|
10787
|
+
address: "0xA738e84fdE890Bc60b99AF7ccE43990E534304de",
|
|
10788
|
+
blockCreated: 2450100
|
|
10789
|
+
}
|
|
10790
|
+
}
|
|
10791
|
+
});
|
|
10762
10792
|
|
|
10763
10793
|
// src/chains/index.ts
|
|
10764
|
-
var customViemChains = [
|
|
10794
|
+
var customViemChains = [
|
|
10795
|
+
fiveIre,
|
|
10796
|
+
arthera,
|
|
10797
|
+
hyperEvm,
|
|
10798
|
+
hyperliquid,
|
|
10799
|
+
stableChain,
|
|
10800
|
+
pushTestnet,
|
|
10801
|
+
astralisTestnet,
|
|
10802
|
+
tempo,
|
|
10803
|
+
hemi,
|
|
10804
|
+
citrea
|
|
10805
|
+
];
|
|
10765
10806
|
var viemChainsById = [...Object.values(viemChains), ...customViemChains].reduce((acc, chainData) => {
|
|
10766
10807
|
return chainData.id ? {
|
|
10767
10808
|
...acc,
|
|
@@ -12821,7 +12862,8 @@ var exclusiveChainIds = {
|
|
|
12821
12862
|
hyperLiquid: 998,
|
|
12822
12863
|
citrea: 4114,
|
|
12823
12864
|
pushTestnet: 42101,
|
|
12824
|
-
astralisTestnet: 71261
|
|
12865
|
+
astralisTestnet: 71261,
|
|
12866
|
+
btcln: 1002
|
|
12825
12867
|
};
|
|
12826
12868
|
|
|
12827
12869
|
// src/constants/contract.ts
|
|
@@ -16358,4 +16400,4 @@ var zapPathAction = {
|
|
|
16358
16400
|
harvest: "harvest"
|
|
16359
16401
|
};
|
|
16360
16402
|
|
|
16361
|
-
export { AllowanceTypes, ApprovalModes, dZapClient_default as DZapClient, DZapPermitMode, OtherAbis, PermitTypes, QuoteFilters, STATUS, Services, SignatureExpiryInSecs, StatusCodes, SwapInputDataDecoder, TxnStatus, checkEIP2612PermitSupport, contractErrorActions, erc20Functions, formatToken, getTokensPairKey, zapPathAction, zapStepAction };
|
|
16403
|
+
export { AllowanceTypes, ApprovalModes, dZapClient_default as DZapClient, DZapPermitMode, OtherAbis, PermitTypes, QuoteFilters, STATUS, Services, SignatureExpiryInSecs, StatusCodes, SwapInputDataDecoder, TxnStatus, checkEIP2612PermitSupport, contractErrorActions, erc20Functions, extendViemChain, formatToken, getTokensPairKey, zapPathAction, zapStepAction };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dzapio/sdk",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.31",
|
|
4
4
|
"description": "A TypeScript/JavaScript SDK for interacting with the DZap protocol, providing utilities for DeFi operations including Swaps, Bridges, and Zaps.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"source": "src/index.ts",
|
|
@@ -108,7 +108,7 @@
|
|
|
108
108
|
"decimal.js": "^10.4.3",
|
|
109
109
|
"node-cache": "^5.1.2",
|
|
110
110
|
"ethers": "5.7.2",
|
|
111
|
-
"viem": "2.
|
|
111
|
+
"viem": "2.48.4"
|
|
112
112
|
},
|
|
113
113
|
"repository": {
|
|
114
114
|
"type": "git",
|