/** * Signer / Wallet Management * Resolves a wallet from CLI flags or environment variables. */ import { ethers } from 'ethers'; export interface SignerContext { signer: ethers.Wallet; provider: ethers.providers.JsonRpcProvider; address: string; chainId: number; } /** * Create a connected signer for the target chain. * Priority: --private-key flag > POP_PRIVATE_KEY env > error */ export declare function createSigner(opts: { privateKey?: string; chainId?: number; rpcUrl?: string; }): SignerContext; /** * Create a read-only provider (no signer needed). */ export declare function createProvider(opts: { chainId?: number; rpcUrl?: string; }): ethers.providers.JsonRpcProvider; /** * The address this invocation OBSERVES AS, for identity-scoped reads * (vote list --unvoted, task list --mine, user profile, vouch status, …). * * Precedence: --address > POP_ADDRESS > derived from the private key. * * Identity-scoped reads must never REQUIRE a signing key: "show me what I * haven't voted on" is the most useful integrator query, and gating it on * POP_PRIVATE_KEY is what pushes integrations into handing a signing key to a * process that only needs to read. Key derivation is the fallback so existing * signer-configured setups keep working unchanged. */ export declare function resolveIdentityAddress(argv: { address?: string; privateKey?: string; 'private-key'?: string; } | any, opts?: { required?: boolean; purpose?: string; }): string | null;