Proof templates

To verify a credential verifier will need to create a proof template and generate a proof request to which the holder wallet will provide the verifiable presentation. Verifiable presentations can not be done via the API, the credential SDK is needed to create a presentation.

When working with proof requests you will often want to request the same information from holders. To make this easier you can create proof request templates to define the contents of the proof requests to be re-used.

Create a proof template

Create a new proof template

post

Create a proof template

Authorizations
Body

Represents a proof template payload in a verifiable credential system.

namestringRequired

Proof request name

Example: Proof request
didstring · min: 32Optional

A DID

Example: did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59
Responses
200
Proof request template created
application/json
post
POST /proof-templates HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 215

{
  "name": "Proof request",
  "request": {
    "name": "test request",
    "purpose": "my purpose",
    "input_descriptors": null
  },
  "expirationTime": {
    "amount": 1,
    "unit": "months"
  },
  "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59"
}
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "totalRequests": 1,
  "isOwner": true,
  "created": "2025-06-30T22:20:02.303Z",
  "updated": "2025-06-30T22:20:02.303Z",
  "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59",
  "request": {
    "name": "test request",
    "purpose": "my purpose",
    "input_descriptors": null
  },
  "types": [
    "jsonld"
  ]
}

Get proof templates

List all proof templates

get
Authorizations
Query parameters
offsetinteger · int32Optional

How many items to offset by for pagination

Default: 0
limitinteger · int32 · min: 1 · max: 64Optional

How many items to return at one time (max 64)

Default: 64
Responses
200
A paged array of proof templates
application/json
get
GET /proof-templates HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Accept: */*
[
  {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "totalRequests": 1,
    "isOwner": true,
    "created": "2025-06-30T22:20:02.303Z",
    "updated": "2025-06-30T22:20:02.303Z",
    "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59",
    "request": {
      "name": "test request",
      "purpose": "my purpose",
      "input_descriptors": null
    },
    "types": [
      "jsonld"
    ]
  }
]

Get details of a specific proof template

Get proof templates

get

Get the details of an existing proof templates

Authorizations
Path parameters
idstring · uuidRequired

Proof template UUID

Responses
200
Returns the information about the proof templates
application/json
get
GET /proof-templates/{id} HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Accept: */*
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "totalRequests": 1,
  "isOwner": true,
  "created": "2025-06-30T22:20:02.303Z",
  "updated": "2025-06-30T22:20:02.303Z",
  "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59",
  "request": {
    "name": "test request",
    "purpose": "my purpose",
    "input_descriptors": null
  },
  "types": [
    "jsonld"
  ]
}

Update a proof template

Update a proof template

patch
Authorizations
Path parameters
idstring · uuidRequired

Proof template UUID

Body

Represents a proof template payload in a verifiable credential system.

namestringRequired

Proof request name

Example: Proof request
didstring · min: 32Optional

A DID

Example: did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59
Responses
200
Profile has been updated
application/json
patch
PATCH /proof-templates/{id} HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 215

{
  "name": "Proof request",
  "request": {
    "name": "test request",
    "purpose": "my purpose",
    "input_descriptors": null
  },
  "expirationTime": {
    "amount": 1,
    "unit": "months"
  },
  "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59"
}
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "totalRequests": 1,
  "isOwner": true,
  "created": "2025-06-30T22:20:02.303Z",
  "updated": "2025-06-30T22:20:02.303Z",
  "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59",
  "request": {
    "name": "test request",
    "purpose": "my purpose",
    "input_descriptors": null
  },
  "types": [
    "jsonld"
  ]
}

Get proof requests from template

Use the Verified parameter when needing to get only those verifications that were succsessful.

Gets the proof requests from this template

get
Authorizations
Path parameters
idstring · uuidRequired

Proof template UUID

Query parameters
verifiedbooleanOptional

Whether the presentation was verified or not

offsetinteger · int32Optional

How many items to offset by for pagination

Default: 0
limitinteger · int32 · min: 1 · max: 64Optional

How many items to return at one time (max 64)

Default: 64
Responses
200
Returns the information about the proof request history
application/json
get
GET /proof-templates/{id}/history HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Accept: */*
[
  {
    "id": "37275574-7ea4-438d-b8ef-f8fc61dbf09e",
    "attributes": {
      "ANY_ADDITIONAL_PROPERTY": {
        "name": "favouriteDrink",
        "names": [
          "age"
        ]
      }
    },
    "name": "Proof request",
    "nonce": "1234567890",
    "error": "text",
    "response_url": "http://api-testnet.truvera.io/proof-requests/37275574-7ea4-438d-b8ef-f8fc61dbf09e/send-presentation",
    "qr": "http://creds-testnet.truvera.io/proof/37275574-7ea4-438d-b8ef-f8fc61dbf09e",
    "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59",
    "verified": false,
    "expired": false,
    "presentation": {},
    "created": "2024-09-26T12:38:10.871Z",
    "updated": "2024-09-26T12:38:10.871Z",
    "request": {
      "name": "test request",
      "purpose": "my purpose",
      "input_descriptors": null
    },
    "type": "proof-request",
    "types": [
      "jsonld"
    ],
    "credentialsIssuers": [
      {
        "issuerDid": "text",
        "issuerName": "text",
        "issuerLogo": "text",
        "issuerTrustRegistries": [
          {
            "name": "text",
            "logoUrl": "text"
          }
        ]
      }
    ]
  }
]

Delete a proof template

Delete proof templates

delete

Deletes the proof templates and associated data

Authorizations
Path parameters
idstring · uuidRequired

Proof template UUID

Responses
200
Proof templates will be deleted
delete
DELETE /proof-templates/{id} HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Accept: */*

No content

Delete history for proof template

This endpoint provides an irreversible deletion of all of proof template's verification history data.

Deletes all the history for this proof template

delete

Deletes all the history for this proof template

Authorizations
Path parameters
idstring · uuidRequired

Proof template UUID

Query parameters
verifiedbooleanOptional

Whether the presentation was verified or not

offsetinteger · int32Optional

How many items to offset by for pagination

Default: 0
limitinteger · int32 · min: 1 · max: 64Optional

How many items to return at one time (max 64)

Default: 64
Responses
200
Proof requests have been deleted
delete
DELETE /proof-templates/{id}/history HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Accept: */*

No content

Delete a proof template

Delete proof templates

delete

Deletes the proof templates and associated data

Authorizations
Path parameters
idstring · uuidRequired

Proof template UUID

Responses
200
Proof templates will be deleted
delete
DELETE /proof-templates/{id} HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Accept: */*

No content

Last updated

Was this helpful?