Expand description
GS1 Digital Link link-type negotiation.
When a resolver receives a Digital Link request, the client can specify which representation it wants via:
- Query parameter:
?linkType=gs1:epil(product information page) - HTTP Accept header:
application/json,application/ld+json, etc.
The ESPR mandates that DPP data is resolvable through GS1 Digital Link. Different consumers need different representations:
- A consumer scanning a QR code wants an HTML product page.
- A machine client wants JSON-LD or raw DPP JSON.
- A market surveillance authority wants the full signed DPP payload.
§Module layout
vocabulary—Gs1LinkType, the GS1 Web Vocabulary link types.media_type—DppMediaTypefor content negotiation.request—ResolutionRequest+ HTTPAccept-header parsing.negotiate—LinkDescriptor+ the negotiation algorithm.
Structs§
- Link
Descriptor - Describes one available representation of a DPP resource.
- Resolution
Request - A parsed resolution request combining the Digital Link with negotiation hints.
Enums§
- Audience
- Re-export the canonical access vocabulary from dpp-domain. Who is asking for passport data.
- Disclosure
- Re-export the canonical access vocabulary from dpp-domain.
How restricted a field is — the counterpart to
Audience. - DppMedia
Type - Media types relevant to DPP content negotiation.
- Gs1Link
Type - GS1 defined link types for Digital Link resolution.
Functions§
- negotiate
- Negotiate the best link descriptor for a given request.