uncefact / spec-untp

UN Transparency Protocol
https://uncefact.github.io/spec-untp/
GNU General Public License v3.0
10 stars 9 forks source link

Align data models to the VC Data Model #91

Open nissimsan opened 1 month ago

nissimsan commented 1 month ago

This issue stems from https://github.com/uncefact/spec-untp/pull/90

Several of our examples are based on an approach of essentially recreating the VC Data Model (which defines issuer, validFrom, etc..), with the intent to wrap that all into the credentialSubject of a VC. That will produce a quite inelegant data graph with a lot of duplication and potential for inconsistencies (issuer vs issuedBy, validFrom vs validFrom...).

Rather, we want to leverage the VCDM. For example issuer, should be added within a complex object instead of repeating it within the credentialSubject. For example:

... "issuer": { "@type": [ "Organization" ], "@id": "did:web:nis.example.com", "taxIdentificationNumnber": "DK-12345678", "name": "Nis Global Unltd.", "street": "Ocean Lane 100", "locality": "Paradise Island", "country": "DK" }, "credentialSubject": { "type": [ "ConformityStuff" ], "aClaim": "conforming", "anotherClaim": "legit", ...

JohnOnGH commented 1 month ago

I think it would be useful to have some form of highlighting of where the spec we define follows the the standard W3C VC DM, and where we are adding something we need for UNTP.

PatStLouis commented 1 month ago

Let's bundle addressing issue #42 with this.

PatStLouis commented 2 weeks ago

@nissimsan along the same line of thinking of migrating the issuedBy field to the issuer value of the vc, could we make the issuedTo the credentialSubject? and add a property called hasAttestation?