Soma Check — Conditional Payment
Savings Dashboard
Every API call with If-None-Match against unchanged data pays 10% instead of 100%.
Providers keep the 90% cache-hit share. Agents poll 10× more for less.
Auto-refreshes every 10s
Total Calls
--
across all endpoints
Actual Hit Rate
--
served with 304
Projected Hit Rate
--
if all clients sent hashes
Credits Saved (actual)
--
real 304 responses
Credits Saved (projected)
--
shadow-mode estimate
Endpoints Tracked
--
with Soma Check traffic
Per-Endpoint Breakdown
| Endpoint | Calls | Actual Hits | Projected Hits | Saved (actual) | Saved (projected) |
|---|
How Soma Check Works
Step 1
First call
Agent calls the endpoint. Server returns data + an
ETag header holding a SHA-256 hash of the content.Step 2
Agent remembers the hash
On next poll the agent sends
If-None-Match: "sha256-..." with the cached hash.Step 3
Hit = 90% discount
If the hash still matches: server returns
304 Not Modified (no body) and bills 10% of origin price. If unchanged, no transfer.Try it — 2 curl calls
First call — get the ETag
# First call — returns 200 + ETag
curl -i https://api.claw-net.org/v1/soma/demo/fx?base=USD
Conditional call — 304 if unchanged
# Second call — pass the ETag back, get 304 if data unchanged curl -i https://api.claw-net.org/v1/soma/demo/fx?base=USD \ -H 'If-None-Match: "sha256-..."'