Data Processing Consent
Consent Initialization
POST /api/consent/personal/init
Request body:
| Field | Required | Type | Description |
|---|---|---|---|
| iin | ✅ | regex: \d{12} | IIN |
| phone | ✅ | regex: \d{11} | Phone |
Response:
json
{
"status": "ok",
"timestamp": 1687506066000,
"data": {
"id": 23,
"iin": "999999999999",
"phone": "99999999999",
"status": "pending",
"error": null,
"accessToken": null,
"expiresAt": null,
"createdAt": "2023-06-23T07:39:37.000000Z"
}
}Possible consent process statuses:
pending,valid,invalid,timeout,not_found,error
TIP
This request returns an existing consent process or creates a new one if none exists.
Get Consent by ID
GET /api/consent/personal/{id}
Response:
json
{
"status": "ok",
"timestamp": 1687506066000,
"data": {
"id": 23,
"iin": "999999999999",
"phone": "99999999999",
"status": "pending",
"error": null,
"accessToken": null,
"expiresAt": null,
"createdAt": "2023-06-23T07:39:37.000000Z"
}
}Get Client Consents
GET /api/consent/personal/iin/{iin}
GET /api/consent/personal/client/{clientId}
Response:
json
{
"status": "ok",
"timestamp": 1687506066000,
"data": [
{
"id": 23,
"iin": "999999999999",
"phone": "99999999999",
"status": "pending",
"error": null,
"accessToken": null,
"expiresAt": null,
"createdAt": "2023-06-23T07:39:37.000000Z"
}
]
}