SPEC.md §§ 4, 6).
Lifecycle Guarantees
- 60-Second Hold TTL: When
POST /v1/paymentsauthorizes a challenge,amountmoves fromW_AVAILtoW_HELDand incrementsspent_today/spent_month. If the token is not redeemed within 60 seconds, the hold expires and bothW_AVAILand the policy spend counters are restored. - Automatic 5xx Refund: If a seller’s downstream handler throws an exception or returns
HTTP >= 500after redeeming a token,@haggles/serverautomatically callsPOST /v1/payments/:id/refundin the background. - 24-Hour Full Refund Window: Captured payments can be refunded in full within 24 hours (
S_PENDINGnet +G_FEES5% fee are both reversed back to the buyer’sW_AVAIL).