7.3.7. Credential Services¶
Get the OpenAPI file for this interface: cms.yaml
7.3.7.1. Services¶
7.3.7.1.1. Credential Request¶
-
POST
/v1/credentialRequests/{credentialRequestId}
¶ Create a request for a credential
Parameters: - credentialRequestId (string) – the id of the credential request
Query Parameters: - transactionId (string) – The id of the transaction (Required)
Status Codes: - 201 Created – Operation successful
- 400 Bad Request – Bad request
- 403 Forbidden – Operation not allowed
- 500 Internal Server Error – Unexpected error
Example request:
POST /v1/credentialRequests/{credentialRequestId}?transactionId=string HTTP/1.1 Host: example.com Content-Type: application/json { "credentialRequestId": "string", "credentialProfileId": "string", "validFromDate": "2020-07-01T13:53:52.747039", "validToDate": "2020-07-01T13:53:52.747039", "personId": "string", "biographicData": { "title": "string", "firstName": "string", "lastName": "string", "dateOfBirth": "2020-07-01", "gender": "string", "nationality": "string", "email": "string", "mobileNumber": "string", "dn": "string", "address": { "address1": "11 Rue des Rosiers", "address2": null, "city": "Libourne", "state": null, "postalcode": "33500", "country": "France" }, "priority": "HIGH" }, "biometricData": [ { "biometricType": "FACE", "biometricSubType": "UNKNOWN", "encounterId": "string", "image": "c3RyaW5n", "imageRef": "https://example.com", "captureDate": "2020-07-01", "captureDevice": "string", "width": 1, "height": 1, "bitdepth": 1, "resolution": 1, "compression": "NONE" } ], "deliveryAddress": { "address1": "11 Rue des Rosiers", "address2": null, "city": "Libourne", "state": null, "postalcode": "33500", "country": "France" }, "status": "PENDING" }
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
-
GET
/v1/credentialRequests/{credentialRequestId}
¶ Read a credential request
Parameters: - credentialRequestId (string) – the id of the credential request
Query Parameters: - attributes (array) – The (optional) set of attributes to retrieve
- transactionId (string) – The id of the transaction (Required)
Status Codes: - 200 OK – Read successful
- 400 Bad Request – Bad request
- 403 Forbidden – Read not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
GET /v1/credentialRequests/{credentialRequestId}?transactionId=string HTTP/1.1 Host: example.com
Example response:
HTTP/1.1 200 OK Content-Type: application/json { "credentialRequestId": "string", "credentialProfileId": "string", "validFromDate": "2020-07-01T13:53:52.747039", "validToDate": "2020-07-01T13:53:52.747039", "personId": "string", "biographicData": { "title": "string", "firstName": "string", "lastName": "string", "dateOfBirth": "2020-07-01", "gender": "string", "nationality": "string", "email": "string", "mobileNumber": "string", "dn": "string", "address": { "address1": "11 Rue des Rosiers", "address2": null, "city": "Libourne", "state": null, "postalcode": "33500", "country": "France" }, "priority": "HIGH" }, "biometricData": [ { "biometricType": "FACE", "biometricSubType": "UNKNOWN", "encounterId": "string", "image": "c3RyaW5n", "imageRef": "https://example.com", "captureDate": "2020-07-01", "captureDevice": "string", "width": 1, "height": 1, "bitdepth": 1, "resolution": 1, "compression": "NONE" } ], "deliveryAddress": { "address1": "11 Rue des Rosiers", "address2": null, "city": "Libourne", "state": null, "postalcode": "33500", "country": "France" }, "status": "PENDING" }
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
-
PUT
/v1/credentialRequests/{credentialRequestId}
¶ Update a credential request
Parameters: - credentialRequestId (string) – the id of the credential request
Query Parameters: - transactionId (string) – The id of the transaction (Required)
Status Codes: - 204 No Content – Update successful
- 400 Bad Request – Bad request
- 403 Forbidden – Update not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
PUT /v1/credentialRequests/{credentialRequestId}?transactionId=string HTTP/1.1 Host: example.com Content-Type: application/json { "credentialRequestId": "string", "credentialProfileId": "string", "validFromDate": "2020-07-01T13:53:52.747039", "validToDate": "2020-07-01T13:53:52.747039", "personId": "string", "biographicData": { "title": "string", "firstName": "string", "lastName": "string", "dateOfBirth": "2020-07-01", "gender": "string", "nationality": "string", "email": "string", "mobileNumber": "string", "dn": "string", "address": { "address1": "11 Rue des Rosiers", "address2": null, "city": "Libourne", "state": null, "postalcode": "33500", "country": "France" }, "priority": "HIGH" }, "biometricData": [ { "biometricType": "FACE", "biometricSubType": "UNKNOWN", "encounterId": "string", "image": "c3RyaW5n", "imageRef": "https://example.com", "captureDate": "2020-07-01", "captureDevice": "string", "width": 1, "height": 1, "bitdepth": 1, "resolution": 1, "compression": "NONE" } ], "deliveryAddress": { "address1": "11 Rue des Rosiers", "address2": null, "city": "Libourne", "state": null, "postalcode": "33500", "country": "France" }, "status": "PENDING" }
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
-
DELETE
/v1/credentialRequests/{credentialRequestId}
¶ Delete a credential request
Parameters: - credentialRequestId (string) – the id of the credential request
Query Parameters: - transactionId (string) – The id of the transaction (Required)
Status Codes: - 204 No Content – Delete successful
- 400 Bad Request – Bad request
- 403 Forbidden – Delete not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
7.3.7.1.2. Credential¶
-
POST
/v1/credentials
¶ Retrieve a list of credentials that match the given search criteria
Query Parameters: - attributes (array) – The (optional) set of required attributes to retrieve
- transactionId (string) – The id of the transaction (Required)
Status Codes: - 200 OK – Read successful
- 400 Bad Request – Bad request
- 403 Forbidden – Read not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
POST /v1/credentials?transactionId=string HTTP/1.1 Host: example.com Content-Type: application/json [ { "attributeName": "string", "operator": "<", "value": "string" } ]
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "credentialId": "string", "personId": "string", "credentialProfileId": "string", "issuedDate": "2020-07-01T13:53:52.747039", "expiryDate": "2020-07-01T13:53:52.747039", "suspended": true, "revoked": true, "type": "string", "serialNumber": "string" } ]
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
-
GET
/v1/credentials/{credentialId}
¶ Read a credential
Parameters: - credentialId (string) – the id of the credential
Query Parameters: - attributes (array) – The (optional) set of required attributes to retrieve
- transactionId (string) – The id of the transaction (Required)
Status Codes: - 200 OK – Read successful
- 400 Bad Request – Bad request
- 403 Forbidden – Read not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
GET /v1/credentials/{credentialId}?transactionId=string HTTP/1.1 Host: example.com
Example response:
HTTP/1.1 200 OK Content-Type: application/json { "credentialId": "string", "personId": "string", "credentialProfileId": "string", "issuedDate": "2020-07-01T13:53:52.747039", "expiryDate": "2020-07-01T13:53:52.747039", "suspended": true, "revoked": true, "type": "string", "serialNumber": "string" }
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
-
POST
/v1/credentials/{credentialId}/suspend
¶ Suspend a credential
Parameters: - credentialId (string) – the id of the credential
Query Parameters: - transactionId (string) – The id of the transaction (Required)
Status Codes: - 204 No Content – Update successful
- 400 Bad Request – Bad request
- 403 Forbidden – Update not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
POST /v1/credentials/{credentialId}/suspend?transactionId=string HTTP/1.1 Host: example.com Content-Type: application/json { "reason": "string" }
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
-
POST
/v1/credentials/{credentialId}/unsuspend
¶ Unsuspend a credential
Parameters: - credentialId (string) – the id of the credential
Query Parameters: - transactionId (string) – The id of the transaction (Required)
Status Codes: - 204 No Content – Update successful
- 400 Bad Request – Bad request
- 403 Forbidden – Update not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
POST /v1/credentials/{credentialId}/unsuspend?transactionId=string HTTP/1.1 Host: example.com Content-Type: application/json { "reason": "string" }
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
-
POST
/v1/credentials/{credentialId}/revoke
¶ Revoke a credential
Parameters: - credentialId (string) – the id of the credential
Query Parameters: - transactionId (string) – The id of the transaction (Required)
Status Codes: - 204 No Content – Update successful
- 400 Bad Request – Bad request
- 403 Forbidden – Update not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
POST /v1/credentials/{credentialId}/revoke?transactionId=string HTTP/1.1 Host: example.com Content-Type: application/json { "reason": "string" }
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
7.3.7.1.3. Credential Profile¶
-
POST
/v1/credentialProfiles
¶ Retrieve a list of credential profiles that match the given search criteria
Query Parameters: - attributes (array) – The (optional) set of required attributes to retrieve
- transactionId (string) – The id of the transaction (Required)
Status Codes: - 200 OK – Read successful
- 400 Bad Request – Bad request
- 403 Forbidden – Read not allowed
- 404 Not Found – Unknown record
- 500 Internal Server Error – Unexpected error
Example request:
POST /v1/credentialProfiles?transactionId=string HTTP/1.1 Host: example.com Content-Type: application/json [ { "attributeName": "string", "operator": "<", "value": "string" } ]
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "credentialProfileId": "string", "name": "string", "description": "string", "credentialType": "SMARTCARD", "defaultLifetime": 1 } ]
Example response:
HTTP/1.1 500 Internal Server Error Content-Type: application/json { "code": 1, "message": "string" }
7.3.7.2. Data Model¶
To be completed