Expand description
Authority attestation — the general domain model of which a “government letter” is one preset.
A GovernmentLetter (see welfare_support.rs) is only the narrow special case where the
authorizing body happens to be a government. The general concept is an authority
attestation: some authority (a government, but equally a pathology company, a university,
a bank, an NGO) attests something about a subject, optionally through an agent-in-capacity
(the natural person or software agent acting for that authority in a stated role), and delivers
it in one of several orthogonal representations (a PDF, a verifiable credential, or a PDF with
an embedded credential).
The authority type is a URI-ish string id, NOT a closed enum — "authority:government" is just
a well-known upper-level constant. Downstream owners coin their own type ids freely
("authority:pathology:acme-labs", etc.) without touching this file.
Like the other WellFair Restricted records, the attestation body lives out-of-band as a blob
(blob_hash) — the PDF / credential bytes live in the content-addressed blob store, and this
struct is the indexable envelope over them, flagging whether the owner must act.
Re-exports§
pub use authority_type::EDUCATION;pub use authority_type::FINANCIAL;pub use authority_type::GOVERNMENT;pub use authority_type::NGO;pub use authority_type::PATHOLOGY;
Modules§
- authority_
type - Well-known upper-level authority type ids.
Structs§
- Agent
InCapacity - A natural person (or software agent) acting FOR the authority in a stated capacity/role — e.g. a pathologist signing off a result, a case officer issuing a determination.
- Authority
- The authorizing body behind an attestation.
- Authority
Attestation - An attestation issued by an authority (through an optional agent-in-capacity) about a subject.
Enums§
- Representation
- How an attestation is delivered — ORTHOGONAL to its content.
Functions§
- authority_
attestation_ record_ id - record ID.
- authority_
attestation_ summary - A compact JSON projection of an attestation for journal display.
- build_
authority_ attestation_ envelope - Build the Restricted envelope for an authority attestation.
- government_
letter - The “government letter” specialization: an
AuthorityAttestationwhose authority is a government (authority_type::GOVERNMENT), labelled fromsender, delivered as aPdf. - parse_
authority_ attestation_ summary - Parse a compact projection produced by
authority_attestation_summaryback into a value.