Create Verifiable Accreditation
Issue Verifiable Accreditations as DID-Linked Resources
Users are able to issue Verifiable Accreditations as DID-Linked Resources on-ledger, which may be used to verify whether a particular recipient of an accreditation is accredited to issue a certain type of credential, under the scope of a particular governance framework. This implementation on cheqd builds on the principles of the EBSI Trust Chain model, using DID-Linked Resources to create a more standardised format for storing, retrieving and dereferencing to trust registry entries.
Step 1: Set up your account
Make sure you have set up your account with cheqd Studio and are logged in, using our guide below:
Step 2: Create a DID
Before you can create a Verifiable Accreditation, you need to create a DID which is used to link to one or multiple Verifiable Accreditations on-ledger. Use the API in the page below to create a DID:
Step 3: Create your Verifiable Accreditation body and save the file locally
Verifiable Accreditations are JSON objects that take the form of the Verifiable Credential data model. There are two types of Verifiable Accreditation:
For a trusted ecosystem, these attestations are required to trace the legitimacy of a credential issuer to a root-of-trust.
Save this file locally and call it something like verifiableAccreditation.json
Note that each SON file must be below ~45kb in size.
Step 4: Encode the file
Prepare a file with resource and encode it into base64, base64url
or hex
. On Unix systems, you can use the following command input:
Expected output:
Step 5: Set the resource name and type
DID-Linked Resources are grouped by having identical names and types. This means if you want to create a new version of the same Resource, you will need to specify the same name and type in the following request.
For Verifiable Accreditations, the "type" MUST be either: "VerifiableAccreditationToAccredit"
or "VerifiableAccreditationToAttest"
For example:
Step 6: Populate the request inputs and hit the API
Ensure that you link this Verifiable Accreditation to the DID that you created in step 3. This will sign the resource with the same verification method keys in your DID Document, ensuring cryptographic integrity and Controllership of the Status List.
As a DID-Linked Resource, the Verifiable Accreditation will have a fully resolvable DID URL which can be referenced within the body of Verifiable Credentials, and queried by verification policies to establish the status of the specific credential.
Step 7: Reference the Verifiable Accreditation
Owing to the design of DID-Linked Resources, following the creation of the a Verifiable Accreditation, users are able to reference the specific version, or create a query to always fetch the latest version of the Accreditation.
Using a DID Resolver or the search DID endpoint, users can find the DID URL and unique resourceId of the Verifiable Accreditation. The unique resourceId allows users to specify this exact version of the Accreditation.
In the DID Document Metadata, users should find "linkedResourceMetadata", like the following snippet:
Specific version of the Verifiable Accreditation
Here, the "resourceURI
" specifies the DID URL of the specific Verifiable Accreditation that was created.
Latest version of the Verifiable Accreditation
In order to reference the latest version of the Verifiable Accreditation, the following construction needs to be used:
did:cheqd:<namespace>:<resourceCollectionId>?resourceName=<resourceName>&resourceType=<resourceType>
For example:
did:cheqd:testnet:0a5b94d0-a417-48ed-a6f5-4abc9e95888d?resourceName=OxfordUniversityAccreditation&resourceType=VerifiableAccreditationToAccredit
Verifiable Accreditation at specific point in time
In order to reference the Verifiable Accreditation at a particular point in time, the following construction needs to be used:
did:cheqd:<namespace>:<resourceCollectionId>?resourceName=<resourceName>&resourceType=<resourceType>&resourceVerionTime=<XMLDateTime>
For example:
did:cheqd:testnet:0a5b94d0-a417-48ed-a6f5-4abc9e95888d?resourceName=OxfordUniversityAccreditation&resourceType=VerifiableAccreditationToAccredit&resourceVersionTime=2023-02-22T06:58:18.61Z
Last updated