Proof requests

Proof templates are used to create proof requests. When a proof request is created, you will receive a URL which needs to be displayed in a QR code for a wallet application to scan.

Create Proof Request

This route uses a template ID and takes the PEX request you defined there.

Creates proof request

post

Creates a proof request from this template

Authorizations
Path parameters
idstring · uuidRequired

Proof template UUID

Body
noncestringOptional

A unique nonce value used in the proof request.

Example: 123456
didstring · min: 32Optional

The DID that will be used as the verifier DID in the proof request

Example: did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59
Responses
200
Returns the information about the proof request
application/json
Responseall of
post
POST /proof-templates/{id}/request HTTP/1.1
Host: api-testnet.truvera.io
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 81

{
  "nonce": "123456",
  "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59"
}
{
  "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"
  ],
  "verifierName": "Truvera",
  "verifierLogo": "https://logo.truvera.io/verifier"
}

Create Proof Request

This route lets you create a standalone proof request without storing a verification template first.

Create a new proof request

post

Create a proof request

Authorizations
Body

Represents a proof request payload in a verifiable credential system.

namestringRequired

Proof request name

Example: Proof request
templatestring · uuidOptional

The unique identifier for the template.

Example: 37275574-7ea4-438d-b8ef-f8fc61dbf09e
noncestringOptional

Nonce or challenge for the presentation to match

Example: 1234567890
didstring · min: 32Optional

A DID

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

{
  "attributes": {
    "ANY_ADDITIONAL_PROPERTY": {
      "name": "favouriteDrink",
      "names": [
        "age"
      ]
    }
  },
  "name": "Proof request",
  "template": "37275574-7ea4-438d-b8ef-f8fc61dbf09e",
  "nonce": "1234567890",
  "did": "did:cheqd:testnet:ac2b9027-ec1a-4ee2-aad1-1e316e7d6f59",
  "request": {
    "name": "test request",
    "purpose": "my purpose",
    "input_descriptors": null
  }
}
{
  "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"
  ],
  "verifierName": "Truvera",
  "verifierLogo": "https://logo.truvera.io/verifier"
}

Get all proof requests

List all proof requests

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 requests
application/json
get
GET /proof-requests 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"
    ]
  }
]

Get the details of an existing proof request

Get proof request

get

Get the details of an existing proof request

Authorizations
Path parameters
idstring · uuidRequired

Proof request UUID

Responses
200
Returns the information about the proof request
application/json
Responseall of
get
GET /proof-requests/{id} 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"
  ],
  "verifierName": "Truvera",
  "verifierLogo": "https://logo.truvera.io/verifier"
}

Delete the proof request

Delete proof request

delete

Deletes the proof request and associated data

Authorizations
Path parameters
idstring · uuidRequired

Proof request UUID

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

No content

Last updated

Was this helpful?