Break it
Attack an agent that uses PayPal's Agent Toolkit. See who pays.
Pick an attack and press Run. On the left is the unguarded agent, read from the recorded run. On the right is the same episode with a guard in front of the tool, and a signed receipt your browser verifies with Ed25519 and SHA-256.
Loading the recorded episodes.
Choose an attack
All 80 attack episodes of the run
The attack episodes are 20 each of lost response, injected instruction, over limit request and duplicate delivery. The unguarded numbers are read from the recorded run. The guarded numbers are the same episodes run through the guard on the local PayPal layer. Every attack here is a planted failure.
Use it in three lines
pip install git+https://github.com/Sriharsan/clearwake-paypal
from clearwake import guard
tools = guard(paypal_toolkit_tools, policy="policy.yaml")
Clearwake adds what the toolkit leaves to you: limits, one request id per money move, a read of PayPal's record before any retry, and a signed receipt.
paypal_toolkit_tools is the tool list your agent framework got from PayPal's toolkit. guard() hands back a list of the same length and order. Of the toolkit's 47 tools, 8 move money and come back wrapped. The other 39 are the same objects, untouched. A wrapped call reads PayPal's record, takes the amount from it and from the signed policy, refuses what is above the limit before any request leaves, gives the move one request id, and writes a signed receipt. It covers what the toolkit failure page records, and Clearwake built it as an independent guard. Setup on the Developers page, or read the guard's page.
Or as an MCP server, for Claude Code or Claude Desktop
claude mcp add paypal-guarded -- python -m clearwake.mcp_server
After the pip install above, your agent sees the same 28 PayPal tools. The money tools run through the same guard as the episodes above; the read tools pass through. Claude Desktop config and the sandbox backend are on the developers page.