Functions
receiptHash
Function: receiptHash()
receiptHash(
runId,content):string
Defined in: src/lib/time-travel/receipt.ts:365
The receipt's hash: run-salted SHA-256, first RECEIPT_HASH_CHARS hex characters. Exported because it is half of the conformance law — a reader that rebuilds a served view proves the rebuild by hashing it the same way.
Parameters
runId
string
content
string
Returns
string
Example
import { receiptAt, receiptHash, servedAt } from 'agentfootprint';
const view = servedAt(agent.getSnapshot()!, 1)!;
const receipt = receiptAt(agent.getSnapshot()!, 1)!;
receiptHash(receipt.basis.runId, view.system.text) === receipt.system.hash; // true