Try Prune with any app in about 2 minutes. Prune vaults your provider key, caps spend, cuts your bill through caching and compression, and returns a signed receipt on every call.
This repo is one script and one README — no framework, no coding-agent setup. The script makes 15 calls (5 short prompts, repeated over 3 rounds) through Prune's OpenRouter proxy, so you actually see caching kick in on the repeats instead of just one opaque call-and-response.
- Join the waitlist at withprune.com and get access — you'll need a Prune account before you can create a Prune API key or vault a provider.
- Get a free API key at openrouter.ai (no payment method required for the free-tier models).
- Vault that key in the Prune dashboard under Connect → Providers. This step is not optional — Prune won't have a provider key to call on your behalf otherwise, even though the model itself is free.
- Copy
.env.exampleto.envand add your Prune key:cp .env.example .env - Install dependencies:
pip install prune-sdk python-dotenv - Run it:
python test_prune.py
You'll see one line per call — round, cache status, tokens saved, and the
reply — then a summary. Round 1 is 5 cache misses; rounds 2 and 3 repeat
the same 5 prompts, so you should see cache=exact and a nonzero
tokens_saved on most of those. The full receipt fields for the last call
(client.last_prune_metadata) print at the end. Verify any receipt at
withprune.com/verify.
Note on the dollar figure: the demo model is priced at $0 on
OpenRouter, so cost_saved_usd reads $0.00 here — there's no cost to
save on a free model. tokens_saved and the cache hits are the real
signal in this demo. Point Prune at a paid model to see dollar savings.
The script waits 2 seconds between calls to stay under OpenRouter's free-tier limits (20 requests/minute, 50/day), so a run leaves you plenty of quota to try it again.
test_prune.py uses openai/gpt-oss-20b:free, a currently-free model on
OpenRouter, so there's nothing to pay to try this. To call a paid model
instead, vault your real OpenRouter key the same way in step 3 and change
MODEL to any model id OpenRouter supports.
Text me if you hit any issues: 8291006285
Apache-2.0 — see LICENSE.