For: Anthropic API users wanting audit-grade tool-use logs
Claude tool-use — receipts for every API call
-
1 Install the Anthropic adapter
Wraps `@anthropic-ai/sdk` to intercept every `tool_use` block.
pnpm add @sbo3l/anthropic -
2 Wrap your client
API surface unchanged — just hand the SBO3L-wrapped client to your existing code.
import Anthropic from "@anthropic-ai/sdk"; import { wrapAnthropic } from "@sbo3l/anthropic"; const raw = new Anthropic(); const claude = wrapAnthropic(raw, { sbo3lUrl: "http://localhost:8730", agentId: "research-01", }); const reply = await claude.messages.create({ model: "claude-sonnet-4-6", max_tokens: 1024, tools: [/* ... */], messages: [{ role: "user", content: "Send 100 USDC to 0xabc" }], }); -
3 What changed
Every `tool_use` block in the response now has an attached `_sbo3l_receipt` — signed, hash-chained, capsule-verifiable. Denials surface as a `tool_result` block with the deny code.