Manage your identity keys for creating cheqd Decentralized Identifiers (DIDs) using Veramo.
veramo execute -m cheqdGenerateDidDoc --argsJSON '{"verificationMethod": "JsonWebKey2020", "methodSpecificIdAlgo": "uuid", "network": "testnet"}'veramo execute -m cheqdGenerateDidDoc --argsFile path/to/exampleFile.jsonMethod: cheqdGenerateDidDoc
Arguments: {
"argsObj": {
"verificationMethod": "Ed25519VerificationKey2020",
"methodSpecificIdAlgo": "uuid",
"network": "testnet"
}
}
Result : {
"didDoc": {
"context": [],
"id": "did:cheqd:testnet:e43f36e4-9fa6-40a4-a8f9-7f7b49eb44db",
"controller": [
"did:cheqd:testnet:e43f36e4-9fa6-40a4-a8f9-7f7b49eb44db"
],
"authentication": [
"did:cheqd:testnet:e43f36e4-9fa6-40a4-a8f9-7f7b49eb44db#key-1"
],
"assertionMethod": [],
"capabilityInvocation": [],
"capabilityDelegation": [],
"keyAgreement": [],
"alsoKnownAs": [],
"verificationMethod": [
{
"id": "did:cheqd:testnet:e43f36e4-9fa6-40a4-a8f9-7f7b49eb44db#key-1",
"type": "Ed25519VerificationKey2020",
"controller": "did:cheqd:testnet:e43f36e4-9fa6-40a4-a8f9-7f7b49eb44db",
"publicKeyMultibase": "z2yJuNbhoUpRn7ypAugSLzkCc8QEw146RJ8DD3jzCZQ6A",
"publicKeyJwk": []
}
],
"service": []
},
"keys": {
"publicKeyHex": "XXXX",
"privateKeyHex": "XXXXXXXX",
"kid": "XXXX",
"type": "Ed25519"
}
}Unexpected token v in JSON at position 1veramo execute -m cheqdGenerateIdentityKeysMethod: cheqdGenerateIdentityKeys
Arguments: {
"argsObj": {
"args": {}
}
}
Result : {
"publicKeyHex": "XXXX",
"privateKeyHex": "XXXXXXXXX",
"kid": "XXXX",
"type": "Ed25519"
}import { fromString, toString } from 'uint8arrays'
const keyPairBase64: IKeyPair = {
publicKey: toString(fromString(keyPair.publicKeyHex, 'hex'), 'base64'),
privateKey: toString(fromString(keyPair.privateKeyHex, 'hex'), 'base64')
}