Fetch all consent records
GET/audit/consent-records
This endpoint is used to fetch all consent records with pagination for individuals in an organisation defined in the consent building block.
Request
Query Parameters
Default value: 0
Number of records to skip for pagination. A negative or unreadable value falls back to 0.
Default value: 10
Maximum number of records to return per page.
Possible values: [consent, legal_obligation, contract, vital_interest, public_task, legitimate_interest]
Unique ID of an object
ID contains individual ID, data agreement ID or consent record ID
sector of the object
Responses
- 200
- 400
- 401
- 500
Consent records for data agreements (based on ISO 27560) listed successfully
Response Headers
- application/json
- Schema
- Example (from schema)
Schema
pagination object
Current page number
Total number of items available
Total number of pages based on limit
Number of items per page
Indicates if there's a previous page
Indicates if there's a next page
{
"consentRecords": [
{
"id": "65471222e8c7c3bb3c2c9901",
"dataAgreementId": "string",
"dataAgreementRevisionId": "string",
"dataAgreementRevisionHash": "a1b2c3d4e5f6...",
"individualId": "string",
"optIn": true,
"state": "signed",
"signatureId": "string",
"sectorPreferences": [
{
"sector": "",
"optIn": true,
"isLastUpdated": true
}
],
"timestamp": "string",
"dataAgreement": {
"version": "string",
"purpose": "string",
"lawfulBasis": ""
}
}
],
"pagination": {
"currentPage": 1,
"totalItems": 25,
"totalPages": 3,
"limit": 10,
"hasPrevious": false,
"hasNext": true
}
}
bad input parameter
Response Headers
Unauthorized
Response Headers
- application/json
- Schema
- Example (from schema)
Schema
{
"errorCode": 400,
"errorDescription": "Bad input parameter"
}
Internal server error
Response Headers
- application/json
- Schema
- Example (from schema)
Schema
{
"errorCode": 400,
"errorDescription": "Bad input parameter"
}