import { Address, Hash, Hex, PublicClient, SignTypedDataReturnType, TypedData, TypedDataDomain, WalletClient } from 'viem'; import { MarkRequired } from '@catalogfi/utils'; import { AtomicSwapConfig } from '../ASConfig'; import { IBaseWallet, WalletChain } from '../baseWallet'; import { IHTLCWallet } from '../htlc'; export type EVMSwapConfig = MarkRequired; export interface IEVMWallet extends IBaseWallet { contractCall(contractCallConfig: { to: Address; data: Hex; from?: Address; value?: bigint; }): Promise; getAddress(): Promise
; getPublicClient(): PublicClient; rpc(name: string, args: unknown[] | Record): Promise; signTypedData(domain: TypedDataDomain, types: Record, value: Record, primaryType: string): Promise; getSigner(): WalletClient; } export declare abstract class AbstractEVMWallet implements IEVMWallet { abstract sign(hexMsg: string): Promise; abstract contractCall(contractCallConfig: { to: Address; data: Hex; from?: Address; value?: bigint; }): Promise; abstract getAddress(): Promise
; abstract getPublicClient(): PublicClient; abstract rpc(name: string, args: unknown[] | Record): Promise; abstract signTypedData(domain: TypedDataDomain, types: Record, value: Record, primaryType: string): Promise; newSwap(swapConfig: EVMSwapConfig): Promise; /** * Returns the chain of the wallet. It can be Bitcoin or EVM */ chain(): WalletChain; abstract getSigner(): WalletClient; } export declare class EVMHTLC implements IHTLCWallet { private swap; private readonly wallet; /** * @constructor * @param {EVMSwapConfig} swap - Atomic swap config, chain must be provided * @param {IEVMWallet} wallet */ constructor(swap: EVMSwapConfig, wallet: IEVMWallet); getHTLCContract(): Promise<{ read: { eip712Domain: (options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; orders: (args: readonly [`0x${string}`], options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; token: (options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise<`0x${string}`>; }; estimateGas: { initiate: (args: readonly [`0x${string}`, bigint, bigint, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; initiateWithSignature: (args: readonly [`0x${string}`, bigint, bigint, `0x${string}`, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; instantRefund: (args: readonly [`0x${string}`, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; multicall: (args: readonly [readonly { redeemer: `0x${string}`; expiry: bigint; amount: bigint; secretHash: `0x${string}`; signature: `0x${string}`; }[], readonly { orderID: `0x${string}`; secret: `0x${string}`; }[], readonly { orderID: `0x${string}`; }[]], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; redeem: (args: readonly [`0x${string}`, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; refund: (args: readonly [`0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; } & { initiate: (args: readonly [`0x${string}`, bigint, bigint, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; initiateWithSignature: (args: readonly [`0x${string}`, bigint, bigint, `0x${string}`, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; instantRefund: (args: readonly [`0x${string}`, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; multicall: (args: readonly [readonly { redeemer: `0x${string}`; expiry: bigint; amount: bigint; secretHash: `0x${string}`; signature: `0x${string}`; }[], readonly { orderID: `0x${string}`; secret: `0x${string}`; }[], readonly { orderID: `0x${string}`; }[]], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; redeem: (args: readonly [`0x${string}`, `0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; refund: (args: readonly [`0x${string}`], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; }; simulate: { initiate: (args: readonly [`0x${string}`, bigint, bigint, `0x${string}`], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; initiateWithSignature: (args: readonly [`0x${string}`, bigint, bigint, `0x${string}`, `0x${string}`], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; instantRefund: (args: readonly [`0x${string}`, `0x${string}`], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; multicall: (args: readonly [readonly { redeemer: `0x${string}`; expiry: bigint; amount: bigint; secretHash: `0x${string}`; signature: `0x${string}`; }[], readonly { orderID: `0x${string}`; secret: `0x${string}`; }[], readonly { orderID: `0x${string}`; }[]], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; redeem: (args: readonly [`0x${string}`, `0x${string}`], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; refund: (args: readonly [`0x${string}`], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; }; createEventFilter: { EIP712DomainChanged: (options?: ({ fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } & { strict?: strict | undefined; }) | undefined) => Promise>; Initiated: (args: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } | ({ orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } extends infer T ? T extends { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } ? T extends args_1 ? Readonly : never : never : never), options?: ({ fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } & { strict?: strict_1 | undefined; }) | undefined) => Promise>; Redeemed: (args: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } | ({ orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } extends infer T_1 ? T_1 extends { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } ? T_1 extends args_2 ? Readonly : never : never : never), options?: ({ fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } & { strict?: strict_2 | undefined; }) | undefined) => Promise>; Refunded: (args: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; } | ({ orderID?: `0x${string}` | `0x${string}`[] | null | undefined; } extends infer T_2 ? T_2 extends { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; } ? T_2 extends args_3 ? Readonly : never : never : never), options?: ({ fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } & { strict?: strict_3 | undefined; }) | undefined) => Promise>; }; getEvents: { EIP712DomainChanged: (options?: { strict?: boolean | undefined; blockHash?: `0x${string}` | undefined; fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } | undefined) => Promise>; Initiated: (args?: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } | undefined, options?: { strict?: boolean | undefined; blockHash?: `0x${string}` | undefined; fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } | undefined) => Promise>; Redeemed: (args?: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; } | undefined, options?: { strict?: boolean | undefined; blockHash?: `0x${string}` | undefined; fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } | undefined) => Promise>; Refunded: (args?: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; } | undefined, options?: { strict?: boolean | undefined; blockHash?: `0x${string}` | undefined; fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } | undefined) => Promise>; }; watchEvent: { EIP712DomainChanged: (options: { batch?: boolean | undefined; pollingInterval?: number | undefined; strict?: boolean | undefined; fromBlock?: bigint | undefined; onError?: ((error: Error) => void) | undefined; onLogs: import('viem').WatchContractEventOnLogsFn; poll?: true | undefined; }) => import('viem').WatchContractEventReturnType; Initiated: (args: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; }, options: { batch?: boolean | undefined; pollingInterval?: number | undefined; strict?: boolean | undefined; fromBlock?: bigint | undefined; onError?: ((error: Error) => void) | undefined; onLogs: import('viem').WatchContractEventOnLogsFn; poll?: true | undefined; }) => import('viem').WatchContractEventReturnType; Redeemed: (args: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; secretHash?: `0x${string}` | `0x${string}`[] | null | undefined; }, options: { batch?: boolean | undefined; pollingInterval?: number | undefined; strict?: boolean | undefined; fromBlock?: bigint | undefined; onError?: ((error: Error) => void) | undefined; onLogs: import('viem').WatchContractEventOnLogsFn; poll?: true | undefined; }) => import('viem').WatchContractEventReturnType; Refunded: (args: { orderID?: `0x${string}` | `0x${string}`[] | null | undefined; }, options: { batch?: boolean | undefined; pollingInterval?: number | undefined; strict?: boolean | undefined; fromBlock?: bigint | undefined; onError?: ((error: Error) => void) | undefined; onLogs: import('viem').WatchContractEventOnLogsFn; poll?: true | undefined; }) => import('viem').WatchContractEventReturnType; }; write: { initiate: , "address" | "abi" | "args" | "functionName"> extends infer T_3 ? { [K in keyof T_3]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K]; } : never>(args: readonly [`0x${string}`, bigint, bigint, `0x${string}`], options: options) => Promise<`0x${string}`>; initiateWithSignature: , "address" | "abi" | "args" | "functionName"> extends infer T_4 ? { [K_1 in keyof T_4]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_1]; } : never>(args: readonly [`0x${string}`, bigint, bigint, `0x${string}`, `0x${string}`], options: options_1) => Promise<`0x${string}`>; instantRefund: , "address" | "abi" | "args" | "functionName"> extends infer T_5 ? { [K_2 in keyof T_5]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_2]; } : never>(args: readonly [`0x${string}`, `0x${string}`], options: options_2) => Promise<`0x${string}`>; multicall: , "address" | "abi" | "args" | "functionName"> extends infer T_6 ? { [K_3 in keyof T_6]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_3]; } : never>(args: readonly [readonly { redeemer: `0x${string}`; expiry: bigint; amount: bigint; secretHash: `0x${string}`; signature: `0x${string}`; }[], readonly { orderID: `0x${string}`; secret: `0x${string}`; }[], readonly { orderID: `0x${string}`; }[]], options: options_3) => Promise<`0x${string}`>; redeem: , "address" | "abi" | "args" | "functionName"> extends infer T_7 ? { [K_4 in keyof T_7]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_4]; } : never>(args: readonly [`0x${string}`, `0x${string}`], options: options_4) => Promise<`0x${string}`>; refund: , "address" | "abi" | "args" | "functionName"> extends infer T_8 ? { [K_5 in keyof T_8]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_5]; } : never>(args: readonly [`0x${string}`], options: options_5) => Promise<`0x${string}`>; }; address: `0x${string}`; abi: readonly [{ readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "token_"; readonly type: "address"; }, { readonly internalType: "string"; readonly name: "name"; readonly type: "string"; }, { readonly internalType: "string"; readonly name: "version"; readonly type: "string"; }]; readonly stateMutability: "nonpayable"; readonly type: "constructor"; }, { readonly inputs: readonly []; readonly name: "InvalidShortString"; readonly type: "error"; }, { readonly inputs: readonly [{ readonly internalType: "string"; readonly name: "str"; readonly type: "string"; }]; readonly name: "StringTooLong"; readonly type: "error"; }, { readonly anonymous: false; readonly inputs: readonly []; readonly name: "EIP712DomainChanged"; readonly type: "event"; }, { readonly anonymous: false; readonly inputs: readonly [{ readonly indexed: true; readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }, { readonly indexed: true; readonly internalType: "bytes32"; readonly name: "secretHash"; readonly type: "bytes32"; }, { readonly indexed: false; readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }]; readonly name: "Initiated"; readonly type: "event"; }, { readonly anonymous: false; readonly inputs: readonly [{ readonly indexed: true; readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }, { readonly indexed: true; readonly internalType: "bytes32"; readonly name: "secretHash"; readonly type: "bytes32"; }, { readonly indexed: false; readonly internalType: "bytes"; readonly name: "secret"; readonly type: "bytes"; }]; readonly name: "Redeemed"; readonly type: "event"; }, { readonly anonymous: false; readonly inputs: readonly [{ readonly indexed: true; readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }]; readonly name: "Refunded"; readonly type: "event"; }, { readonly inputs: readonly []; readonly name: "eip712Domain"; readonly outputs: readonly [{ readonly internalType: "bytes1"; readonly name: "fields"; readonly type: "bytes1"; }, { readonly internalType: "string"; readonly name: "name"; readonly type: "string"; }, { readonly internalType: "string"; readonly name: "version"; readonly type: "string"; }, { readonly internalType: "uint256"; readonly name: "chainId"; readonly type: "uint256"; }, { readonly internalType: "address"; readonly name: "verifyingContract"; readonly type: "address"; }, { readonly internalType: "bytes32"; readonly name: "salt"; readonly type: "bytes32"; }, { readonly internalType: "uint256[]"; readonly name: "extensions"; readonly type: "uint256[]"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "redeemer"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "timelock"; readonly type: "uint256"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }, { readonly internalType: "bytes32"; readonly name: "secretHash"; readonly type: "bytes32"; }]; readonly name: "initiate"; readonly outputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "redeemer"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "timelock"; readonly type: "uint256"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }, { readonly internalType: "bytes32"; readonly name: "secretHash"; readonly type: "bytes32"; }, { readonly internalType: "bytes"; readonly name: "signature"; readonly type: "bytes"; }]; readonly name: "initiateWithSignature"; readonly outputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }, { readonly internalType: "bytes"; readonly name: "signature"; readonly type: "bytes"; }]; readonly name: "instantRefund"; readonly outputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly components: readonly [{ readonly internalType: "address"; readonly name: "redeemer"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "expiry"; readonly type: "uint256"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }, { readonly internalType: "bytes32"; readonly name: "secretHash"; readonly type: "bytes32"; }, { readonly internalType: "bytes"; readonly name: "signature"; readonly type: "bytes"; }]; readonly internalType: "struct HTLC.InitWithSig[]"; readonly name: "inits"; readonly type: "tuple[]"; }, { readonly components: readonly [{ readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }, { readonly internalType: "bytes"; readonly name: "secret"; readonly type: "bytes"; }]; readonly internalType: "struct HTLC.Redeem[]"; readonly name: "redeems"; readonly type: "tuple[]"; }, { readonly components: readonly [{ readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }]; readonly internalType: "struct HTLC.Refund[]"; readonly name: "refunds"; readonly type: "tuple[]"; }]; readonly name: "multicall"; readonly outputs: readonly [{ readonly internalType: "bool[]"; readonly name: "results"; readonly type: "bool[]"; }]; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "bytes32"; readonly name: ""; readonly type: "bytes32"; }]; readonly name: "orders"; readonly outputs: readonly [{ readonly internalType: "bool"; readonly name: "isFulfilled"; readonly type: "bool"; }, { readonly internalType: "address"; readonly name: "initiator"; readonly type: "address"; }, { readonly internalType: "address"; readonly name: "redeemer"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "initiatedAt"; readonly type: "uint256"; }, { readonly internalType: "uint256"; readonly name: "timelock"; readonly type: "uint256"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }, { readonly internalType: "bytes"; readonly name: "secret"; readonly type: "bytes"; }]; readonly name: "redeem"; readonly outputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "bytes32"; readonly name: "orderID"; readonly type: "bytes32"; }]; readonly name: "refund"; readonly outputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly []; readonly name: "token"; readonly outputs: readonly [{ readonly internalType: "contract IERC20"; readonly name: ""; readonly type: "address"; }]; readonly stateMutability: "view"; readonly type: "function"; }]; }>; getERC20Contract(): Promise<{ read: { symbol: (options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; name: (options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; allowance: (args: readonly [`0x${string}`, `0x${string}`], options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; balanceOf: (args: readonly [`0x${string}`], options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; decimals: (options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; totalSupply: (options?: import('viem').Prettify, "address" | "abi" | "args" | "functionName">> | undefined) => Promise; }; estimateGas: { approve: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; decreaseAllowance: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; increaseAllowance: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; mint: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; selfMint: (args: readonly [bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; transfer: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; transferFrom: (args: readonly [`0x${string}`, `0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; } & { approve: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; decreaseAllowance: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; increaseAllowance: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; mint: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; selfMint: (args: readonly [bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; transfer: (args: readonly [`0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; transferFrom: (args: readonly [`0x${string}`, `0x${string}`, bigint], options: import('viem').Prettify, "address" | "abi" | "args" | "functionName">>) => Promise; }; simulate: { approve: (args: readonly [`0x${string}`, bigint], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; decreaseAllowance: (args: readonly [`0x${string}`, bigint], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; increaseAllowance: (args: readonly [`0x${string}`, bigint], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; mint: (args: readonly [`0x${string}`, bigint], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; selfMint: (args: readonly [bigint], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; transfer: (args: readonly [`0x${string}`, bigint], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; transferFrom: (args: readonly [`0x${string}`, `0x${string}`, bigint], options?: Omit, "address" | "abi" | "args" | "functionName"> | undefined) => Promise>; }; createEventFilter: { Approval: (args: { owner?: `0x${string}` | `0x${string}`[] | null | undefined; spender?: `0x${string}` | `0x${string}`[] | null | undefined; } | ({ owner?: `0x${string}` | `0x${string}`[] | null | undefined; spender?: `0x${string}` | `0x${string}`[] | null | undefined; } extends infer T ? T extends { owner?: `0x${string}` | `0x${string}`[] | null | undefined; spender?: `0x${string}` | `0x${string}`[] | null | undefined; } ? T extends args ? Readonly : never : never : never), options?: ({ fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } & { strict?: strict | undefined; }) | undefined) => Promise>; Transfer: (args: { from?: `0x${string}` | `0x${string}`[] | null | undefined; to?: `0x${string}` | `0x${string}`[] | null | undefined; } | ({ from?: `0x${string}` | `0x${string}`[] | null | undefined; to?: `0x${string}` | `0x${string}`[] | null | undefined; } extends infer T_1 ? T_1 extends { from?: `0x${string}` | `0x${string}`[] | null | undefined; to?: `0x${string}` | `0x${string}`[] | null | undefined; } ? T_1 extends args_1 ? Readonly : never : never : never), options?: ({ fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } & { strict?: strict_1 | undefined; }) | undefined) => Promise>; }; getEvents: { Approval: (args?: { owner?: `0x${string}` | `0x${string}`[] | null | undefined; spender?: `0x${string}` | `0x${string}`[] | null | undefined; } | undefined, options?: { strict?: boolean | undefined; blockHash?: `0x${string}` | undefined; fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } | undefined) => Promise>; Transfer: (args?: { from?: `0x${string}` | `0x${string}`[] | null | undefined; to?: `0x${string}` | `0x${string}`[] | null | undefined; } | undefined, options?: { strict?: boolean | undefined; blockHash?: `0x${string}` | undefined; fromBlock?: bigint | import('viem').BlockTag | undefined; toBlock?: bigint | import('viem').BlockTag | undefined; } | undefined) => Promise>; }; watchEvent: { Approval: (args: { owner?: `0x${string}` | `0x${string}`[] | null | undefined; spender?: `0x${string}` | `0x${string}`[] | null | undefined; }, options: { batch?: boolean | undefined; pollingInterval?: number | undefined; strict?: boolean | undefined; fromBlock?: bigint | undefined; onError?: ((error: Error) => void) | undefined; onLogs: import('viem').WatchContractEventOnLogsFn; poll?: true | undefined; }) => import('viem').WatchContractEventReturnType; Transfer: (args: { from?: `0x${string}` | `0x${string}`[] | null | undefined; to?: `0x${string}` | `0x${string}`[] | null | undefined; }, options: { batch?: boolean | undefined; pollingInterval?: number | undefined; strict?: boolean | undefined; fromBlock?: bigint | undefined; onError?: ((error: Error) => void) | undefined; onLogs: import('viem').WatchContractEventOnLogsFn; poll?: true | undefined; }) => import('viem').WatchContractEventReturnType; }; write: { approve: , "address" | "abi" | "args" | "functionName"> extends infer T_2 ? { [K in keyof T_2]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K]; } : never>(args: readonly [`0x${string}`, bigint], options: options) => Promise<`0x${string}`>; decreaseAllowance: , "address" | "abi" | "args" | "functionName"> extends infer T_3 ? { [K_1 in keyof T_3]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_1]; } : never>(args: readonly [`0x${string}`, bigint], options: options_1) => Promise<`0x${string}`>; increaseAllowance: , "address" | "abi" | "args" | "functionName"> extends infer T_4 ? { [K_2 in keyof T_4]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_2]; } : never>(args: readonly [`0x${string}`, bigint], options: options_2) => Promise<`0x${string}`>; mint: , "address" | "abi" | "args" | "functionName"> extends infer T_5 ? { [K_3 in keyof T_5]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_3]; } : never>(args: readonly [`0x${string}`, bigint], options: options_3) => Promise<`0x${string}`>; selfMint: , "address" | "abi" | "args" | "functionName"> extends infer T_6 ? { [K_4 in keyof T_6]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_4]; } : never>(args: readonly [bigint], options: options_4) => Promise<`0x${string}`>; transfer: , "address" | "abi" | "args" | "functionName"> extends infer T_7 ? { [K_5 in keyof T_7]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_5]; } : never>(args: readonly [`0x${string}`, bigint], options: options_5) => Promise<`0x${string}`>; transferFrom: , "address" | "abi" | "args" | "functionName"> extends infer T_8 ? { [K_6 in keyof T_8]: import('viem').UnionOmit, "address" | "abi" | "args" | "functionName">[K_6]; } : never>(args: readonly [`0x${string}`, `0x${string}`, bigint], options: options_6) => Promise<`0x${string}`>; }; address: `0x${string}`; abi: readonly [{ readonly inputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "constructor"; }, { readonly anonymous: false; readonly inputs: readonly [{ readonly indexed: true; readonly internalType: "address"; readonly name: "owner"; readonly type: "address"; }, { readonly indexed: true; readonly internalType: "address"; readonly name: "spender"; readonly type: "address"; }, { readonly indexed: false; readonly internalType: "uint256"; readonly name: "value"; readonly type: "uint256"; }]; readonly name: "Approval"; readonly type: "event"; }, { readonly anonymous: false; readonly inputs: readonly [{ readonly indexed: true; readonly internalType: "address"; readonly name: "from"; readonly type: "address"; }, { readonly indexed: true; readonly internalType: "address"; readonly name: "to"; readonly type: "address"; }, { readonly indexed: false; readonly internalType: "uint256"; readonly name: "value"; readonly type: "uint256"; }]; readonly name: "Transfer"; readonly type: "event"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "owner"; readonly type: "address"; }, { readonly internalType: "address"; readonly name: "spender"; readonly type: "address"; }]; readonly name: "allowance"; readonly outputs: readonly [{ readonly internalType: "uint256"; readonly name: ""; readonly type: "uint256"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "spender"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }]; readonly name: "approve"; readonly outputs: readonly [{ readonly internalType: "bool"; readonly name: ""; readonly type: "bool"; }]; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "account"; readonly type: "address"; }]; readonly name: "balanceOf"; readonly outputs: readonly [{ readonly internalType: "uint256"; readonly name: ""; readonly type: "uint256"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly []; readonly name: "decimals"; readonly outputs: readonly [{ readonly internalType: "uint8"; readonly name: ""; readonly type: "uint8"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "spender"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "subtractedValue"; readonly type: "uint256"; }]; readonly name: "decreaseAllowance"; readonly outputs: readonly [{ readonly internalType: "bool"; readonly name: ""; readonly type: "bool"; }]; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "spender"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "addedValue"; readonly type: "uint256"; }]; readonly name: "increaseAllowance"; readonly outputs: readonly [{ readonly internalType: "bool"; readonly name: ""; readonly type: "bool"; }]; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "to"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }]; readonly name: "mint"; readonly outputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly []; readonly name: "name"; readonly outputs: readonly [{ readonly internalType: "string"; readonly name: ""; readonly type: "string"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }]; readonly name: "selfMint"; readonly outputs: readonly []; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly []; readonly name: "symbol"; readonly outputs: readonly [{ readonly internalType: "string"; readonly name: ""; readonly type: "string"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly []; readonly name: "totalSupply"; readonly outputs: readonly [{ readonly internalType: "uint256"; readonly name: ""; readonly type: "uint256"; }]; readonly stateMutability: "view"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "to"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }]; readonly name: "transfer"; readonly outputs: readonly [{ readonly internalType: "bool"; readonly name: ""; readonly type: "bool"; }]; readonly stateMutability: "nonpayable"; readonly type: "function"; }, { readonly inputs: readonly [{ readonly internalType: "address"; readonly name: "from"; readonly type: "address"; }, { readonly internalType: "address"; readonly name: "to"; readonly type: "address"; }, { readonly internalType: "uint256"; readonly name: "amount"; readonly type: "uint256"; }]; readonly name: "transferFrom"; readonly outputs: readonly [{ readonly internalType: "bool"; readonly name: ""; readonly type: "bool"; }]; readonly stateMutability: "nonpayable"; readonly type: "function"; }]; }>; /** * The atomic swap contract address associated with the passed chain * * @returns {string} The contract address */ id(): string; /** * Initiates the HTLC * * @returns {Promise} Transaction ID */ init(): Promise; /** * Redeems the HTLC * * @returns {Promise} Transaction ID */ redeem(secret: string): Promise; private getOrderId; /** * Refunds the HTLC * * @returns {Promise} Transaction ID */ refund(): Promise; } export interface JWTFromSIWE { getToken(): Promise; } export type InitWithSigRequest = { redeemer: string; timelock: number; amount: string; };