Product Docs
Product DocsTechnical DocsLearning & GovernanceUseful Links
  • Product Docs
  • Node Docs
  • Learning Docs
  • â„šī¸Getting Started
    • Product Overview
    • âžĄī¸Get Started with cheqd Studio
      • 👉Set Up Your Account
      • đŸ—ī¸Create API Keys
      • đŸĒ™Token Top Up
      • 🔄Advanced Configuration Options
    • â˜‘ī¸Use Trust Registries for AI Agents
      • đŸ—ī¸Build an AI Agent Trust Registry
        • Setup AI Agent Trust Registry
          • Issue Verifiable Credentials to AI Agent
        • Setup and Configure MCP Server
          • Create AI Agent DID
          • Import Credential to AI Agent
          • Advanced functionality
            • Issue a Verifiable Credential
            • Verify a Credential
      • 🤝Validate AI Agent Trust Chain
  • đŸŸĸStart using cheqd
    • 🆔Create DIDs and Identity Keys
      • Create a DID
      • Create Identity Keys
      • Create a Subject DID
      • Resolve a DID
      • Update a DID
      • Deactivate a DID
    • ✅Issue Credentials and Presentations
      • Issue a Credential
      • Setup Verida Wallet
      • Verify a Credential
      • Verify a Presentation
      • Revoke a Credential
      • Suspend or Unsuspend a Credential
    • â™ģī¸Charge for Verifiable Credentials
      • Understanding Credential Payments
        • Access Control Conditions
        • Privacy Considerations
      • Charge for Status List
      • Issue Credential with Encrypted Status List
      • Create Verifier Pays Issuer flow
      • Bulk Update or Rotate Encryption Keys
    • 🤝Build Trust Registries
      • Decentralized Trust Chains (DTCs)
        • Root Authorisations
        • RTAO -> TAO
        • TAO -> SubTAO
        • TAO -> Trusted Issuer (TI)
        • Referencing Trust Registry within a Verifiable Credential
      • Set up Trust Chain
        • Issue Verifiable Accreditation
        • Verify Verifiable Accreditation
      • Get Started with TRAIN
        • Deploy TRAIN and Anchor rTAO in DNS
        • Validate Trust Chain
    • 🎋Create Status Lists
      • Bitstring Status List
        • Create Bitstring Status List
        • Update Bitstring Status List
        • Check Bitstring Status List
        • Search Bitstring Status List
      • Token Status List
        • Create Token Status List
        • Update Token Status List
    • â†•ī¸Create DID-Linked Resources
      • Understanding DID-Linked Resources
        • Context for developing DID-Linked Resources
        • Technical composition of DID-Linked Resources
        • Referencing DID-Linked Resources in VCs
      • Create DID-Linked Resource
      • Search DID-Linked Resource
  • đŸ› ī¸Integrate an SDK
    • Choosing the right SDK
    • 🍏Credo
      • Setup Credo Agent
      • Decentralized Identifiers (DIDs)
        • Create a DID
        • Update a DID
        • Deactivate a DID
      • DID-Linked Resources
        • Create DID-Linked Resource
        • Resolve DID-Linked Resource
        • Create AnonCreds Schema
        • Create AnonCreds Credential Definition
      • Verifiable Credentials and Presentations
        • Issue a Verifiable Credential (AnonCreds)
        • Present a Verifiable Credential (AnonCreds)
    • 🍊ACA-Py
      • Setup ACA-Py Agent
      • Decentralized Identifiers (DIDs)
        • Create a DID
        • Update a DID
        • Deactivate a DID
      • DID-Linked Resources
        • Create AnonCreds Schema
        • Create AnonCreds Credential Definition
      • Verifiable Credentials and Presentations
        • AnonCreds
          • Issue a Verifiable Credential
          • Present a Verifiable Credential
          • Revoke a Verifiable Credential
        • JSON-LD
          • Issue a Verifiable Credential
          • Present a Verifiable Credential
    • 🍈Veramo
      • Setup Veramo CLI for cheqd
        • Troubleshooting Veramo CLI Setup
      • Decentralized Identifiers (DIDs)
        • Create a DID
        • Querying a DID
        • Update an existing DID
        • Deactivate a DID
        • Create an off-ledger holder DID
        • Managing Identity Keys
        • Troubleshooting
      • Verifiable Credentials and Presentations
        • Issue a Verifiable Credential
        • Verify a Verifiable Credential
        • Create a Verifiable Presentation
        • Verify a Verifiable Presentation
      • Credential Payments
        • Charge for Status List
        • Issue Credential with Encrypted Status List
        • Verifier pays Issuer
      • Bitstring Status List
        • Create Status List
        • Issuing a Verifiable Credential referencing Status List
      • DID-Linked Resources
        • Create a DID-Linked Resource
        • Create a new Resource version within existing Collection
    • đŸĢWalt.id Community Stack
  • đŸ—ī¸Architecture
    • Architecture Decision Record (ADR) Process
    • List of ADRs
      • đŸ”ĩADR 001: cheqd DID Method
      • đŸŸĸADR 002: DID-Linked Resources
      • 🟡ADR 003: DID Resolver
      • 🟠ADR 004: DID Registrar
      • đŸŸŖADR 005: DID Resolution & DID URL Dereferencing
  • đŸ’ĢAdvanced features and alternatives
    • âžĄī¸DID Registrar
      • Setup DID Registrar
      • Create a DID
      • Create a DID-Linked Resource
    • âŦ…ī¸DID Resolver
      • Setup DID Resolver
    • ⚡AnonCreds Object Method
      • Schemas
      • Credential Definitions
      • Revocation Registry Definitions
      • Revocation Status Lists
    • 🌠Advanced Tooling
      • cheqd Cosmos CLI for identity
        • Create a DID
        • Update a DID
        • Deactivate a DID
        • Query a DID
        • Create a DID-Linked Resource
        • Update a DID-Linked Resource
      • Direct interaction with ledger code
      • VDR Tools CLI with cheqd (deprecated)
      • Demo Wallet for Identity Setup
  • âš›ī¸Network
    • Get started with cheqd Network
      • Identity Write Pricing
      • Comparison to Hyperledger Indy
    • ⏊Setup your Wallet
      • Setup Leap Wallet
        • Congifure cheqd Testnet for Leap
      • Setup Keplr Wallet
      • Migrate from Keplr to Leap Wallet
    • â†Ēī¸Useful Tools and APIs
      • Block Explorer
      • Testnet Faucet
      • Validator Status API
      • Cheqd x Cosmos Data APIs
      • Cosmos Airdrop Helpers
      • Cosmos Address Convertor
      • Ethereum Bridge
    • âŦ†ī¸Network Upgrades
      • 2021
        • 0.1.x
        • 0.2.x
        • 0.3.x
      • 2022
        • 0.4.x
        • 0.5.x
        • 0.6.x
      • 2023
        • 1.x
      • 2024
        • 2.x
        • 3.x
      • Root Cause Analysis of Outages
        • v1.x upgrade RCA
  • âš–ī¸Legal
    • License
    • Code of Conduct
    • Security Policy
  • 🆘Support
    • System Status
    • Discord
    • Bugs & Feature Requests
Powered by GitBook
LogoLogo

General

  • Website
  • Blog
  • Get $CHEQ

Product Docs

  • Product Docs
  • cheqd Studio
  • Creds.xyz
  • Bug/Feature Requests

Technical Docs

  • Node Docs
  • GitHub
  • Block Explorer

Learning Docs

  • Learning Docs
  • Governance Docs
  • Governance Forum
  • Governance Explorer
On this page
  • Step 1: Install requisite packages
  • 1.1. Install Veramo CLI
  • 1.2. Install the did-provider-cheqd package
  • Step 2: Modify the cheqd plugin Agent configuration file
  • 2.1. Get the agent.yml configuration file
  • 2.2. Open the agent.yml file in an editor to customise the config
  • 2.3. Generate a new local database encryption key
  • 2.4. Set your DID Resolver endpoint
  • 2.5. Add cheqd Testnet to your Leap wallet
  • 2.6. Configure your cheqd/Cosmos account keys and RPC endpoints
  • 2.7. Save the agent.yml file and exit
  • Step 3: Verify your configuration file is correct
  • Next steps

Was this helpful?

Edit on GitHub
Export as PDF
  1. Integrate an SDK
  2. Veramo

Setup Veramo CLI for cheqd

Setup your Veramo CLI to start using cheqd's identity functionality, including Decentralized Identifiers (DIDs), Verifiable Credentials and DID-Linked Resources (DLRs).

Last updated 12 hours ago

Was this helpful?

If you're looking to use the Veramo CLI with cheqd or develop a proof-of-concept application, use the .

Step 1: Install requisite packages

Node version recommended Nodev20 or later. You can .

1.1. Install Veramo CLI

This step is exactly :

npm i @veramo/cli@latest -g

Note: Depending on your system permissions, you might be prompted for additional permissions. Add sudo to the beginning of the command in case that happens.

Verify the installation was correct. Command below should output latest version of Veramo you installed.

veramo -v
x.x.x

1.2. Install the did-provider-cheqd package

Install the did-provider-cheqd NPM package in a similar fashion:

npm install @cheqd/did-provider-cheqd@latest -g

You can check all of your NPM package versions by running the command:

npm list -g

Step 2: Modify the cheqd plugin Agent configuration file

2.1. Get the agent.yml configuration file

You can do this in terminal through:

wget -c https://raw.githubusercontent.com/cheqd/did-provider-cheqd/main/agent.yml

2.2. Open the agent.yml file in an editor to customise the config

You can open the agent.yml in a text editor/IDE of your choice to edit a few mandatory settings.

In terminal, you can edit the agent.yml file using an editor like nano:

nano <path/to/>agent.yml

Make sure you provide the actual relative/absolute path to the file.

2.3. Generate a new local database encryption key

By default, the did-provider-cheqd package has a default SQLite database password, but it's a good idea to modify and change this to a new key unique to your install.

$ veramo config gen-key

X25519 raw private key (hex encoded):

4a5aeb56c7956dd6f3312e7094130a03afc060b95621fa3a86577aaf2b67cc1d

You can use this key with @veramo/kms-local#SecretBox
or replace the default agent.yml 'dbEncryptionKey' constant

Take the key generated and replace the value under dbEncryptionKey in the agent.yml file.

2.4. Set your DID Resolver endpoint

did-cheqd-resolver:
    $require: '@cheqd/did-provider-cheqd?t=function&p=/cheqd#getResolver'
    $args:
        - url: 'https://resolver.cheqd.net/1.0/identifiers/'

The default value is set to resolver.cheqd.net, which is an instance of the cheqd DID Resolver hosted by the cheqd team. This DID Resolver instance can handle requests for did:cheqd:mainnet as well as did:cheqd:testnet namespaces.

If you want, you can replace the url property with a different REST API endpoint for a different instance of the cheqd DID Resolver.

Alternative/Optional: Use Universal Resolver instead

Note: This configuration is an advanced step and not recommended for most users. Skip it and continue to the next step in most cases, unless you know why you want to switch the resolver interface.

Firstly, comment out the custom did-cheqd-resolver entry and uncomment the universal-resolver entry. This tells Veramo CLI to use the Universal Resolver interface for did:cheqd.

# DID resolvers
didResolver:
    $require: '@veramo/did-resolver#DIDResolverPlugin'
    $args:
        - resolver:
              $require: did-resolver#Resolver
              $args:
                  - key:
                        $ref: /did-key-resolver
                    # cheqd:
                    #  $ref: /did-cheqd-resolver
                    cheqd:
                        $ref: /universal-resolver

Also comment out this section for the did-cheqd-resolver:

# did-cheqd-resolver:
#   $require: '@cheqd/did-provider-cheqd?t=function&p=/cheqd#getResolver'
#   $args:
#     - url: 'https://resolver.cheqd.net/1.0/identifiers/'

Finally, uncomment and configure the universal-resolver interface:

universal-resolver:
    $require: '@veramo/did-resolver#UniversalResolver'
    $args:
        - url: https://dev.uniresolver.io/1.0/identifiers/

2.5. Add cheqd Testnet to your Leap wallet

In order to add cheqd Testnet to your Leap extension, please follow the following tutorial:

2.6. Configure your cheqd/Cosmos account keys and RPC endpoints

# DID Manager
didManager:
---
defaultProvider: did:cheqd:testnet
providers:
    did:cheqd:mainnet:
        $require: '@cheqd/did-provider-cheqd#CheqdDIDProvider'
        $args:
            - defaultKms: local
              cosmosPayerMnemonic: <your_cosmos_mnemonic_paying_for_did_txs>
              networkType: mainnet
              rpcUrl: 'https://rpc.cheqd.net'
    did:cheqd:testnet:
        $require: '@cheqd/did-provider-cheqd#CheqdDIDProvider'
        $args:
            - defaultKms: local
              cosmosPayerMnemonic: <your_cosmos_mnemonic_paying_for_did_txs>
              networkType: testnet
              rpcUrl: 'https://rpc.cheqd.network'

You need to configure this in under didManager section as shown above, where you'll need to edit:

  1. defaultProvider: The default cheqd network is set to did:cheqd:testnet to allow developers to test out network functionality. However, if you prefer, you can switch this out to did:cheqd:mainnet instead.

2.7. Save the agent.yml file and exit

Make sure all your edits above are persisted and saved to a file that you can access.

Step 3: Verify your configuration file is correct

Once you've completed Step 2 above, verify that your Veramo configuration is accurate using the following command. If your configuration is correct, you should get a success message like the one below.

$ veramo config check -f <path/to/>agent.yml

Your Veramo configuration seems fine. An agent can be created and the 'agent.execute()' method can be called on it.

Next steps

Now that your Veramo CLI installation is successfully set up to work with cheqd, try following our tutorials for:

Download the file that contains the configuration for cheqd network to be used with Veramo CLI.

Note: Alternatively, you can also fetch this by the repository.

In order to be able to read/query did:cheqd entries from the ledger, you need to configure a REST API endpoint for a instance.

If you plan on interacting with multiple DID methods using Veramo CLI, you can alternatively query did:cheqd using instead. This allows your CLI configuration to handle .

While reading/querying from the cheqd ledger incurs no cost, if you want to to cheqd ledger, you need to pay transaction fees for the ledger writes.

cosmosPayerMnemonic: . This is only stored locally, and the mnemonic is used to reconstitute the account address and keys used to pay for the transaction.

rpcUrl: For both did:cheqd:mainnet: as well as did:cheqd:testnet: sections, you can specify a Cosmos SDK RPC endpoint. This endpoint is where transactions are sent to. By default, this is populated with rpc.cheqd.net (for mainnet) and rpc.cheqd.network (for testnet), but you can can modify this to or even your own local/private RPC endpoint.

If the config check throws an error, check out our to see common errors and fixes.

đŸ› ī¸
🍈
official Veramo CLI setup guide
install Node here
as described in Veramo CLI docs
agent.yml
cloning
did-provider-cheqd
cheqd DID Resolver
a Universal Resolver instance
any DID method supported by Universal Resolver
create/update a DID
Mnemonic associated with your cheqd/Cosmos SDK account
a different hosted RPC endpoint for cheqd
troubleshooting guide for Veramo CLI setup

Create a DID

Create a Decentralized Identifier (DID) on cheqd using Veramo.

Issue a Verifiable Credential

Issue a Verifiable Credential, signed by a did:cheqd Decentralized Identifier (DID), using Veramo.

Cover

Configure cheqd Testnet for Leap

Set up a cheqd testnet account using your Leap Wallet.