v1

latestOpenAPI 3.0.02026-07-2411724301.7 KB
1. Consent Update

The Kaleyra platform allows you to grant or revoke consent options to an end-customer based on channel and sender ID. This API allows you to send the option to your end-users to provide consent to your sender ID either using Opt-In or Opt-Out, based on regional regulations.

post/v1/{sid}/consent

Path parameters

sidstring required

Account SID (Security Identifier). For more information, see View API Key and SID.

Headers

api-keystring required

API key generated from the Kaleyra platform account. For more information, see View API Key and SID.

Request body

channelstring required

Channel name for which you want to update the consent. Example - sms.

sender_identifierstring required

Inbound Sender ID. In case of SMS, it’s the short code for customers.

contact_identifierstring required

Contact identifier of the end-user or end-user's mobile number.

consent_categorystring

Consent category. Example - Marketing, Transactional, or Promotional.

consent_topicstring

Consent topic. Example - Offers, Loan, or Insurance.

sourcestring required

Source of the consent request or source of opt-in or opt-out. Example - API.

source_identifierstring

Unique identifier for the source request. Example - MO_id. The MO_id is the identifier stored on the SMS database.

timestampstring date-time

Timestamp when the event occurred in ISO Date format (YYYY-MM-DDThh:mm:ss).

consent_statusstring required

Status of consent. Example - OPT_IN or OPT_OUT.

inbound_message_identifierstring

Inbound sender_id to which end-user is sending opt-in or opt-out message to. It will be the sender ID of the incoming MO.

request_identifierstring

Unique request ID from Kaleyra from where the consent API is triggered.

x_callback_urlstring

Callback URL to receive updates on processing.

Response

Accepted

object required