Create a DID-Linked Resource (DLR), linked to a Decentralized Identifier (DID) on cheqd, using Veramo.
collectionId: The last fragment of the corresponding DIDDocamount: 2500000000amount: 10000000000amount: 5000000000{
"name": "degreeSchema",
"version": "1.5.7",
"attrNames": ["name", "age", "degree", "grade"]
}$ uuidgen
e7b662f8-d3f8-4a83-bd00-2cdcd6cc50ab$ base64 -w 0 resource.json
<path-to-the-resource-file>$ base64 -w 0 resource.json
SGVsbG8sIHdvcmxk{
"kms": "local",
"payload": {
"collectionId": "d3e515cf-81af-40cb-9ac1-154827986d29", // unique ID of associated 'parent' DID
"id": "e7b662f8-d3f8-4a83-bd00-2cdcd6cc50ab",
"name": "TestResource",
"resourceType": "JsonDocument",
"version": "",
"alsoKnownAs": [],
"data": "SGVsbG8sIHdvcmxk" // note that the base64 encoded content is passed here
},
"network": "testnet",
"signInputs": [{
"verificationMethodId": "did:cheqd:testnet:d3e515cf-81af-40cb-9ac1-154827986d29#key-1",
"keyType": "Ed25519",
"privateKeyHex": "0f5c124886178037952e87e0cdc55d185732577fca19ae877e64ac9ab24a0cc534e5326e70f1a42d785d93048aee806c359ec75a7b06f39253befd1746708438"
}],
"fee": {
"amount": [{
"denom": "ncheq",
"amount": "2500000000" // 2.5 CHEQ is the fixed fee for a JSON transaction
}],
"gas": "1000000",
"payer": "cheqd1rnr5jrt4exl0samwj0yegv99jeskl0hsxmcz96" // must match the account set in the agent.yaml file
}
}{
"kms": "local",
"payload": {
"collectionId": "d3e515cf-81af-40cb-9ac1-154827986d29",
"id": "e7b662f8-d3f8-4a83-bd00-2cdcd6cc50ab",
"name": "TestResource",
"resourceType": "JsonDocument"
"version": "",
"alsoKnownAs": []
},
"network": "testnet",
"signInputs": [{
"verificationMethodId": "did:cheqd:testnet:d3e515cf-81af-40cb-9ac1-154827986d29#key-1",
"keyType": "Ed25519",
"privateKeyHex": "0f5c124886178037952e87e0cdc55d185732577fca19ae877e64ac9ab24a0cc534e5326e70f1a42d785d93048aee806c359ec75a7b06f39253befd1746708438"
}],
"file": "/path/to/resource.json", // note that the resource passed as file is inputted here
"fee": {
"amount": [{
"denom": "ncheq",
"amount": "2500000000" // 2.5 CHEQ is the fixed fee for a JSON transaction
}],
"gas": "1000000",
"payer": "cheqd1rnr5jrt4exl0samwj0yegv99jeskl0hsxmcz96" // must match the account set in the agent.yaml file
}
}veramo execute -m cheqdCreateLinkedResource --argsFile path/to/payload.json