DappSpendPolicy
Per-peer limits a wallet enforces on a dApp's transactions, checked before anything reaches the approver.
Every field is off by default, so a session with no policy behaves exactly as before: each transaction asks the human. The caps are hard: a request outside them is refused without asking the approver, which is what makes a policy a pre-commitment ("this dApp can never move more than X") and what stops an agent from farming approvals until reflex taps one through. The wallet's owner can always widen the policy in the app.
Amount limits are per instrument: dailyCap = 25 means at most 25 of each allowed instrument in any rolling 24h window, tracked from the SpendLedger's receipts. Only transactions the wallet can parse as a single token-standard transfer (DappCommandSummary.transferOf) count against the caps or qualify for auto-approval; anything unrecognised is never refused by amount and never auto-approved. It goes to the human, flagged, and the human is the gate.
autoApproveBelow is the one field that skips the approver: a parsed transfer at or under it (and inside every other limit) is approved without asking, and the receipt records that it was. Off by default; a wallet UI should treat enabling it as an explicit, per-peer opt-in.
Constructors
Properties
Instruments this peer may move. Null = any.
Receiving parties this peer may pay. Null = any.
Auto-approve parsed transfers at or below this amount, without asking the approver. Null = off: every transaction goes to the approver. Always bounded by the caps above.
Largest total per instrument in any rolling 24h window. Null = no cap.
Largest single transfer, per request. Null = no cap.
Minimum gap between transaction requests. ZERO = no rate limit.