GetDigitalCertificate
Retrieves a digital certificate either by its ID or by the combination of account, issuer, name, and type.
Request
GET /nxt?requestType=getDigitalCertificate
All endpoints use port 22024 by default.
Parameters
| Name | Type | Description | Required |
|---|---|---|---|
certificate | string | Certificate ID (unsigned long) | Yes* |
account | string | Account ID or SHAMWARI address | Yes* |
issuer | string | Issuer account ID or SHAMWARI address | Yes* |
certificateName | string | Certificate name | Yes* |
certificateType | string | Certificate type | Yes* |
*Provide either certificate OR all of account+issuer+certificateName+certificateType.
Response
{
"certificate": "9876543210123456789",
"name": "IdentityCert",
"type": "IDENTITY",
"account": "1234567890123456789",
"issuer": "9876543210123456789",
"issuerRS": "SHAMWARI-ABCD-EFGH-IJKL-MNOPQ",
"timestamp": 1700000000,
"expirationTimestamp": 1893456000,
"signature": "hex_encoded_signature...",
"canonicalContent": "hex_encoded_content...",
"revoked": false,
"active": true,
"errorCode": 0,
"errorDescription": ""
}
Error Codes
| Code | Description |
|---|---|
| 3 | Missing parameters |
| 4 | Invalid certificate ID format |
| 5 | Certificate not found |
Example
curl "http://localhost:22024/nxt?requestType=getDigitalCertificate&certificate=9876543210123456789"