Verifying Multiple VCs
The VC Playground supports the delivery of
QueryByExample
requests for doing Multi-Credential Verification as a
Verifiable Credential Verifier.
Wallet Sign Up
If you already have a CHAPI-enabled digital wallet (Veres Wallet, LearnCard, etc.), you can skip to the VC Issuance section.
Here's how to get a demo Veres Wallet if you need one:
-
Visit https://demo.vereswallet.dev/ and click "Try Veres Wallet".
-
Use an email address that you can access. The Veres Wallet supports email address tags, so you can modify a valid email address by adding "+chapi" to create multiple accounts: myname+chapi@example.com The "+chapi" can be anything you like and you can use this approach to make multiple accounts at a single email address.
-
Once you click "Register", you'll receive an "Allow Wallet" modal. Make sure to click "Allow" on that modal, so the wallet can handle credentials on your behalf.
Once that's done, proceed to Verifiable Credential Issuance.
Verifiable Credential Issuance
First, visit the Issuer section of the playground.
Next, select the "JFF x vc-edu PF3" icon in the top "Select a credential to issue" section.
The credential JSON below is similar to what will be passed to the issuer to generate the credential.
Example Credential JSON prior to its being issued
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
"https://purl.imsglobal.org/spec/ob/v3p0/context.json"
],
"id": "urn:uuid:63c8140b-1b77-4c39-babc-825e4cfd69ba",
"type": [
"VerifiableCredential",
"OpenBadgeCredential"
],
"name": "JFF x vc-edu PlugFest 3 Interoperability",
"issuer": {
"type": ["Profile"],
"id": "did:key:z6MktiSzqF9kqwdU8VkdBKx56EYzXfpgnNPUAGznpicNiWfn",
"name": "Jobs for the Future (JFF)",
"url": "https://www.jff.org/",
"image": "https://w3c-ccg.github.io/vc-ed/plugfest-1-2022/images/JFF_LogoLockup.png"
},
"issuanceDate": "2023-07-20T07:05:44Z",
"credentialSubject": {
"type": ["AchievementSubject"],
"id": "did:key:123",
"achievement": {
"id": "urn:uuid:ac254bd5-8fad-4bb1-9d29-efd938536926",
"type": ["Achievement"],
"name": "JFF x vc-edu PlugFest 3 Interoperability",
"description": "This wallet supports the use of W3C Verifiable Credentials and has demonstrated interoperability during the presentation request workflow during JFF x VC-EDU PlugFest 3.",
"criteria": {
"type": "Criteria",
"narrative": "Wallet solutions providers earned this badge by demonstrating interoperability during the presentation request workflow. This includes successfully receiving a presentation request, allowing the holder to select at least two types of verifiable credentials to create a verifiable presentation, returning the presentation to the requestor, and passing verification of the presentation and the included credentials."
},
"image": {
"id":"https://w3c-ccg.github.io/vc-ed/plugfest-3-2023/images/JFF-VC-EDU-PLUGFEST3-badge-image.png",
"type": "Image"
}
}
}
}
Now, lets issue the credential. Click "Issue Verifiable Credential" to proceed to the (optional) DID Authentication screen.
Once you've completed DID Authentication (or not), you'll be provided with the Verifiable Credential JSON.
Example Generated / Issued Verifiable Credential
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
"https://purl.imsglobal.org/spec/ob/v3p0/context.json",
"https://w3id.org/security/suites/ed25519-2020/v1"
],
"id": "urn:uuid:63c8140b-1b77-4c39-babc-825e4cfd69ba",
"type": [
"VerifiableCredential",
"OpenBadgeCredential"
],
"name": "JFF x vc-edu PlugFest 3 Interoperability",
"issuer": {
"type": [
"Profile"
],
"id": "did:key:z6MkuxAHYLWVb4FyKvmxyT4egQeoYbNJrwNAVcg4TUkwxk86",
"name": "Jobs for the Future (JFF)",
"url": "https://www.jff.org/",
"image": "https://w3c-ccg.github.io/vc-ed/plugfest-1-2022/images/JFF_LogoLockup.png"
},
"issuanceDate": "2023-08-15T20:37:11.170Z",
"credentialSubject": {
"type": [
"AchievementSubject"
],
"id": "did:key:123",
"achievement": {
"id": "urn:uuid:ac254bd5-8fad-4bb1-9d29-efd938536926",
"type": [
"Achievement"
],
"name": "JFF x vc-edu PlugFest 3 Interoperability",
"description": "This wallet supports the use of W3C Verifiable Credentials and has demonstrated interoperability during the presentation request workflow during JFF x VC-EDU PlugFest 3.",
"criteria": {
"type": "Criteria",
"narrative": "Wallet solutions providers earned this badge by demonstrating interoperability during the presentation request workflow. This includes successfully receiving a presentation request, allowing the holder to select at least two types of verifiable credentials to create a verifiable presentation, returning the presentation to the requestor, and passing verification of the presentation and the included credentials."
},
"image": {
"id": "https://w3c-ccg.github.io/vc-ed/plugfest-3-2023/images/JFF-VC-EDU-PLUGFEST3-badge-image.png",
"type": "Image"
}
}
},
"proof": {
"type": "Ed25519Signature2020",
"created": "2023-08-15T20:37:11Z",
"verificationMethod": "did:key:z6MkuxAHYLWVb4FyKvmxyT4egQeoYbNJrwNAVcg4TUkwxk86#z6MkuxAHYLWVb4FyKvmxyT4egQeoYbNJrwNAVcg4TUkwxk86",
"proofPurpose": "assertionMethod",
"proofValue": "z3Z3MYDpgcMWgoFovdLKc7qmLWCm3qLARn9FBNX6XBhajXipb6XWH9zksNHVrg8YE61PiygQ9brKEWpdHyNhx8obD"
}
}
```
NOTE: The credential JSON document now has an absolute URL for it's id
value and a new proof
section. The issuer.id
has also been updated to reflect the playground as the Issuer, and (of course) the issuanceDate
has also been set.
That credential may now be stored in a wallet. Click "Store in Wallet" to proceed.
A modal will appear - similar to the one below - explaining that the playground wants to send the credential for you.
Clicking "Next" should present you with a list of available wallets:
However, if you instead receive a browser window popup warning you that you do not yet have one set up, you will need to return to the Wallet Sign Up section above.
If you received a list of wallet options, pick the one you prefer by clicking on it's name to proceed.
Each wallet will have it's own system for displaying the credential and offering to store it for you.
Once you've clicked "Store" in your preferred wallet system, you will be brought back to the main playground screen.
Follow the above process a few more times by clicking "Issuer Demo" to load your wallet with more example credentials.
Multiple Verifiable Credential Verification
Now that you have several Verifiable Credentials (VCs) in your wallet, let's get them all verified in one request.
First, visit the playground's Verifier section.
Select the VCs you loaded into your wallet (i.e. "Alumni", "JFF x vc-edu PF3", and "Permanent Resident").
Next, click "Request Verifiable Presentation" to request that your wallet share these credentials with the Playground's Verifier.
The Wallet should display each of the credentials it found based on your selection. It may also provide the ability to select specific ones to be verified. The demo Veres Wallet presents the credential selection as follows:
Click the "Share" button to send some or all of them to the playground for verification.
Once shared, the process should end with a VerifiablePresentation
JSON document shown and the words "Presentation Verified".
Example Verifiable Presentation
Note that if you pick a credential that you didn't first load into your demo wallet, you'll receive a "Sorry, we can't seem to find any credentials" message. Additionally, you may find a different credential presented if it contains the requested data needed for verification.
Checkout the QueryByExample
documentation for examples of how a Verifier may request Wallets to respond with matching credentials.