DoctavianDoctavian
ClickwrapConsents

Consent List

GET
/consents/list

This endpoint retrieves a list of consents associated with the requesting user or system. This endpoint returns detailed information about each consent session, including timestamps, user environment data, acceptance status, and related term definitions.

Authorization

X-Subscription-Key<token>

In: header

Header Parameters

Authorization?string

JWT token to authenticate the request on behalf of a specific Microsoft user or a backend service principal.

X-Subscription-Key?string

Unique API key used to identify and authorize access to a specific environment

Response Body

application/json

curl -X GET "https://example.com/consents/list"
"{\n  \"result\": {\n    \"statusCode\": 200,\n    \"message\": \"OK\",\n    \"data\": [\n      {\n        \"consent\": {\n          \"ipAddress\": \"{{userIpAddress}}\",\n          \"termDefinitionId\": \"{{termDefinitionId}}\",\n          \"sessionId\": \"{{sessionId}}\",\n          \"sessionStartDatetime\": \"{{sessionStartDatetime}}\",\n          \"sessionExpirationDatetime\": \"{{sessionExpirationDatetime}}\",\n          \"environmentData\": \"{{environmentDescription}}\",\n          \"additionalData\": \"{{customConsentMetadata}}\",\n          \"externalUserId\": \"{{externalUserIdentifier}}\",\n          \"accepted\": true, //false\n          \"acceptedDatetime\": \"{{acceptedTimestamp}}\"\n        }\n      }\n    ]\n  },\n  \"origin\": \"{{originEnvironment}}\",\n  \"dateTime\": \"{{responseTimestamp}}\",\n  \"userId\": \"{{userId}}\"\n}"