Skip to main content

Module linktype

Module linktype 

Source
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

Structs§

LinkDescriptor
Describes one available representation of a DPP resource.
ResolutionRequest
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.
DppMediaType
Media types relevant to DPP content negotiation.
Gs1LinkType
GS1 defined link types for Digital Link resolution.

Functions§

negotiate
Negotiate the best link descriptor for a given request.