Improved
Interactions API: Improved Support for Communication Consent (Opt-Out/In)
about 1 month ago by Tim Sutor
Interactions API and Communication Consent
Previously Interactions API did not fully support communication consent (opt-out/in).
Specifically, it was not possible to include an opt-out/in status on an interaction while also specifying an overall status for the interaction (like successful_contact or wrong_number).
Previous Communication Consent Support
Previously the outcome enum property had an opted_out option.
New Communication Consent Support
Two things have changed:
-
The
opted_outoption has been removed from theoutcomeenum property. -
The
outcomesDetailedarray now supports a new "Communication Consent Outcome" object specifically for opt-in/out functionality. More info in the Body Params section here.
Example
Below is a snippet from Scenario 5 on the API Examples page:
{
...
"outcomesDetailed": [
{
"type": "survey_response",
"value": {
"questionText": "Are you able to attend the Weekend Rally in Cambridge?",
"questionId": "765",
"responseText": "No",
"responseId": "41"
}
},
{
"type":"communication_consent",
"value": {
"consentStatus":"opted_out"
}
}
],
...
}
