Skip to content

Instantly share code, notes, and snippets.

@alexdunae
Last active Sep 21, 2021
Embed
What would you like to do?

BC COVID-19 Vaccine Passport

BC's COVID-19 vaccine passport is encoded as a JSON web token following the SMART Health Card open spec.

I made a little write up about how to decode the data.

Vax codes

You can inspect the http://snomed.info/sct coding key to see which type of vaccines were recorded:

  • 28581000087106 – PFIZER-BIONTECH COVID-19 messenger ribonucleic acid 30 micrograms per 0.3 milliliter suspension for dilution for injection Pfizer Canada ULC-BioNTech Manufacturing GmbH (real clinical drug)
  • 28571000087109 – MODERNA COVID-19 messenger ribonucleic acid-1273 100 micrograms per 0.5 milliliter liquid for injection Moderna Therapeutics Inc. (real clinical drug)
  • 28531000087107 – Vaccine product against disease caused by Severe acute respiratory syndrome coronavirus 2 (medicinal product)
  • 1119349007 – Vaccine product containing only Severe acute respiratory syndrome coronavirus 2 messenger ribonucleic acid (medicinal product)
{
"header": {
"alg": "ES256",
"zip": "DEF",
"kid": "XCqxdhhS7SWlPqihaUXovM_FjU65WeoBFGc_ppent0Q"
},
"payload": {
"iss": "https://smarthealthcard.phsa.ca/v1/issuer",
"nbf": 1630885634,
"vc": {
"type": [
"https://smarthealth.cards#covid19",
"https://smarthealth.cards#immunization",
"https://smarthealth.cards#health-card"
],
"credentialSubject": {
"fhirVersion": "4.0.1",
"fhirBundle": {
"resourceType": "Bundle",
"type": "collection",
"entry": [
{
"fullUrl": "resource:0",
"resource": {
"resourceType": "Patient",
"name": [
{
"family": "LASTNAME",
"given": [
"FIRSTNAME"
]
}
],
"birthDate": "1980-01-01"
}
},
{
"fullUrl": "resource:1",
"resource": {
"resourceType": "Immunization",
"status": "completed",
"vaccineCode": {
"coding": [
{
"system": "http://hl7.org/fhir/sid/cvx",
"code": "208"
},
{
"system": "http://snomed.info/sct",
"code": "28581000087106"
}
]
},
"patient": {
"reference": "resource:0"
},
"occurrenceDateTime": "2021-05-21",
"lotNumber": "EW0199",
"performer": [
{
"actor": {
"display": "Drop-in Vaccine Clinic"
}
}
]
}
},
{
"fullUrl": "resource:2",
"resource": {
"resourceType": "Immunization",
"status": "completed",
"vaccineCode": {
"coding": [
{
"system": "http://hl7.org/fhir/sid/cvx",
"code": "208"
},
{
"system": "http://snomed.info/sct",
"code": "28581000087106"
}
]
},
"patient": {
"reference": "resource:0"
},
"occurrenceDateTime": "2021-07-25",
"lotNumber": "FD7206",
"performer": [
{
"actor": {
"display": "UBC Vax Van"
}
}
]
}
}
]
}
}
}
},
"verifications": {
"trustable": true,
"verifiedBy": "XCqxdhhS7SWlPqihaUXovM_FjU65WeoBFGc_ppent0Q",
"origin": "https://smarthealthcard.phsa.ca/v1/issuer"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment