Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.yoid.me/llms.txt

Use this file to discover all available pages before exploring further.

Overview

With a credential template defined, you can now issue a specific credential by providing the template ID and the youth’s actual data. The API returns URIs that deliver the credential to the youth’s wallet.

Endpoint

POST https://test.didxtech.com/me-creds/api/credentials/issuance

Request

curl -X POST "https://test.didxtech.com/me-creds/api/credentials/issuance" \
  -H "Authorization: Bearer <access_token>" \
  -H "Content-Type: application/json" \
  -d '{
    "credentialTemplateId": "tpl_6421a8905c17830c188e2e2f",
    "attributes": {
      "programmeName": "Umuzi Web Development Programme",
      "completionDate": "2025-03-15",
      "fullName": "Thandi Molefe",
      "skillsCovered": "HTML, CSS, JavaScript, React, Node.js",
      "assessmentScore": "87"
    }
  }'

Request Body

FieldTypeDescription
credentialTemplateIdstringThe id from the credential template created in Step 2
attributesobjectKey-value pairs matching the attributes defined in the template. Required attributes must be present.

Response

HTTP 200 OK
{
  "data": {
    "id": "iss_cm7d9cq5600pwk3zq3kmpg8uc",
    "status": "offered",
    "credentials": [
      {
        "id": "cred_abc123def456",
        "status": "pending"
      }
    ],
    "offerUri": "https://didx.co.za/invitation?credential_offer_uri=...",
    "offerQrUri": "https://didx.co.za/invitation?credential_offer_uri=...&qr=true",
    "createdAt": "2025-01-20T11:27:37.051Z",
    "updatedAt": "2025-01-20T11:27:37.051Z"
  }
}

Key Response Fields

FieldDescription
idIssuance ID — use for revocation and webhook correlation
statusoffered — the credential is ready to be delivered
credentialsArray of individual credentials in this issuance
offerUriThe URI to pass to Step 4 — this delivers the credential to the youth’s wallet
offerQrUriQR-optimised version for scanning with a wallet app
Two IDs, different purposes. The top-level id (iss_cm7d9cq5600pwk3zq3kmpg8uc) is the issuance ID — use this for revocation and webhook correlation. The nested credentials[0].id is the individual credential ID. For revocation, always use the top-level id, not credentials[0].id.

What Happens on the Youth’s Side

At this point, the credential exists as an offer — it hasn’t reached the youth’s wallet yet. The next step (Step 4) delivers it. But once delivered:
  • If Thandi has already activated her wallet, the credential appears as a pending item she can accept or reject
  • If she hasn’t activated yet, the credential waits in custody until she signs in
  • She reviews the credential attributes in her wallet before accepting
  • Once accepted, the credential is stored permanently in her wallet and available for presentation to verifiers

Tracking Issuance Status

Rather than polling, use webhooks to track what happens after issuance:
EventMeaning
openid4vc.issuance.offeredCredential offer sent to youth
openid4vc.issuance.completedYouth accepted and received the credential
openid4vc.issuance.failedIssuance attempt failed
openid4vc.issuance.expiredOffer expired before youth accepted
Save the offerUri from the response — you need it in Step 4: Send Credential Offer to Wallet.