MPP modes

MPP has two payment modes and one entry point each. They share no state, so which one you call is decided by how the target bills, not by anything in this library.

Charge mode

FunctionChecksCost
runMppChargeSuite({ target, network, payerSecretKey, rpcUrl? })MPP-01Settles a real payment every call

Channel mode

FunctionChecksCost
runMppChannelSuite({ target, commitmentSecretHex, network, rpcUrl?, channelOverride?, expected?, allowDestructive?, destructiveChannel? })MPP-10–12, 14 free; MPP-13 when allowDestructive is setMPP-13 permanently closes the channel

expected is Partial<{ token, from, to, refundWaitingPeriod }> — MPP-10's on-chain parameter assertions. channelOverride asserts which channel to inspect; the target's own 402 challenge is authoritative, so a mismatch fails MPP-10 rather than silently inspecting two contracts.