Skip to content
Protocol contracts not yet configured for this build
Enter app

Developers

Contract ABIs

Every ABI used by the interface and the scripts lives in one generated module, lib-ts/abi.ts. Nothing is hand-written except where a contract is unverified on chain.

Regenerating

bash
forge build && node scripts/gen-abis.mjs

That script does two things:

  1. Reads the Foundry artifacts in out/ for the five Plouto contracts.
  2. Fetches the Pons ABIs live from Blockscout, so they cannot drift from what is deployed.

Provenance

ABISource
ploutoRegistryAbiFoundry artifact
ploutoRevenueRouterAbiFoundry artifact
gravityStakingAbiFoundry artifact
buybackExecutorAbiFoundry artifact
ploutoReserveAbiFoundry artifact
ponsFactoryAbiBlockscout, verified source
ponsFeeEscrowAbiBlockscout, verified source
ponsLaunchDeployerAbiBlockscout, verified source
ponsCurveAbiRecovered from deployed bytecode — see below
erc20AbiMinimal hand-written subset

The curve ABI

Per-launch Pons curves are deployed as unverified instances. There is no verified source to fetch.

The ABI was therefore recovered by extracting the dispatcher selectors from deployed bytecode and resolving them against the public 4-byte database. The one function Plouto actually calls was confirmed directly:

text
buy(uint256,uint256,address) = 0x59a87bc1   ← present in deployed curve bytecode

scripts/prepare-pons-launch.ts re-checks that selector against a live curve before any launch, and refuses to continue if it is absent.

Solidity interfaces

The on-chain side keeps its own transcriptions in src/interfaces/:

  • IPonsV2.sol — factory, escrow, curve, launch deployer, plus the PonsLaunchedToken and PonsLaunchConfig structs.
  • IUniswapV4.sol — the minimal PoolManager surface, PoolKey, SwapParams and IUnlockCallback.
  • IPlouto.sol — the small internal interfaces the contracts use to call each other.

These are transcribed from verified ABIs, not invented. The file header records the provenance for each.

Type safety

lib-ts/abi.ts exports every ABI as const, so viem and wagmi infer argument and return types from the ABI itself. A typo in a function name is a compile error rather than a runtime revert.