import type { Account, Chain, Hex, PublicClient, Transport, WalletClient } from 'viem'; import type { SignAuthorizationReturnType } from 'viem/accounts'; import type { Delegation7702Registry } from '../types'; type ResolveAuthorizationParams = { /** Pre-signed authorization; when provided it is returned as-is. */ authorization?: SignAuthorizationReturnType; /** When true and no authorization is provided, sign one if delegation is inactive. */ autoDelegate: boolean; walletAddress: Hex; }; type ResolveAuthorizationDeps = { chainId: number; delegationRegistry: Delegation7702Registry; publicClient: PublicClient; walletClient: WalletClient; }; /** * Resolves which EIP-7702 authorization (if any) to attach to a sponsored * transaction. * * - If the caller pre-signed an authorization, it is returned as-is. * - If `autoDelegate` is false, no authorization is attached. * - Otherwise, queries the on-chain delegation state. If delegation is * already active, no authorization is needed; if not, signs one. */ export declare const resolveAuthorization: ({ authorization, autoDelegate, walletAddress }: ResolveAuthorizationParams, deps: ResolveAuthorizationDeps) => Promise; export {};