Create DID-Linked Resource
Create a DID-Linked Resource associated with a cheqd DID over REST API
Using the /resource/create
API, users are able to create custom DID-Linked Resources, including:
Schemas
Credential Definitions
Trust Registries
Status Lists
Logos associated with DIDs
Governance files
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 DID-Linked Resource, you need to create a "parent" DID which is used to link the Resource on-ledger. Use the API in the page below to create a DID:
Create an Issuer DID
Create a W3C conformant DID on cheqd using the did:cheqd
DID Method.
Learn more about DID-Linked Resources
Understand the context and technical composition of cheqd's DID-Linked Resources.
Step 3. Create your Resource content and save the file locally
DID-Linked Resources can be any type of file or content that is below ~45kb in size.
For the purpose of an example, lets use an AnonCreds schema (JSON file) as the resource:
Save this file locally and call it something like resource.json.
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 a consistent name and type
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.
Step 6: Populate the request inputs and hit the API
Last updated