An independent witness for a live deal: each party sends the hash of every event as it happens and gets a signed receipt with the time and its place in the chain
witness_recordWitness a deal event. Send deal_id, party_id, event_type, content_hash (SHA-256 hex of the content, never the content), your Ed25519 public_key and your sig (base64 signature over the canonical JSON of {content_hash, deal_id, event_type, party_id, type:'witness-event', v:1}). Get back a receipt signed by Witness: the time we saw it, its place (seq) in the deal's chain, and the chain hash over the previous receipt. It shows only that this hash was sent by this key and seen at this time, in this order. It does not show the content is true, who the party is, or that nothing else was sent. Stores hashes, types, public keys, signatures and times for 400 days after the deal's last event; never content or addresses. Free.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"deal_id": "<deal_id>",
"party_id": "<party_id>",
"event_type": "<event_type>",
"content_hash": "<content_hash>",
"public_key": "<public_key>",
"sig": "<sig>"
},
"name": "witness_record"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sig | Yes | base64 Ed25519 signature over the canonical JSON of the event (see description). | |
| deal_id | Yes | Opaque id both parties use for the deal. Use a random one (16+ characters); anyone who knows it can add events to the chain. | |
| party_id | Yes | Opaque id of the sender. Its key is fixed by its first event in the deal. | |
| event_type | Yes | Lowercase label such as offer, accept, payment, delivery, confirm. | |
| public_key | Yes | Ed25519 public key, 32 bytes, base64. | |
| content_hash | Yes | SHA-256 of the event content, lowercase hex. |