Protocol coverage
The AlgoVoi gateway issues a compliance receipt on every incoming payment request across all four payment protocols:| Protocol | Trigger | Receipt on |
|---|---|---|
| x402 | POST /checkout/{token} | Every admission screen |
| MPP | POST /mpp/{resource_id} | Every admission screen |
| AP2 | POST /ap2/initiate | Every admission screen |
| A2A | POST /a2a/v1/tasks | Every admission screen |
draft-hopley-x402-compliance-receipt (POSTED on IETF datatracker 2026-05-23, Independent Submission, Informational), and implemented as part of the substrate reference package:
- TypeScript:
@algovoi/substrate—buildComplianceReceipt()(live, v0.3.0) - Python:
algovoi-substrate—build_compliance_receipt()(live, v0.3.0)
Lifecycle position
content_hash linkage.
Receipt shape
A compliance receipt is a six-field JSON object canonicalised under RFC 8785 (JCS). Field names are sorted lexicographically by JCS during canonicalisation.| Field | Type | Description |
|---|---|---|
canon_version | string | In-band canonicalisation pin. Fixed jcs-rfc8785-v1. |
jurisdiction_flags | ordered array | ISO-3166-1 codes. Order significant under RFC 8785. |
payer_ref | string | sha256:{hex} content-addressed reference to the payer identity record. SHA-256(network:address). |
screen_provider_did | string | DID URI of the screening party. Resolves without operator runtime access. |
screen_result | string (closed enum) | ALLOW / REFER / DENY. |
screen_timestamp_ms | integer | Epoch milliseconds. Substrate Rule 2 — MUST be integer, not float string. |
The closed enumeration: screen_result
| Value | Semantic | Regulatory significance |
|---|---|---|
ALLOW | Payer passed all screening checks. Payment may proceed. | No SAR obligation triggered. Baseline positive record in the audit chain. |
REFER | Payer matched a watchlist or risk threshold. Requires manual review before proceeding. | Triggers SAR obligation under Proceeds of Crime Act 2002 s.330 (UK) / AMLR Article 56 (EU). Payment held pending review outcome. |
DENY | Payer matched sanctions list or failed mandatory check. Payment blocked. | Triggers tipping-off compliance under SAMLA 2018 s.20 — reason for denial MUST NOT be disclosed to the payer. |
content_hash under JCS. Probability scores, risk tiers, or intermediate states are not acceptable substitutes in the canonical receipt record.
payer_ref construction
payer_ref is a content-addressed reference to the payer identity — not the payer’s raw address. The preimage is {chain_network}:{wallet_address}, hashed with SHA-256:
Why this format
The compliance receipt exists to create an independently verifiable admission-time record:- Under AMLD6 / AMLR Article 56, operators must retain records of every transaction screening decision with enough detail to reconstruct the decision at audit time.
- Under SAMLA 2018 s.20 (UK), the reason for a
DENYmust not be disclosed to the payer. The receipt records the categorical outcome; the screening detail stays in the operator’s internal records. - Under PSD2 Article 74 (Directive 2015/2366), transaction monitoring records must be available to competent authorities. A
content_hash-chained receipt that a third party can verify without operator runtime access satisfies this without exposing operator internals.
DENY receipt is not missing data, it is a byte-distinct verifiable artefact.
Audit chain linkage
Every compliance receipt is appended to the SHA-256 JCS hash-chained audit ledger:Conformance vectors
8 byte-level reference vectors + 5 pair invariants + 3 chain invariants atvectors/compliance_receipt_v1/.
Reproduce the full 8-implementation cross-validation:
Quick start
TypeScript
Python
What this is NOT
- Not a risk score. The receipt records a categorical admission decision, not a continuous risk signal. Upstream risk models emit scores; the receipt records the policy outcome of applying those scores.
- Not a KYC certificate. The receipt records that a compliance screen was performed and its outcome. Full KYC documentation is held in the operator’s internal records, not in the canonical receipt.
- Not a payment confirmation. The compliance receipt records admission. Settlement is recorded separately in the settlement attestation.
Companion IETF Internet-Draft
draft-hopley-x402-compliance-receipt (Independent Submission, Informational). AlgoVoi-authored, sole authorship. Normatively references draft-hopley-x402-canonicalisation-jcs-v1.
See also
- Canonicalisation substrate — the JCS discipline
- Settlement attestation — post-admission counterpart
- Refund receipt — post-settlement counterpart
- Payment Evidence Frame — wraps all receipt types into one verifiable artefact
- Conformance vectors — full vector corpus
- Substrate authorship and provenance — citable AlgoVoi authorship record