Purpose Preferences
Create Purpose Preference
Use this API to create a new Purpose Preference. The Purpose Preference will be created with the details provided in the request body.
post/api/consentmanager/v1/custompreferences
Request body
Example request
{
"Name": "Email Frequency",
"Description": "Allows users to select how often they would like to receive marketing emails",
"SelectionType": "SINGLE_CHOICE",
"DisplayAs": "BUTTONS",
"DefaultLanguage": true,
"Language": "en-US",
"Options": [
"Daily",
"Weekly",
"Monthly",
"Never"
],
"Organizations": [
"712a1f61-a548-432f-afc4-5a383c28eeb2",
"862a1f61-e148-032f-afc4-7a383c28eec6"
],
"Purposes": [
"a1b2c3d4-e5f6-4a5b-8c7d-9e0f1a2b3c4d"
]
}Response
OK
Example response
{
"Id": "194e0d3b-0ba8-4bc7-b046-e3ae42b2bd25",
"Name": "Email Frequency",
"Description": "Options for different frequencies to receive emails",
"SelectionType": "SINGLE_CHOICE",
"DisplayAs": "BUTTONs",
"CreatedDate": "2023-01-15T10:52:30.974Z",
"UpdatedDate": "2023-01-15T10:55:30.974Z",
"NumberOfOptions": 4,
"NumberOfLanguages": 3,
"DefaultLanguage": "en-us",
"Options": [
{
"Id": "ca0fc41b-b28a-4335-804c-44d1f0f782ed",
"Label": "Weekly",
"Order": 1,
"IsDefault": true,
"CanDelete": true
}
],
"Languages": [
{
"Name": "Email Frequency",
"Description": "Options for different frequencies to receive emails",
"Language": "en-us",
"Default": true,
"Options": [
{
"Id": "ca0fc41b-b28a-4335-804c-44d1f0f782ed",
"Label": "Weekly",
"Order": 1,
"IsDefault": true,
"CanDelete": true
}
]
}
],
"Organizations": [
"712a1f61-a548-432f-afc4-5a383c28eeb2"
],
"TotalLinkedActivePurposes": 5
}