vc-examples
vc-examples copied to clipboard
Add an Open Badges Example
https://www.imsglobal.org/activity/digital-badges
Please include all the necessary items needed for someone to implement a new Open Badges based Verifiable Credential Data Model compliant VC / VP.
I'll start on this. Some notes:
- Updated from Open Badges are Verifiable Credentials
- I just reused the issuer and proof from Orie's UniversityDegreeCredential example for now
- I need to double-check the context and terms
- I snipped the redundant issuer from Open Badges are Verifiable Credentials that we had for backcompat
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
"https://w3id.org/openbadges/v2"
],
"id": "https://example.com/assertions/1001",
"type": [
"Credential?",
"Assertion?"
],
"issuer": {
"id": "did:web:vc.transmute.world"
},
"issuanceDate": "2020-03-10T04:24:12.164Z",
"credentialSubject": {
"id": "https://example.com/profiles/bob",
"obi:holds": {
"id": "https://example.com/badgeclasses/123",
"type": "BadgeClass",
"name": "Certificate of Accomplishment",
"image": "data:image/png;base64,...",
"description": "A badge describing great accomplishments",
"criteria": {
"narrative": "Perform tasks of valor and wit."
}
}
},
"obi:evidence": {
"id": "https://example.org/portfolios/25",
"name": "Bob's Portfolio",
"narrative": "Bob worked hard to develop a good portfolio",
"genre": "ePortfolio"
},
"proof": {
"type": "JsonWebSignature2020",
"created": "2020-03-21T17:51:48Z",
"verificationMethod": "did:web:vc.transmute.world#_Qq0UL2Fq651Q0Fjd6TvnYE-faHiOpRlPVQcY_-tA4A",
"proofPurpose": "assertionMethod",
"jws": "eyJiNjQiOmZhbHNlLCJjcml0IjpbImI2NCJdLCJhbGciOiJFZERTQSJ9..OPxskX37SK0FhmYygDk-S4csY_gNhCUgSOAaXFXDTZx86CmI5nU9xkqtLWg-f4cqkigKDdMVdtIqWAvaYx2JBA"
}
}
fyi @ottonomy