/** * pop treasury claim — claim your allocation from a merkle distribution. * * Human units: --amount is a DECIMAL amount in the distribution's payout * token by default. The payout token (and its decimals) comes from the indexed * Distribution entity — the same source the sibling `pop treasury claim-mine` * already uses, so the two commands cannot disagree about one value — with * PaymentManager.getDistribution retained as the fallback for a distribution * the subgraph has not indexed yet. address(0) means the chain's native token * (verified against contracts origin/main src/PaymentManager.sol), otherwise * a live ERC20 decimals() read. Pass --wei to supply the exact raw integer * instead (the merkle leaf hashes the raw amount, so exactness matters when * your allocation has full-precision dust). * * Pre-flight (skippable with --no-preflight) mirrors the contract's revert * gates: DistributionNotFound, DistributionAlreadyFinalized and AlreadyClaimed * (hasClaimed) fail fast before gas is spent. Opt-out BLOCKS with a * PreconditionError: the DEPLOYED PaymentManager still reverts OptedOut in * claimDistribution (audit L-19 removes that gate only in a not-yet-deployed * version), so claiming while opted out would just burn gas. * * Prefer `pop treasury claim-mine` — it recomputes the tree and derives your * amount + proof automatically. This command is the manual escape hatch. */ import type { Argv, ArgumentsCamelCase } from 'yargs'; import { ethers } from 'ethers'; interface ClaimArgs { org?: string; distribution: number; amount: string; proof?: string; 'proof-file'?: string; wei?: boolean; chain?: number; rpc?: string; 'private-key'?: string; 'dry-run'?: boolean; yes?: boolean; preflight?: boolean; } /** Parse --proof (inline JSON) or --proof-file (JSON array, or object with a `proof` field). */ export declare function parseProof(proof?: string, proofFile?: string): string[]; /** Convert --amount to the raw claim value: decimal token units, or raw wei with --wei. */ export declare function parseClaimAmount(amount: string, wei: boolean, decimals: number): ethers.BigNumber; export declare const claimHandler: { builder: (yargs: Argv) => Argv<{ distribution: number; } & { amount: string; } & { proof: string | undefined; } & { "proof-file": string | undefined; } & { wei: boolean; }>; handler: (argv: ArgumentsCamelCase) => Promise; }; export {};