Skip to content

Commit cbb26a1

Browse files
tweeddalexgitbook-bot
authored andcommitted
GITBOOK-379: change request with no subject merged in GitBook
1 parent 98c4b2b commit cbb26a1

File tree

11 files changed

+352
-144
lines changed

11 files changed

+352
-144
lines changed

SUMMARY.md

+4-2
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,13 @@
8181
* [Update a DID](sdk/credo/decentralized-identifiers-dids/update-a-did.md)
8282
* [Deactivate a DID](sdk/credo/decentralized-identifiers-dids/deactivate-a-did.md)
8383
* [DID-Linked Resources](sdk/credo/did-linked-resources/README.md)
84+
* [Create DID-Linked Resource](sdk/credo/did-linked-resources/create-did-linked-resource.md)
85+
* [Resolve DID-Linked Resource](sdk/credo/did-linked-resources/resolve-did-linked-resource.md)
8486
* [Create AnonCreds Schema](sdk/credo/did-linked-resources/create-anoncreds-schema.md)
8587
* [Create AnonCreds Credential Definition](sdk/credo/did-linked-resources/create-anoncreds-credential-definition.md)
8688
* [Verifiable Credentials and Presentations](sdk/credo/verifiable-credentials-and-presentations/README.md)
87-
* [Issue a Verifiable Credential](sdk/credo/verifiable-credentials-and-presentations/issue-a-verifiable-credential.md)
88-
* [Present a Verifiable Credential](sdk/credo/verifiable-credentials-and-presentations/present-a-verifiable-credential.md)
89+
* [Issue a Verifiable Credential (AnonCreds)](sdk/credo/verifiable-credentials-and-presentations/issue-a-verifiable-credential.md)
90+
* [Present a Verifiable Credential (AnonCreds)](sdk/credo/verifiable-credentials-and-presentations/present-a-verifiable-credential.md)
8991
* [🍊 ACA-Py](sdk/aca-py/README.md)
9092
* [Setup ACA-Py Agent](sdk/aca-py/setup-aca-py-agent.md)
9193
* [Decentralized Identifiers (DIDs)](sdk/aca-py/decentralized-identifiers-dids/README.md)

sdk/credo/README.md

+35-9
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,44 @@
11
---
2-
description: >-
3-
Credo, formerly Hyperledger Aries Framework JavaScript (AFJ), with cheqd
4-
support
2+
description: Credo with cheqd support
53
---
64

75
# 🍏 Credo
86

9-
[Credo](https://credo.js.org/) is a framework written in TypeScript for building **SSI Agents and services** that aims to be **compliant and interoperable** with the standards defined in the European Architecture and Reference Framework.
7+
### Get Started with Credo
108

11-
The Aries Framework JavaScript project has recently been rebranded to "Credo" and was moved from the Hyperledger Foundation to the [Open Wallet Foundation](https://openwallet.foundation/). 
9+
**Credo** is a TypeScript-based framework for building Self-Sovereign Identity (SSI) agents and services. It is designed for **modularity**, **interoperability**, and **compliance** with the European Architecture and Reference Framework (ARF).
1210

13-
In the recent months, Credo has heavily been expanding into a more modular and "less specific" framework. The integration with cheqd is a prime example of this, being the first true showcase of anchoring AnonCreds on non-Indy ledgers. Supporting more credential formats, ledgers and DID methods is crucial and essential to the continual development of Credo. cheqd is now fully supported in Credo and can be used for the issuance of Verifiable Credentials as well as the creation of Credential Schemas and Credential Definitions.
11+
Previously known as _Aries Framework JavaScript_, Credo has recently been **rebranded** and transitioned from the **Hyperledger Foundation** to the **Open Wallet Foundation**, reflecting its broader mission and growing community.
1412

15-
AnonCreds using cheqd are facilitated using the [cheqd AnonCreds Object Method](../../advanced/anoncreds/).
13+
Credo has evolved into a more flexible and general-purpose SSI framework. A major milestone in this evolution is the full **integration with** [**cheqd**](https://cheqd.io) — making Credo the first framework to support **AnonCreds on non-Indy ledgers**.
14+
15+
This integration showcases Credo’s expanding support for:
16+
17+
* Multiple **credential formats**
18+
* Diverse **DID methods**
19+
* Interoperable **ledger technologies**
20+
21+
Using Credo, developers can now issue **Verifiable Credentials**, create **Credential Schemas**, and define **Credential Definitions** using **cheqd-native AnonCreds**, enabled by the **cheqd AnonCreds Object Method**.
22+
23+
### 🌟 Why Credo?
24+
25+
***TypeScript-native** — strongly typed, developer-friendly, and production-ready
26+
***Modular and extensible** — use only what you need, plug in new components
27+
***Cross-ledger compatibility** — supports Indy, cheqd, and beyond
28+
***Flexible credential support** — AnonCreds, W3C JSON-LD, JWT
29+
***Aligned with EU standards** — interoperable with EBSI & ARF
30+
***Backed by the Open Wallet Foundation** — with growing community adoption
31+
32+
### Breaking New Ground: Credo + cheqd
33+
34+
Credo is now the **first framework to support AnonCreds on non-Indy ledgers**, thanks to a deep integration with [**cheqd**](https://cheqd.io). ACA-Py has since followed suit.
35+
36+
This includes:
37+
38+
* Issuance of Verifiable Credentials on cheqd
39+
* Creation of Credential Schemas and Credential Definitions
40+
* Support for the **cheqd AnonCreds Object Method**
41+
* Native DID and resource support for `did:cheqd`
1642

1743
## Architecture
1844

@@ -26,9 +52,9 @@ AnonCreds using cheqd are facilitated using the [cheqd AnonCreds Object Method](
2652

2753
## Supported Credential types
2854

29-
Aries Framework JavaScript supports the following Credential formats:
55+
Credo supports the following Credential formats:
3056

31-
<table data-card-size="large" data-view="cards"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><mark style="color:blue;"><strong>SD-JWT</strong></mark></td><td>Selective Disclosure JWT (SD-JWT) is the most <strong>commonly adopted credential format for European Digital Identity Ecosystems</strong>, allowing users to selectively disclose which attributes they would like to share in a presentation.</td><td><a href="https://docs.cheqd.io/product/learning-docs/decentralised-identity/credentials/types/sd-jwt">https://docs.cheqd.io/product/learning-docs/decentralised-identity/credentials/types/sd-jwt</a></td></tr><tr><td><mark style="color:blue;"><strong>AnonCreds</strong></mark></td><td><strong>AnonCreds</strong> is a Zero-Knowledge Credential format, offering full Holder privacy and selective disclosure.</td><td><a href="https://hyperledger.github.io/anoncreds-spec/">https://hyperledger.github.io/anoncreds-spec/</a></td></tr><tr><td><mark style="color:blue;"><strong>JSON-LD</strong></mark></td><td><strong>JSON-LD (Linked Data)</strong> Credentials are a richer data format, allowing applications to follow embedded links to other pieces of Linked Data across the web.</td><td><a href="https://learn.cheqd.io/decentralised-identity/credentials/types/json-ld">https://learn.cheqd.io/decentralised-identity/credentials/types/json-ld</a></td></tr></tbody></table>
57+
<table data-card-size="large" data-view="cards"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><mark style="color:blue;"><strong>AnonCreds</strong></mark></td><td><strong>AnonCreds</strong> is a Zero-Knowledge Credential format, offering full Holder privacy and selective disclosure.</td><td><a href="https://hyperledger.github.io/anoncreds-spec/">https://hyperledger.github.io/anoncreds-spec/</a></td></tr><tr><td><mark style="color:blue;"><strong>SD-JWT</strong></mark></td><td>Selective Disclosure JWT (SD-JWT) is the most <strong>commonly adopted credential format for European Digital Identity Ecosystems</strong>, allowing users to selectively disclose which attributes they would like to share in a presentation.</td><td><a href="https://docs.cheqd.io/product/learning-docs/decentralised-identity/credentials/types/sd-jwt">https://docs.cheqd.io/product/learning-docs/decentralised-identity/credentials/types/sd-jwt</a></td></tr><tr><td><mark style="color:blue;"><strong>JSON-LD</strong></mark></td><td><strong>JSON-LD (Linked Data)</strong> Credentials are a richer data format, allowing applications to follow embedded links to other pieces of Linked Data across the web.</td><td><a href="https://learn.cheqd.io/decentralised-identity/credentials/types/json-ld">https://learn.cheqd.io/decentralised-identity/credentials/types/json-ld</a></td></tr></tbody></table>
3258

3359
## Watch our demo video
3460

sdk/credo/decentralized-identifiers-dids/create-a-did.md

+49-21
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,27 @@ description: Create a DID using the did:cheqd method from Credo Agent
44

55
# Create a DID
66

7-
Follow these instructions to create a new DID from Credo Agent and publish the associated DID Document on cheqd ledger.
7+
This tutorial shows you how to create a **cheqd DID** using your configured **Credo Agent**, and how to publish the associated **DID Document** to the **cheqd ledger**.
88

9-
> ⚠️ **Before you begin...**
10-
>
11-
> Make sure you've correctly configured [the Credo agent with cheqd](../setup-credo-agent.md).
9+
## ⚠️ Prerequisites
10+
11+
Before you begin:
12+
13+
* ✅ Ensure your **Credo agent** is correctly configured with the `@credo-ts/cheqd` module
14+
* ✅ You’ve set up a `cosmosPayerSeed` for publishing to the cheqd network
15+
* ✅ You're connected to the correct network (`mainnet` or `testnet`)
16+
17+
## Method Overview
18+
19+
Credo supports two approaches to creating a DID:
20+
21+
#### Option 1 – Manually construct a full DID Document
22+
23+
Use when you want full control over the DID structure and already have key(s) in your wallet.
24+
25+
#### Option 2 – Auto-generate the DID Document
26+
27+
Use when you want Credo to create the DID Document from a key you specify in `secret`.
1228

1329
## Create DID
1430

@@ -19,25 +35,29 @@ Follow these instructions to create a new DID from Credo Agent and publish the a
1935
3. `options`\*
2036
4. `didDocument`
2137

22-
### **Option 1**[****](https://credo.js.org/guides/tutorials/cheqd#option-1)
23-
24-
Provide a DID Document payload according to the w3c did core specification in the request body. This is possible when the keys corresponding to the verification methods provided in the DID Document are already created in the wallet
38+
### Option 1: Create a DID from a full DID Document
2539

26-
```typescript
40+
1. First, generate a key pair:
2741

28-
// create a key pair
42+
```ts
2943
const key = await agent.wallet.createKey({
3044
keyType: KeyType.Ed25519,
3145
})
3246

33-
// encode public key according to the verification method
3447
const ed25519PublicKeyBase58 = key.publicKeyBase58
48+
```
49+
50+
2. Use that key to construct and register the DID Document:
51+
52+
```ts
53+
import { DidDocument } from '@credo-ts/core'
3554

36-
// Create a DID
3755
await agent.dids.create<CheqdDidCreateOptions>({
3856
method: 'cheqd',
39-
secret: {},
40-
options: {},
57+
secret: {}, // No secret needed if key is already in wallet
58+
options: {
59+
network: 'testnet',
60+
},
4161
didDocument: new DidDocument({
4262
id: 'did:cheqd:testnet:92874297-d824-40ea-8ae5-364a1ec9237d',
4363
controller: ['did:cheqd:testnet:92874297-d824-40ea-8ae5-364a1ec9237d'],
@@ -49,32 +69,40 @@ await agent.dids.create<CheqdDidCreateOptions>({
4969
publicKeyBase58: ed25519PublicKeyBase58,
5070
},
5171
],
52-
authentication: ['did:cheqd:testnet:92874297-d824-40ea-8ae5-364a1ec9237d#key-1'],
72+
authentication: [
73+
'did:cheqd:testnet:92874297-d824-40ea-8ae5-364a1ec9237d#key-1',
74+
],
5375
}),
5476
})
5577
```
5678

79+
> 📝 Make sure the `publicKeyBase58` matches the key in your wallet.\
80+
> The DID will be written to the `testnet` unless you specify `"mainnet"` in `options.network`.
81+
5782
### **Option 2**[****](https://credo.js.org/guides/tutorials/cheqd#option-2)
5883

59-
If a DID Document is not passed to the registrar, it requires the secret parameter with a verificationMethod to construct the DID Document.
84+
If you don’t want to manually build a DID Document, you can let Credo handle it based on your input key type and ID.
6085

61-
```typescript
86+
```ts
6287
await agent.dids.create({
6388
method: 'cheqd',
64-
// the secret contains a the verification method type and id
6589
secret: {
6690
verificationMethod: {
67-
id: 'key-1',
68-
type: 'Ed25519VerificationKey2020',
91+
id: 'key-1', // Logical key name
92+
type: 'Ed25519VerificationKey2020', // Or another supported type
6993
},
7094
},
71-
// an optional methodSpecificIdAlgo parameter
7295
options: {
7396
network: 'testnet',
74-
methodSpecificIdAlgo: 'uuid',
97+
methodSpecificIdAlgo: 'uuid', // Optional: 'uuid' (default) or 'base58'
7598
},
7699
})
77100
```
78101

102+
> 🔐 Credo will generate the DID Document using the key referenced in `secret` and publish it to the network.
103+
104+
## What’s Next?
79105

106+
Now that your DID is live on the cheqd network, try:
80107

108+
<table data-card-size="large" data-view="cards"><thead><tr><th></th><th></th></tr></thead><tbody><tr><td><mark style="color:blue;"><strong>Create DID-Linked Resource</strong></mark></td><td>Associate DID-Linked Resources to your DID.</td></tr><tr><td><mark style="color:blue;"><strong>Issue Verifiable Credentials</strong></mark></td><td>Issue Credentials using your cheqd DID.</td></tr></tbody></table>

sdk/credo/decentralized-identifiers-dids/deactivate-a-did.md

+31-9
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,45 @@ description: Deactivate a did:cheqd from Credo Agent
44

55
# Deactivate a DID
66

7-
Follow these instructions to deactivate a did:cheqd DID from Credo Agent
7+
This guide explains how to **deactivate a `did:cheqd`** using a configured Credo Agent. Deactivating a DID marks it as no longer usable but does **not** remove it from the ledger — the DID can still be resolved and its deactivated state will be reflected in its metadata.
88

9-
## Deactivate DID
9+
## Prerequisites
1010

11-
A DID can be deactivated, it can still be resolved
11+
Before deactivating a DID, ensure that:
1212

13-
### **Parameters**[****](https://credo.js.org/guides/tutorials/cheqd#parameters-2)
13+
* The **Credo agent is configured** with cheqd support
14+
* The DID you are deactivating was created and is controlled by your agent
15+
* You have access to the signing key used to authorize DID updates
1416

15-
1. `did`\*
16-
2. `options`
17+
## Behavior of Deactivated DIDs
1718

18-
```typescript
19+
* Deactivated DIDs **remain resolvable**
20+
* DID resolvers will indicate that the DID is **deactivated**
21+
* The DID and its associated document become **immutable and non-functional**
22+
* Deactivation is **permanent**
23+
24+
### Parameters
25+
26+
| Parameter | Required | Description |
27+
| --------- | -------- | -------------------------------------------------------------- |
28+
| `did` || The full `did:cheqd` identifier you wish to deactivate |
29+
| `options` || Optional settings, including a `versionId` to track the update |
30+
31+
### Example: Deactivate a cheqd DID
32+
33+
```ts
1934
await agent.dids.deactivate({
2035
did: 'did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411',
21-
// an optional versionId parameter
2236
options: {
23-
versionId: '3.0',
37+
versionId: '3.0', // Optional: for tracking version history or audit purposes
2438
},
2539
})
2640
```
41+
42+
***
43+
44+
### Notes
45+
46+
* The optional `versionId` parameter allows you to assign a custom version identifier to the deactivation transaction
47+
* Once deactivated, the DID cannot be updated, reactivated, or used for issuing credentials
48+
* You can still resolve the DID to verify its deactivated status via the `deactivated: true` metadata

sdk/credo/decentralized-identifiers-dids/update-a-did.md

+41-15
Original file line numberDiff line numberDiff line change
@@ -4,32 +4,44 @@ description: Update a did:cheqd DID from Credo Agent
44

55
# Update a DID
66

7-
Follow these instructions to update a did:cheqd DID from Credo Agent.
7+
This guide walks you through how to **update an existing cheqd DID** using your configured **Credo Agent**. Updating a DID Document lets you add or modify keys, service endpoints, or other metadata associated with the DID.
88

9-
## Update DID
9+
## Prerequisites
1010

11-
To update a DID Document, fetch the body of the DID Document you want to change from the DID Resolver, make the relevant updates and pass it as the parameter
11+
Before you begin, make sure:
1212

13-
### **Parameters**[****](https://credo.js.org/guides/tutorials/cheqd#parameters-1)
13+
* ✅ Your Credo agent is already configured with cheqd support
14+
* ✅ You have write access to the DID (i.e., the key used for DID creation or a controller key)
15+
* ✅ You know the **DID you want to update** and its current document state
1416

15-
1. `did`\*
16-
2. `didDocument`\*: The updated DID Document
17-
3. `options`
18-
4. `secret`
17+
## How DID Updates Work
18+
19+
To update a `did:cheqd`, you must:
20+
21+
1. **Fetch the current DID Document**
22+
2. **Modify** the relevant fields (e.g., add keys, update service endpoints)
23+
3. **Submit the updated DID Document** using `agent.dids.update(...)`
24+
25+
### Example: Add a New Service and Verification Method
26+
27+
```ts
28+
import { DidDocumentService } from '@credo-ts/core'
1929

20-
```typescript
2130
await agent.dids.update({
2231
did: 'did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411',
23-
// Updates DID Document with an additional verification method if provided
32+
33+
// Used to authorize and derive additional keys, if needed
2434
secret: {
2535
verificationMethod: {
2636
id: 'key-2',
27-
type: 'JsonWebKey2020',
37+
type: 'JsonWebKey2020', // Can also be Ed25519VerificationKey2020, etc.
2838
},
2939
},
40+
3041
didDocument: {
3142
id: 'did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411',
3243
controller: ['did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411'],
44+
3345
verificationMethod: [
3446
{
3547
id: 'did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411#key-1',
@@ -38,15 +50,29 @@ await agent.dids.update({
3850
publicKeyMultibase: 'z6MknkzLUEP5cxqqsaysNMWoh8NJRb3YsowTCj2D6yhwyEdj',
3951
},
4052
],
41-
authentication: ['did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411#key-1'],
42-
// updates did document with a service block
53+
54+
authentication: [
55+
'did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411#key-1',
56+
],
57+
4358
service: [
4459
new DidDocumentService({
45-
id: 'did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411#rand',
46-
type: 'rand',
60+
id: 'did:cheqd:testnet:b84817b8-43ee-4483-98c5-f03760816411#website',
61+
type: 'linkedDomains',
4762
serviceEndpoint: 'https://rand.in',
4863
}),
4964
],
5065
},
5166
})
5267
```
68+
69+
***
70+
71+
### Parameters Reference
72+
73+
| Parameter | Required | Description |
74+
| ------------- | -------- | -------------------------------------------------------------------------- |
75+
| `did` || The DID you want to update |
76+
| `didDocument` || The **complete** updated DID Document |
77+
| `secret` | ⚠️ | Required only if you're referencing new keys not yet in the agent’s wallet |
78+
| `options` || Optional advanced settings (e.g., method-specific configurations) |

0 commit comments

Comments
 (0)