Android Tags
If you don't already know how to tag your users, visit this documentation.
REST API: Get Your Tagged Users
Use the following API to get a list of all the tags that you have created for your subscribers.
curl -X GET \
https://apis.izooto.com/v1/topics
-H “Authentication-Token: 'Your_iZooto_API_Key'”
-H “Content-Type: application/json”
Sample Response
{
"topics": {
"Your Tag Name 1": 10,
"Your Tag Name 2": 40,
"Your Tag Name 3": 300
}
}
The data is returned in a JSON format where,
Type | Data Type | Description |
---|---|---|
Key | String | Tag Name. This would be the name of the tag you used while calling our addTag method. |
Value | Integer | Audience Reach. These would be the total number of users that are tagged under a particular name. |
Push Campaigns to Android Tags
Use the following API to send notifications only to a specific Tag you created for your Android Subscribers.
curl -X POST \
- H "Authentication-Token: {Your_iZooto_API_Key}" \
- H "Content-Type: application/json" \
-d '{
"title" : "{NOTIFICATION_TITLE}",
"message" : "{NOTIFICATION_MESSAGE}",
"icon_url" : "{ICON_URL}",
"banner_url" : "{BANNER_URL}",
"landing_url" : "{LANDING_URL}",
"actions" : [
{
"text" : "{BUTTON_1_TEXT}",
"url" : "{BUTTON_1_URL}",
"id":"{BUTTON_1_ACTION_ID}"
},
{
"text" : "{BUTTON_2_TEXT}",
"url" : "{BUTTON_2_URL}",
"id":"{BUTTON_2_ACTION_ID}"
}
],
"utm_source" : "{UTM_SOURCE}",
"utm_medium" : "{UTM_MEDIUM}",
"utm_campaign" : "{UTM_CAMPAIGN}",
"ttl" : {TTL_SECONDS},
"target" : {
"type": "topic",
"value" : "Your_Android_Tag_Name" # Replace this with your Tag Name.
},
"additional_params":{
"{KEY_1}":"{VALUE_1}",
"{KEY_2}":"{VALUE_2}",
"{KEY_3}":"{VALUE_3}",
"{KEY_4}":"{VALUE_4}",
"{KEY_5}":"{VALUE_5}"
},
"open_in_app" :{TRUE/FALSE}
}' "https://apis.izooto.com/v1/notifications"
For parameter definition, please refer to this documentation.
Updated almost 4 years ago