Fees
What this build charges, where each fee comes from, and how it is changed. Every real-money fee below is Release-gated. Live credit card keys refuse to boot, so the credit card rail runs in Stripe TEST mode only. A stablecoin mode is not refused in code: on a real-money chain the hosted image starts it only when the operator lists it in CORE_ALLOWED_MODES and the vault's owner and fee collector are Safe multisigs (threshold 2 or more).
| Rail | Fee | Where the rate comes from | Status |
|---|---|---|---|
| Stablecoin escrow, contract v1 | protocol fee: the vault's feeBps on each settlement, rounded down | set on chain by the vault owner, at most 1000 bps; the repository's deploy script defaults to 100 bps | Release-gated |
| Stablecoin escrow, contract v2 | protocol fee: the vault's feeBps when held value is released, rounded down | set on chain by the vault owner, at most 150 bps; each stream keeps the lower of the fee at its open and the current fee; the deploy script defaults to 0 bps | Release-gated |
| Credit card rail | platform fee (the credit card application fee) on settled minus refunded value, rounded down | the revenue switchboard: on at 50 bps unless the operator changes it; each budget keeps the rate it opened with | Release-gated (Stripe TEST only) |
| Control Mode | none | no money moves; there is no fee row | Live |
The core never sets the protocol fee: it reads the vault's fee and refuses to start if a vault charges something other than the fee the operator configured (or pinned at first boot). If a vault's fee changes later, new stablecoin opens are refused with protocol_fee_mismatch until the configuration matches. Processor charges on the credit card rail are not a Dynamo fee row; the revenue summary estimates them from a stated pricing table whose figures are marked to be confirmed. The switchboard's other channels (internal ledger fee, usage fee, enterprise entitlements) are off and cannot be switched on. For the routes and the switchboard, see the developer fee page.
Fee doctrine
- Every fee is its own ledger row, asset-denominated, tied to the
settlement that produced it: one row per vault fee event for the protocol fee, and the credit card rail's fee ledger for the platform fee. GET /owner/v1/fees lists them.
- The payer gets refunded value back in full. On the credit card rail a refund writes an
explicit fee-reversal row. On contract v2 the fee is taken only when held value is released after the holdback, so a refund inside the holdback returns value that has paid no fee. On contract v1 a refund after an attested break point is pulled back from the payee, including the fee portion. Where the engine's verified-settlement ledger nets a reversed fee against the payee, an unnettable residue is recorded as forgone fee (holdback and refunds), never a buyer charge.
- Failed actions carry no fee: fees are computed on settled value, and
units that never billed produce no settlement to fee.
The fee-model harness
The fee-model harness (packages/fee-model) checks a fee model against recorded session shapes from a committed fixture file, each with a source tag. For each session it computes the model's fee revenue (fee on settled value minus fee on refunded value, rounded down) and a rail-specific cost floor:
- Stablecoin rail: every on-chain operation the session recorded, at the
recorded gas per operation and a configured gas price.
- Credit card rail: the processor's spread that is not returned when
value is refunded (plus the fixed fee when a capture is refunded in full).
- Control Mode: no cost and no fee.
It exits non-zero unless every money-rail session's revenue exceeds its cost floor and every Control Mode session has neither. All arithmetic is integer micro-USD.
cd /Users/steve/dpv1-aug26 && pwd
make fee-report
The harness uses its own built-in model rates (100 bps stablecoin, 50 bps credit card, the hosted card application fee of record, ruling 135), not the switchboard or a vault, so it does not test the rate a deployment charges.