Add an OptOut
This document will go over how to add an OptOut using our API.
POST addressbook/optout
POST addressbook/optoutcurl -X POST \
"https://api.mobivatebulksms.com/addressbook/optout" \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer [API Key]' \
-d '{ "mobile": "440011122233" }'import requests
headers = {
'Content-Type': 'application/json',
'Authorization': 'Bearer [API Key]',
}
json_data = {
'mobile': '440011122233',
}
response = requests.post('https://api.mobivatebulksms.com/addressbook/optout', headers=headers, json=json_data)
# Note: json_data will not be serialized by requests
# exactly as it was in the original request.
#data = '{ "mobile": "440011122233" }'
#response = requests.post('https://api.mobivatebulksms.com/addressbook/optout', headers=headers, data=data)Name
Value
Name
Type
Required?
Description
{
"mobile":"440011122233",
"note":"API",
"created":1690783496000
}{
"code":400,
"message":"Invalid mobile number"
}{
"code":401,
"message":"Unauthorized"
}Last updated