The SDK logs a warning (not an error) when a paid tool is called without
memo. Read them back with GET /v1/analytics/receipts.
TypeScript SDK
memo is plain text. decisionContext is any JSON-serialisable object. Known fields are typed (see DecisionContext in the SDK types); extras are kept as-is.
Python SDK
decisionContext and decision_context. The SDK normalises to camelCase before sending.
Raw HTTP
Without an SDK, includememo and decisionContext in the JSON body of any paid tool call:
Validation
Bad audit values never block a call. The SDK validates lightly on the client before sending:memoover 1000 chars → truncated with a warning logmemoempty / non-string → dropped silentlydecisionContext.confidenceoutside[0, 1]→ dropped silentlydecisionContextnon-object → dropped silently
Where it shows up
Both fields are written to the receipt when it is created:GET /v1/analytics/receipts returns them with the other receipt attributes, with no extra request.
When to use which
- Memo only: quick debugging. Set a one-line reason (“why am I calling this?”) on every paid call. The SDK logs a warning if you forget.
- Memo + decisionContext: agents under programmatic oversight (supervisor agents, audit pipelines, eval rigs). A downstream system can reason about the structured context without parsing prose.
- Neither: acceptable for fire-and-forget scripts where receipts don’t matter. The SDK won’t block the call, but there is no audit trail.
Tag vs memo vs decisionContext
Each field records something different about the same receipt:
Together they link input to outcome, which RoCS is computed from.