- Receiving any SPL stable (USDC, USDT, USDG) requires no signature —
standard SPL transfers land in the PDA’s per-mint ATA. Use
provisionTreasuryAtasfrom@leash/registry-utilsonce after mint to ensure faucets and wallets find an ATA for every supported stable. - Spending requires the asset owner (or a delegated executive) to sign an
Executeinstruction routed through MPL Core. For x402 calls the executive holds a per-mint capped SPL delegation on the treasury ATA; approving USDC does not approve USDG. SeeFund an agentfor the full delegation flow. - Withdrawing stables back to the owner (or any rescue wallet) is
an
Execute(SPL.TransferChecked); withdrawing native SOL (e.g. Genesis creator fees) is the same pattern withExecute(SystemProgram.Transfer)instead. Only the owner can authorise either, and the same PDA-via-CPI wrap works across classic SPL Token, Token-2022, and the System program. SeeWithdraw treasury funds. - Creator fees from the agent’s Genesis token (if you launched one
via
Launch an agent token) accrue directly to this PDA as native SOL. Drain them withwithdrawTreasurySol/withdrawTreasurySolAllfrom@leash/registry-utils(or one click in the playground’s withdraw card — pickSOL (native)from the currency dropdown).
@leash/core exposes deriveAgentTreasuryAddress,
deriveAgentTreasuryAta({ asset, mint }), listSplBalances, and
getTreasuryBalance; v0.1 demos use these to render the treasury readout
without a wallet.
