API reference
Consents
Customer API: GET /consents, PATCH /consents
Channels the customer can be reached on (email, SMS, LINE, WhatsApp) with the current marketing status. Bounced or complained channels are locked.
Response 200
consentsobject[]requiredconsents[].channel"EMAIL" | "SMS" | "LINE" | "WHATSAPP"requiredconsents[].status"NEVER_SUBSCRIBED" | "PENDING" | "SUBSCRIBED" | "UNSUBSCRIBED" | "BOUNCED" | "COMPLAINED"requiredconsents[].changeablebooleanrequiredFalse when the channel bounced or was reported as spam.
consents[].updatedAtstring | nullrequired
curl -X GET "https://{site}/api/v1/customer/consents" \
-H "Authorization: Bearer $KANORIO_CUSTOMER_TOKEN"Recorded as a first-party consent change (source LOGIN) with IP and user agent as evidence; a previously unsubscribed customer can re-subscribe here.
Request body
channel"EMAIL" | "SMS" | "LINE" | "WHATSAPP"requiredsubscribedbooleanrequired
Response 200
consentobjectrequiredconsent.channel"EMAIL" | "SMS" | "LINE" | "WHATSAPP"requiredconsent.status"NEVER_SUBSCRIBED" | "PENDING" | "SUBSCRIBED" | "UNSUBSCRIBED" | "BOUNCED" | "COMPLAINED"requiredconsent.changeablebooleanrequiredFalse when the channel bounced or was reported as spam.
consent.updatedAtstring | nullrequired
Errors
VALIDATION400CONSENT_LOCKED409
curl -X PATCH "https://{site}/api/v1/customer/consents" \
-H "Authorization: Bearer $KANORIO_CUSTOMER_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'