import { AbstractEthersV5Signer } from '@nktkas/hyperliquid/signing'; import { ethers } from 'ethers'; /** * LitActionPkpEthersWallet - An ethers-compatible wallet implementation for use within Lit Actions * * This class provides an ethers.js Signer-compatible interface that uses Lit's PKP signing * capabilities within a Lit Action execution environment. Unlike PKPEthersWallet which is * designed to run outside Lit Actions and uses the Lit SDK to make signing requests, * this wallet runs INSIDE a Lit Action and directly calls Lit.Actions.signAndCombineEcdsa. * * Key differences from PKPEthersWallet: * - No provider/RPC logic (runs in Lit Action sandbox) * - Direct use of Lit.Actions.signAndCombineEcdsa instead of SDK methods * - Simplified constructor (just takes PKP public key) * - No transaction population (gas estimation, nonce, etc.) * * Supports: * - signMessage: Sign arbitrary messages (EIP-191) * - _signTypedData: Sign EIP-712 typed data * - signTransaction: Sign raw Ethereum transactions * * @example * ```typescript * const wallet = new LitActionPkpEthersWallet({ * pkpPublicKey: '0x04...', * sigName: 'my-signature' * }); * * // Sign a message * const signature = await wallet.signMessage('Hello World'); * * // Sign typed data (EIP-712) * const typedSignature = await wallet._signTypedData(domain, types, value); * * // Sign a transaction * const signedTx = await wallet.signTransaction(transaction); * ``` */ export declare class LitActionPkpEthersWallet implements AbstractEthersV5Signer { private readonly pkpPublicKey; private readonly sigName; readonly address: string; constructor(pkpPublicKey: string, sigName?: string); /** * Sign a message using EIP-191 personal_sign format */ signMessage(message: string | Uint8Array): Promise; /** * Get the wallet address (required by AbstractEthersV5Signer) */ getAddress(): Promise; /** * Sign typed data using EIP-712 (required by AbstractEthersV5Signer) * Note: Ethers v5 uses _signTypedData (with underscore) */ _signTypedData(domain: { name: string; version: string; chainId: number; verifyingContract: string; }, types: { [key: string]: { name: string; type: string; }[]; }, value: Record): Promise; /** * Sign a transaction * Note: Transaction must be pre-populated with all fields (gasLimit, nonce, chainId, etc.) * as we don't have RPC access in Lit Actions */ signTransaction(transaction: ethers.providers.TransactionRequest): Promise; } //# sourceMappingURL=lit-action-pkp-ethers-wallet.d.ts.map