Trust Registry Proof Templates

Assigns a proof template to a trust registry

POSThttps://api-testnet.dock.io/trust-registries/{registryId}/proof-templates
Path parameters
registryId*string

A trust registry id

registryId*string

A Trust Registry ID

Body

Proof template ID

id*string

The proof template ID

Example: "a6cd414a-6eba-4241-9a9c-6f75864edbd5"
Response

Trust Registry has been assigned the proof template

Request
const response = await fetch('https://api-testnet.dock.io/trust-registries/{registryId}/proof-templates', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "id": "a6cd414a-6eba-4241-9a9c-6f75864edbd5"
    }),
});
const data = await response.json();
Response
{
  "type": "text",
  "message": "text"
}

Get Trust Registry proof templates

Returns the Trust Registry proof templates

GEThttps://api-testnet.dock.io/trust-registries/{registryId}/proof-templates
Path parameters
registryId*string

A trust registry id

Query parameters
Response

List of proof templates

Body
total*integer

Total number of proof templates

Example: 200
list*array of ProofRequest (object)
Request
const response = await fetch('https://api-testnet.dock.io/trust-registries/{registryId}/proof-templates', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "total": 200,
  "list": [
    {
      "id": "37275574-7ea4-438d-b8ef-f8fc61dbf09e",
      "name": "Proof request",
      "nonce": "1234567890",
      "qr": "http://creds-testnet.dock.io/proof/37275574-7ea4-438d-b8ef-f8fc61dbf09e",
      "did": "did:dock:xyz",
      "verified": false
    }
  ]
}

Remove Trust Registry proof template

Removes a Trust Registry proof template

DELETEhttps://api-testnet.dock.io/trust-registries/{registryId}/proof-templates/{templateId}
Path parameters
registryId*string

A trust registry id

templateId*string

A proof template id

Response

Trust Registry proof template has been deleted

Request
const response = await fetch('https://api-testnet.dock.io/trust-registries/{registryId}/proof-templates/{templateId}', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();
Response
{
  "type": "text",
  "message": "text"
}

Last updated