verify_receipt
Verify cryptographic integrity of receipts to confirm consent proof authenticity for AI agents. Public verification without API keys.
Instructions
Verify a receipt's cryptographic integrity. Public — no API key needed.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| receipt_id | Yes | ||
| canonical_hash | Yes | ||
| signature | Yes | ||
| key_id | Yes |
Implementation Reference
- openterms_mcp_server.py:235-245 (handler)Handler for verify_receipt tool, which POSTs to /v1/receipts/verify.
elif name == "verify_receipt": resp = client.post("/v1/receipts/verify", json=arguments, headers=_headers(auth=False)) if resp.status_code == 200: v = resp.json() status = "✅ VALID" if v.get("valid") else "❌ INVALID" return ( f"{status}\n" f" hash_matches: {v.get('hash_matches')}\n" f" signature_valid: {v.get('signature_valid')}" ) return _format_error(resp) - openterms_mcp_server.py:44-57 (schema)Tool definition/schema for verify_receipt.
{ "name": "verify_receipt", "description": "Verify a receipt's cryptographic integrity. Public — no API key needed.", "inputSchema": { "type": "object", "required": ["receipt_id", "canonical_hash", "signature", "key_id"], "properties": { "receipt_id": {"type": "string"}, "canonical_hash": {"type": "string"}, "signature": {"type": "string"}, "key_id": {"type": "string"}, }, }, },