Send Bulk App Pushes

Prev Next

Bulk Push API is a service that sends push notifications to a predefined segment over the web using predefined web services and can be used to send bulk push notifications to the selected segment. 

You can reach the analytics of your bulk push notifications sent via Experience > Message > App Push on Insider’s InOne. Your pushed will be named {campaignName}-API.

The system authorizes only the 127.0.0.1 IP by default. This IP restricts the requests to the Insider APIs. To use the Mobile APIs, you must delete the default added IP or add your IPs to the IP Address Authorization list.

Endpoint and Headers

POST https://mobile.useinsider.com/api/v1/push/bulk

Headers

Header

Sample Value

Description

Content-Type

application/json

This header specifies the media type of the resource.

Body Parameters

Parameter

Description

Data Type

Required

api_key

Your API Key. Refer to API Authentication Tokens to get your API key.

String

Yes

campaign_name

Name of the push campaign.

String

Yes

segment_name

Name of the segment the push notification is sent to. You can get the segment name through Audience > Segments > Saved Segments.

String

Yes

title

Title of the push notification. For instance, it can be your App name.

String

Yes

content

Content of the push notification.

String

Yes

deeplink

Key/value pairs to be passed to the application in the push payload. The most common use of deep links is sending the user to the selected landing page when they open the push notification.

Object

No

notification_image

URL of the image in the rich push notification. If advanced_push_items is in use, notification_image will not be displayed.

String

No

goal_event

Key to set campaign goal to track conversions on repoorting of the campaigns.

String

No

android_sound

Name of the custom sound file in your app to play a custom sound on Android devices.

String

No

ios_sound

Name of the custom sound file in your app to play a custom sound on iOS devices.

String

No

test_push

true will send the push notification only to the test devices.

Boolean

No

advanced_push_items

Array of Advanced Push Items object.

Array

No

preferred_type

It is required only to send Advanced Pushes. E.g. carousel, slider.

String

No

override_global_freq_cap

true will override global frequency capping limit.

Boolean

No

Sample Body

Before sending the request, make sure to replace the values in your request body.

The sample body below is a push notification campaign that specifies the campaign and segment names, title and content, deep links, notification image, sounds for Android/iOS, and additional options such as test mode, frequency cap override, advanced push items with headlines, descriptions, and images, delivered in a carousel format.

App push notifications are sent to a user's last active device.

{
   "api_key":"Your API Key goes here",
   "campaign_name":"Insider API Demo",
   "segment_name":"Your segment name goes here",
   "title":"Your push notification title goes here",
   "content":"Your push content goes here.",
   "deeplink":{
      "your_deeplink_key":"value",
      "your_another_deeplink_key":"value"
   },
   "notification_image":"https://your_image_url.jpg",
   "goal_event":"your_event",
   "android_sound":"Your custom sound name for Android goes here",
   "ios_sound":"Your custom sound name for iOS goes here",
   "test_push":true,
   "override_global_freq_cap":true,
   "advanced_push_items":[
      {
         "headline":"Title for the item 1",
         "description":"Description for the item 1",
         "image_url":"https://your_image_url.jpg",
         "deep_links":{
            "your_deeplink_key":"value"
         }
      },
      {
         "headline":"Title for the item 2",
         "description":"Description for the item 2",
         "image_url":"https://your_image_url.jpg",
         "deep_links":{
            "your_deeplink_key":"value"
         }
      },
      {
         "headline":"Title for the item 3",
         "description":"Description for the item 3",
         "image_url":"https://your_image_url.jpg",
         "deep_links":{
            "your_deeplink_key":"value"
         }
      }
   ],
   "preferred_type":"carousel"
}

Below is a sample JSON for single app push.

{
   "api_key":"Your API Key goes here",
   "campaign_name":"Insider API Demo",
   "segment_name":"Your segment name goes here",
   "title":"Your push notification title goes here",
   "content":"Your push content goes here.",
   "deeplink":{
      "your_deeplink_key":"value",
      "your_another_deeplink_key":"value"
   },
   "notification_image":"https://your_image_url.jpg",
   "goal_event":"your_event",
   "android_sound":"Your custom sound name for Android goes here",
   "ios_sound":"Your custom sound name for iOS goes here",
   "test_push":true,
   "override_global_freq_cap":true,
}

Sample Responses

  • 200 Campaign created successfully

This response indicates that your campaign was created successfully.

{
    "response": "Campaign Created."
}
  • 400 Invalid API Key

The API Key sent in the payload does not match the API key at Insider. Please contact Insider for more information.

{
    "response": "No Partner Found With Api Key."
}
  • 422 No Push Message Certificate

Refer to Push Certificates to see how to add push certificates for iOS, Android, and Huawei.

{
    "response": "No Push Message Certificate is Provided."
}

Fail Records Messages

Message

Definition

Error Creating Campaign

Some parameters are missing in the campaign. Check all the required parameters.

No API Key Provided

The API key is a required parameter.

No Title Provided

Push notification title is a required parameter. It should be sent in the payload.

No Content Provided

Push content is a required parameter. It should be sent in the payload.

No Partner Found With API Key

The API Key sent in the payload does not match the API key at Insider. Please contact Insider for more information.

Bad IP

The IP the push payload is sent from is not whitelisted.

No Segment Matched

The segment name in the payload does not match any segments on the Insider Dashboard.

AdvancedPushItems should contain at least 3, max. 6 items.

If advanced_push_items key is in use in the request body, it should contain at least 3 and max 6 items.

Preferred Type is Not Carousel or Slider

If preferred_type key is in use in the request body, it can either be carousel or slider.

Invalid Advanced Push Payload

All the items for the Advanced Push Notification, should have Headline, Description, ImageURL variables defined and image URLs should be using HTTPS protocol.

Limitations

  • All functions must be executed with a simple HTTPS POST request.

  • The API key should be provided in the request body. If the key is incorrect, no operation will be executed.

  • The rate limit is 1000 requests per minute.

  • Each payload can contain only one bulk push campaign.

The default limit shown here is a standard baseline. If your use case requires higher capacity, feel free to reach out to the Insider One team — we can adjust it to fit your needs.