@etherspot/remote-signer
Version:
Etherspot Permissioned Signer SDK - signs the UserOp with SessionKey and sends it to the Bundler
61 lines (58 loc) • 2.49 kB
TypeScript
import { U as UserOperation } from '../ERC4337Utils-DFwtlIAE.js';
import { Gas } from './common/getGasFee.js';
import { Account, PublicClient } from 'viem';
import { BigNumberish, BigNumber } from './types/bignumber.js';
import { SessionKeyOnChainData } from './types/session-key-types.js';
import { UserOpsRequest, BatchUserOpsRequest } from './common/interfaces.js';
import { SdkOptions, PaymasterApi } from './interfaces.js';
import { HttpRpcClient } from './base/HttpRpcClient.js';
import { TransactionGasInfoForUserOp } from './base/TransactionDetailsForUserOp.js';
import { EtherspotWalletAPI } from './base/EtherspotWalletAPI.js';
import './types/common-types.js';
import 'node_modules/viem/_types/errors/utils';
import './bundler/interface.js';
import './base/BaseAccountAPI.js';
import '../PaymasterAPI-kjTxpLRH.js';
import './base/calcPreVerificationGas.js';
import './dto/sign-message.dto.js';
declare class RemoteSignerSdk {
externalViemAccount: Account;
etherspotWalletAddress: string;
chainId: number;
index: number;
apiKey: string;
sessionKey: string;
factoryUsed: string;
providerUrl: string;
publicClient: PublicClient;
etherspotWallet: EtherspotWalletAPI;
bundler: HttpRpcClient;
erc20SessionKeyValidator: string;
private userOpsBatch;
private constructor();
private initialize;
private getERC20SessionKeyValidator;
static create(externalViemAccount: Account, sdkOptions: SdkOptions): Promise<RemoteSignerSdk>;
getPublicClient(): PublicClient;
getProviderUrl(): string;
validateSessionKey(): Promise<boolean>;
isSessionKeyLiveOnChain(): Promise<boolean>;
getSessionKeyOnChainData(): Promise<SessionKeyOnChainData>;
signUserOp(userOp: UserOperation): Promise<UserOperation>;
getCounterFactualAddress(): Promise<string>;
estimate(params?: {
paymasterDetails?: PaymasterApi;
gasDetails?: TransactionGasInfoForUserOp;
callGasLimit?: BigNumberish;
nonceKey?: BigNumber;
}): Promise<any>;
send(signedUserOp: any): Promise<string>;
getGasFee(): Promise<Gas>;
getNativeBalance(): Promise<string>;
getUserOpReceipt(userOpHash: string): Promise<string>;
getUserOpHash(userOp: UserOperation): Promise<string>;
addUserOpsToBatch(tx: UserOpsRequest): Promise<BatchUserOpsRequest>;
clearUserOpsFromBatch(): Promise<void>;
totalGasEstimated(userOp: UserOperation): Promise<BigNumber>;
}
export { RemoteSignerSdk };