/** * `agentsmarket call ` — invoke a skill. * * Payment is handled server-side: server checks buyer's USDC balance on-chain * before allowing the call. Client signs an EIP-2612 Permit (preferred over * EIP-3009 because USDC on Base mainnet requires msg.sender == to for * receiveWithAuthorization, blocking operator relay). * * Flags: * --payment-tx-hash Real tx hash from MetaMask/Trust Wallet. * --inputs Pass as JSON string, e.g. '{"key":"value"}' * --no-auto-sign Skip automatic Permit signing on 402 * (default: load identity and auto-sign). * * On 402 with mode 'eip2612_permit_variant_d', CLI auto-loads * ~/.agentsmarket/identity, signs one EIP-2612 Permit (owner=buyer, spender=operator, * value=total), computes shared_link, retries. */ export interface CallOptions { skillId: string; paymentTxHash: string | null; inputsJson: string | null; noAutoSign?: boolean; } export declare function parseInputs(inputsJson: string | null): Record; interface IdentityShape { private_key: string; agent_id: string; } /** * Resolve the signing key through the same config lookup as `loadConfig()`. * * This hardcoded `~/.config/agentsmarket/agent.key`, ignoring XDG_CONFIG_HOME, * so a client could AUTHENTICATE as one agent while SIGNING with whatever key * lived in the default location. The server rejected those permits as * INVALID_LINK (fail-closed, no money moved) — which is exactly how it * surfaced: every purchase from a non-default profile failed while the default * profile worked. */ export declare function loadIdentityPath(): string; /** * One key, one address, from one place. * * This used to read `agent.key` itself and only consult the environment in * treasury mode, so `AGENTSMARKET_PRIVATE_KEY` signed the EIP-191 request but * left the permit unsigned — the server saw a 402 and the CLI answered * "no local identity to sign the permit with" while holding a perfectly good * key in the environment. `loadPrivateKeyHex()` already resolves treasury → * buyer → file; reading the key here and the address anywhere else is the * drift that once produced INVALID_LINK. * * A missing file is a normal state (a CI job that passed no key at all), so * it is a null return rather than a throw. */ export declare function tryLoadIdentity(): IdentityShape | null; export declare function callCommand(opts: CallOptions): Promise; export {};