DID management functions enable the following:
List - lists the available DIDs
Load - loads a DID by the specified id
Delete - deletes a DID by the specified url
Resolve - resolves a DID to a document
For more info on DIDs, go here .
List DID
The /did
endpoint lists the available DIDs.
curl Request body schema Response body schema
Copy curl -X 'GET' \
'https://custodian.ssikit.walt.id/did' \
-H 'accept: application/json'
Copy The list of DID strings
E.g. List the available DIDs
curl Response body
Copy curl -X 'GET' \
'https://custodian.ssikit.walt.id/did' \
-H 'accept: application/json'
Copy [
"did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX",
"did:web:my.domain",
"did:web:walt.id",
"did:key:z6Mkv58vGsBMwbiyQ3P93MRnYfRgGvn4STEEsj5hFHYe51wu"
]
Load DID
The /did/{id}
endpoint loads a DID specified by:
id path parameter (required) - the DID url string
curl Request body schema Response body schema
Copy curl -X 'GET' \
'https://custodian.ssikit.walt.id/{id}' \
-H 'accept: application/json'
Copy {
"assertionMethod":
[
"string"
],
"authentication":
[
"string"
],
"@context":
[
"string"
],
"id": "string",
"verificationMethod":
[
{
"controller": "string",
"id": "string",
"publicKeyJwk":
{
"alg": "string",
"crv": "string",
"kid": "string",
"kty": "string",
"use": "string",
"x": "string"
},
"type": "string"
}
]
}
E.g Load the DID having the id = did:web:walt.id .
curl Response body
Copy curl -X 'GET' \
'https://custodian.ssikit.walt.id/did/did%3Aweb%3Awalt.id' \
-H 'accept: application/json'
Copy {
"assertionMethod":
[
"did:web:walt.id#186a1e0a6d42459ba902724fe7643ed4"
],
"authentication":
[
"did:web:walt.id#186a1e0a6d42459ba902724fe7643ed4"
],
"@context":
[
"https://www.w3.org/ns/did/v1"
],
"id": "did:web:walt.id",
"verificationMethod":
[
{
"controller": "did:web:walt.id",
"id": "did:web:walt.id#186a1e0a6d42459ba902724fe7643ed4",
"publicKeyJwk":
{
"alg": "EdDSA",
"crv": "Ed25519",
"kid": "186a1e0a6d42459ba902724fe7643ed4",
"kty": "OKP",
"use": "sig",
"x": "7-ofBq4vt0ePzC5IjiWkqTedfSv7WJJr6-HsQNXsr2M"
},
"type": "Ed25519VerificationKey2019"
}
]
}
Delete DID
The /did/{id}
deletes the DID specified by:
url - path parameter (required) - the DID url string
curl Request body schema Response body schema
Copy curl -X 'DELETE' \
'https://custodian.ssikit.walt.id/did/{id}' \
-H 'accept: application/json'
E.g. Delete the DID having id = did:web:walt.id .
curl
Copy curl -X 'DELETE' \
'https://custodian.ssikit.walt.id/did/did%3Aweb%3Awalt.id' \
-H 'accept: application/json'
Create DID
The /did/create
endpoint creates a DID.
curl Request body schema Response body schema
Copy curl -X 'POST' \
'https://custodian.ssikit.walt.id/did/create' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '<request-body>'
Copy {
"method" : "string" ,
"keyAlias" : "string" ,
"method-dependent-options" : "..."
}
The method
and keyAlias
properties are common for all did-method requests, method
being required, while keyAlias
- optional (if not specified, a new key will be automatically created using the default algorithm according to the did-method ). The method-dependent options have default values, if not specified otherwise. Below are the available properties by did-method .
key web ebsi cheqd iota jwk
Copy {
"method" : "key" ,
"keyAlias" : "string" ,
"useJwkJcsPub" : "boolean"
}
useJwkJcsPub
(default) - false - specifies whether to create a did:key using the jwk_jcs-pub multicodec (code: 0xeb51 )
Copy {
"method" : "web" ,
"keyAlias" : "string" ,
"didWebDomain" : "string" ,
"didWebPath" : "string"
}
didWebDomain
(default) - "walt.id"
didWebPath
(default) - empty-string
Copy {
"method" : "ebsi" ,
"keyAlias" : "string" ,
"version" : "int"
}
Copy {
"method" : "cheqd" ,
"keyAlias" : "string" ,
"network" : "string"
}
network
(default) - "testnet"
Copy {
"method" : "iota" ,
"keyAlias" : "string"
}
Copy {
"method" : "jwk" ,
"keyAlias" : "string"
}
E.g. Create a DID using the web
method having the domain set to walt.id
.
curl Request body Response body
Copy curl -X 'POST' \
'https://custodian.ssikit.walt.id/did/create' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '{
"method": "web",
"didWebDomain": "walt.id"
}'
Copy {
"method" : "web" ,
"didWebDomain" : "walt.id"
}
Resolve DID
The /did/resolve
endpoint resolves a DID.
curl Request body schema Response body schema
Copy curl -X 'POST' \
'https://custodian.ssikit.walt.id/did/resolve' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '<request-body>'
Copy {
"assertionMethod":
[
"string"
],
"authentication":
[
"string"
],
"@context":
[
"string"
],
"id": "string",
"verificationMethod":
[
{
"controller": "string",
"id": "string",
"publicKeyJwk":
{
"alg": "string",
"crv": "string",
"kid": "string",
"kty": "string",
"use": "string",
"x": "string"
},
"type": "string"
}
]
}
E.g. Reslove the DID having id = did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX
.
curl Request body Response body
Copy curl -X 'POST' \
'https://custodian.ssikit.walt.id/did/resolve' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '{
"did": "did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX"
}'
Copy {
"did": "did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX"
}
Copy {
"assertionMethod":
[
"did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX#z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX"
],
"authentication":
[
"did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX#z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX"
],
"capabilityDelegation":
[
"did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX#z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX"
],
"capabilityInvocation":
[
"did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX#z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX"
],
"@context":
[
"https://www.w3.org/ns/did/v1"
],
"id": "did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX",
"keyAgreement":
[
"did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX#z6LShXhgLqK3vQX3eg18gwZUYNtt6M6FjPqpV1eQD86m8Hwh"
],
"verificationMethod":
[
{
"controller": "did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX",
"id": "did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX#z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX",
"publicKeyBase58": "6tW7uQ6c3YgZDoCFbHMB6QFjPENyHRouTUwGnLv36wS9",
"type": "Ed25519VerificationKey2019"
},
{
"controller": "did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX",
"id": "did:key:z6MkkLmAVeM3P6B2LJ2xGrK1wVojCoephK4G9VrCcct42ADX#z6LShXhgLqK3vQX3eg18gwZUYNtt6M6FjPqpV1eQD86m8Hwh",
"publicKeyBase58": "6rXWpXWBpwoJZHdNAJ3XDngQFCZ92nffc2viifTEQvAw",
"type": "X25519KeyAgreementKey2019"
}
]
}
Import DID
The /did/import
endpoint resolves and imports the DID to the underlying data store.
curl Request body schema Response body schema
Copy curl -X 'POST' \
'https://custodian.ssikit.walt.id/did/import' \
-H 'accept: application/json' \
-H 'Content-Type: text/plain' \
-d '<request-body>'
E.g. Import DID having id = did:key:z6Mkm8NbvDnnxJ2t5zLGSkYGCWZiqq11Axr58xQ3ZG1Jss3z
.
curl Request body
Copy curl -X 'POST' \
'https://custodian.ssikit.walt.id/did/import' \
-H 'accept: application/json' \
-H 'Content-Type: text/plain' \
-d 'did:key:z6Mkm8NbvDnnxJ2t5zLGSkYGCWZiqq11Axr58xQ3ZG1Jss3z'
Copy did:key:z6Mkm8NbvDnnxJ2t5zLGSkYGCWZiqq11Axr58xQ3ZG1Jss3z