Skip to main content

Overview

A presentation template specifies what credentials and attributes you want to verify. The type field in the template must match the type from a credential template that was used during issuance — this is how the system knows which credentials to request from the user’s wallet.

Endpoint

POST https://test.didxtech.com/me-creds/api/templates/presentations

Request

curl -X POST "https://test.didxtech.com/me-creds/api/templates/presentations" \
  -H "Authorization: Bearer <access_token>" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "University Student Verification",
    "description": "Template for verifying university student credentials",
    "credentials": [
      {
        "name": "University Student Card",
        "description": "Digital student identification card",
        "type": "https://metadata.paradym.id/types/university-card-v1",
        "attributes": {
          "studentId": {
            "type": "string"
          },
          "fullName": {
            "type": "string"
          },
          "degreeProgram": {
            "type": "string"
          }
        }
      }
    ]
  }'

Request Body

FieldTypeDescription
namestringName for this presentation template
descriptionstringDescription of what this template verifies
credentialsarrayList of credential types to request
credentials[].typestringMust match the type URI from the issuer’s credential template
credentials[].attributesobjectThe specific attributes to request from the credential
The type field must be the full URI from the issuer’s credential template response (e.g. https://metadata.paradym.id/types/university-card-v1), not the short name used during template creation.

Response

HTTP 200 OK
{
  "data": {
    "name": "University Student Verification",
    "description": "Template for verifying university student credentials",
    "createdAt": "2025-02-20T11:27:37.051Z",
    "updatedAt": "2025-02-20T11:27:37.051Z",
    "id": "cm2ytsdid009u4ke3t30aiuvc",
    "credentials": [
      {
        "name": "University Student Card",
        "description": "Digital student identification card",
        "format": "sd-jwt-vc",
        "type": "https://metadata.paradym.id/types/university-card-v1",
        "attributes": {
          "studentId": {
            "type": "string"
          },
          "fullName": {
            "type": "string"
          },
          "degreeProgram": {
            "type": "string"
          }
        }
      }
    ]
  },
  "links": {
    "self": "https://test.didxtech.com/me-creds/api/templates/presentations/tpl_6421a8905c17830c188e2e2f"
  },
  "meta": {
    "version": "1.0"
  }
}

Key Response Fields

FieldDescription
idUnique template identifier — save this for use in Step 2
formatsd-jwt-vc — credential format used
Presentation templates are reusable. Create one template and use it for multiple verification requests — save the id for Step 2: Create a Presentation Request.