Skip to content

Draft: Updates DFR to use new Jargon strategy to keep Facility as credentialSubject

Follows !559 (closed) , this PR has the updates of Jargon for the Digital Facility Record switching to the credentialSubject having the id of the actual subject (the Facility).

The actual Jargon changes to generate this was:

  • Update FacilityRecord.facility from being an embedded property to instead aggregate all untp.Facility properties
  • sets FacilityRecord's own @id to untp:Facility so that it masquerades as the Facility (with extra relationships).

This allows us to have a separate object defined in Jargon, FacilityRecord which has all the fields of Facility as well as some extra relationships (conformityClaim etc.) (benefits of a schema and sample data), while the expanded JSON-LD just sees an Facility with extra relations/predicates, as is right for JSON-LD.

Tested this DFR for valid jsonld and schema with https://github.com/absoludity/jargon-untp-tester

Ref #540

I'm leaving this as draft until the preceding !559 (closed) lands, as I'll then need to rebase this and update the target branch to main.

Merge request reports

Loading