Urgent.News

What's breaking now, across thousands of outlets.

Tech

"The fourth most expensive x402 mistake: paying without a spending policy"

The wallet is empty. Nothing failed: no reverts, no timeouts, no stuck transactions. Every payment was authorized, every signature was valid, every recipient was legitimate. Your agent just spent ten dollars in increments of ten cents and never once asked whether it should stop. The fourth most expensive x402 mistake is paying without a spending policy. The first three mistakes were about single…

Paying without a spending policy is the fourth most costly mistake in the x402 system. The first three mistakes involved individual payment errors, such as signing twice for one intent or treating verification as settlement. This mistake, however, involves multiple authorized payments that add up to a bill nobody authorized. Two main traps contribute to this issue: the aggregate trap and the automated retry storm.

The aggregate trap occurs when a per-call cap is set, like $0.10, but it only limits the size of each payment, not the total number of payments. This allows an agent to make a hundred $0.10 calls, spending $10 in total, despite each call being under the cap. The automated retry storm happens when a request fails after payment or the result never comes back, causing the agent to retry blindly, leading to double payments.

Both traps highlight the protocol-level gap in x402, which only settles payments without managing money, leaving budgeting, approval, and escalation to your code. To prevent this mistake, set a maximum total spend per task or run, require human or policy approval above a per-payment amount, record every payment in a payment ledger, and implement a kill switch with a global spend limit per wallet per time window.

Additionally, set up alerting at 50% and 80% of the budget. Finally, use Veyline's economic governor to compile natural-language spending policies into machine-enforced constraints through a mandate, ensuring every paid step is authorized against them.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

My git changelog showed every pull request twice — a commit range isn't a change list

Last release cycle I generated notes for our own service the naive way: git log v0.9.0..v0.10.0 , format the subjects, done. The output listed 12 commits. We had merged 6 pull requests.

  • Git log command generated 12 commit subjects during release cycle
  • Merge PRs appeared twice due to merge-commit repository behavior
  • First-parent-with-boundaries logic implemented in Git Changelog Generator

"The second most expensive x402 mistake: treating verify as settlement"

/verify returned isValid: true . So you did the work. Then /settle answered {"errorReason":"invalid_payload"} and a 400 that explains nothing.

  • Treat "verify" as settlement, leading to costly mistakes
  • Verify examines authorization, settle transfers funds
  • Gap between verify and settle can cause double-spending

More from Wednesday 7 October →