Issue and verify SMART Health Cards and SMART Health Links for patient credential sharing

domain: hl7.org · 6 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

In-depth guide

FHIR Bulk Data $export gotchas — the full failure-mode walkthrough related to hl7.org, checked against official docs, with linked verified routes.

Steps

  1. To issue a SMART Health Card: package the patient's FHIR data (e.g., immunization Bundle) as a minimized FHIR Bundle (no server URLs, no narrative), compress it with DEFLATE, then sign it as a JWS compact serialization using an ES256 (ECDSA P-256) private key; the resulting JWS string is the SMART Health Card
  2. Publish the issuer's public key at a JWKS endpoint at <issuer>/.well-known/jwks.json; the kid in the JWS header must match a key in the JWKS; verifiers will fetch this endpoint to validate signatures
  3. To distribute as a file, wrap the JWS string(s) in a JSON object with a 'verifiableCredential' array and save as a .smart-health-card file (MIME type: application/smart-health-card); for QR distribution, split the JWS into chunks and encode each as a numeric QR code
  4. To issue a SMART Health Link (SHL): generate a random encryption key, encrypt the payload (FHIR Bundle or .smart-health-card file) with AES-256-GCM, store it at a manifest URL, then encode the SHL URL as shlink:/<base64url-payload> for sharing via QR or hyperlink
  5. To verify a SMART Health Card: decode the JWS, fetch the issuer's JWKS, validate the ES256 signature, check the 'exp' claim if present, and parse the vc.credentialSubject.fhirBundle to extract the clinical data
  6. For SMART Health Links verification: parse the SHL URL to extract the manifest URL and decryption key, GET the manifest with the SHL-recipient header, then decrypt and decompress each payload file to obtain the FHIR data

Known gotchas

Related routes

Build a SMART Health Links (SHL) sharing flow that packages a patient's immunization record as a FHIR Bundle, encrypts it, and generates a shareable SHL URL for offline or cross-organization sharing
hl7.org/fhir/smart-app-launch · 6 steps · unrated
Implement IHE PMIR (Patient Master Identity Registry) Mobile Patient Identity Feed to publish patient identity create/update/merge events using FHIR
healthcare · 6 steps · unrated

Give your agent this knowledge — and 15,600+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans