OneSignal

FREE
By dimashirokov
Updated 10 months ago
Communication
0.2/10
Popularity
57958ms
Latency
-
Success Rate

OneSignal API Documentation

Add push notification service to websites and apps.

View API Details
POSTaddDevice
POSTaddDevicePurchase
POSTcancelNotification
POSTcreateApp
POSTcreateDeviceSession
POSTeditDevice
POSTgetApp
POSTgetApps
POSTgetDevice
POSTgetDevices
POSTgetNotification
POSTgetNotifications
POSTnotificationTest
POSTsendNotification
POSTtrackNotificationOpen
POSTupdateApp
POSTupdateDeviceSessionLength
POSTsendNotification

Sends notifications to your users

Header Parameters
X-RapidAPI-HostSTRING
REQUIRED
X-RapidAPI-KeySTRING
REQUIRED
Required Parameters
includedSegmentsLIST
REQUIREDRequired: Comma-separated list of the segment names you want to target. Users in these segments will receive a notification. This targeting parameter is only compatible with excluded_segments. Example: [`Active Users`, `Inactive Users`]
appKeyCREDENTIALS
REQUIREDRequired: REST API keys are used for API calls on a specific app's notifications or devices.
appIdCREDENTIALS
REQUIREDRequired: Your OneSignal application ID, which can be found in Keys & IDs. It is a UUID and looks similar to `8250eaf6-1a58-489e-b136-7c74a864b434`.
appIdCREDENTIALS
REQUIREDRequired: Your OneSignal application ID, which can be found in Keys & IDs. It is a UUID and looks similar to `8250eaf6-1a58-489e-b136-7c74a864b434`.
appKeyCREDENTIALS
REQUIREDRequired: REST API keys are used for API calls on a specific app's notifications or devices.
contentsJSON
REQUIREDREQUIRED: unless content_available=true or template_id is set. The notification`s content (excluding the title), a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. English must be included in the hash.Example: `{"en": "English Message", "es": "Spanish Message"}`
appIdCREDENTIALS
REQUIREDRequired: Your OneSignal application ID, which can be found in Keys & IDs. It is a UUID and looks similar to `8250eaf6-1a58-489e-b136-7c74a864b434`.
appKeyCREDENTIALS
REQUIREDRequired: REST API keys are used for API calls on a specific app's notifications or devices.
appIdCREDENTIALS
REQUIREDRequired: Your OneSignal application ID, which can be found in Keys & IDs. It is a UUID and looks similar to `8250eaf6-1a58-489e-b136-7c74a864b434`.
appKeyCREDENTIALS
REQUIREDRequired: REST API keys are used for API calls on a specific app's notifications or devices.
appIdCREDENTIALS
REQUIREDRequired: Your OneSignal application ID, which can be found in Keys & IDs. It is a UUID and looks similar to `8250eaf6-1a58-489e-b136-7c74a864b434`.
Optional Parameters
appIdsLIST
OPTIONALOptional: Example: [`2dd608f2-a6a1-11e3-251d-400c2940e62b`, `2dd608f2-a6a1-11e3-251d-500f2950e61c`].
excludedSegmentsLIST
OPTIONALOptional: Comma-separated list of segment that will be excluded when sending. Users in these segments will not receive a notification, even if they were included in included_segments. This targeting parameter is only compatible with included_segments. Example: [`Active Users`, `Inactive Users`]
includePlayerIdsLIST
OPTIONALOptional: Comma-separated list of pecific players to send your notification to. Does not require API Auth Key. combine with other targeting parameters. Not compatible with any other targeting parameters. Example: [`1dd608f2-c6a1-11e3-851d-000c2940e62c`, `1dd608f2-c6a1-11e3-851d-000c2940e62c`]
chromeWebIconSTRING
OPTIONALOptional: Sets the web push notification's icon. An image URL linking to a valid image. Common image types are supported; GIF will not animate. We recommend 256x256 (at least 80x80) to display well on high DPI devices
admSmallIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
admLargeIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
iosSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. Pass 'nil' to disable vibration and sound for the notification.
androidSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. NOTE: Leave off file extension for Android.
wpSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
wpWnsSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
androidAccentColorSTRING
OPTIONALOptional: Sets the background color of the notification circle to the left of the notification text. Only applies to apps targeting Android API level 21+ on Android 5.0+ devices.
androidVisibilitySELECT
OPTIONALOptional: `1` = Public (default) (Shows the full message on the lock screen unless the user has disabled all notifications from showing on the lock screen. Please consider the user and mark private if the contents are.) `0` = Private (Hides message contents on lock screen if the user set "Hide sensitive notification content" in the system settings) `-1` = Secret (Notification does not show on the lock screen at all)
iosBadgeTypeSTRING
OPTIONALOptional: Describes whether to set or increase/decrease your app's iOS badge count by the `ios_badgeCount` specified count. Can specify `None`, `SetTo`, or `Increase`. `None` leaves the count unaffected.`SetTo` directly sets the badge count to the number specified in ios_badgeCount. `Increase` adds the number specified in ios_badgeCount to the total. Use a negative number to decrease the badge count.
sendAfterSTRING
OPTIONALOptional: Schedule notification for future delivery. Examples: All examples are the exact same date & time. `Thu Sep 24 2015 14:00:00 GMT-0700 (PDT)`; `September 24th 2015, 2:00:00 pm UTC-07:00`; `2015-09-24 14:00:00 GMT-0700`; `Sept 24 2015 14:00:00 GMT-0700`; `Thu Sep 24 2015 14:00:00 GMT-0700 (Pacific Daylight Time)`
delayedOptionSTRING
OPTIONALOptional: Possible values are: `timezone` (Deliver at a specific time-of-day in each users own timezone); `last-active` (Deliver at the same time of day as each user last used your app). If `send_after` is used, this takes effect after the send_after time has elapsed.
ttlNUMBER
OPTIONALOptional: Time To Live - In seconds. The notification will be expired if the device does not come back online within this time. The default is 259,200 seconds (3 days).
isAnyWebSELECT
OPTIONALOptional: Indicates whether to send to all subscribed web browser users, including Chrome, Firefox, and Safari. You may use this instead as a combined flag instead of separately enabling `isChromeWeb`, `isFirefox`, and `isSafari`, though the three options are equivalent to this one.
isFirefoxSELECT
OPTIONALOptional: Indicates whether to send to all Mozilla Firefox desktop users registered under your Firefox web push platform.
isWPSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.0 platform.
isWP_WNSSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.1+ platform.
isAdmSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Amazon Fire platform.
isChromeSELECT
OPTIONALOptional: Please see `isChromeWeb` for sending to web push users. This flag only applies to Google Chrome Apps & Extensions.
contentsJSON
OPTIONALREQUIRED: unless content_available=true or template_id is set. The notification`s content (excluding the title), a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. English must be included in the hash.Example: `{"en": "English Message", "es": "Spanish Message"}`
headingsJSON
OPTIONALOptional: The notification`s title, a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. A default title may be displayed if a title is not provided. Example: `{"en": "English Title", "es": "Spanish Title"}`
templateIdSTRING
OPTIONALOptional: Use a template you setup on our dashboard. You can override the template values by sending other parameters with the request. The template_id is the UUID found in the URL when viewing a template on our dashboard.
contentAvailableSTRING
OPTIONALOptional: Sends content-available=1 to wake your app to run custom native code.
filtersSTRING
OPTIONALOptional: The filters parameter targets notification recipients using an array of JSON objects containing field conditions to check.
dataJSON
OPTIONALOptional: A custom map of data that is passed back to your app. Example: `{"abc": "123", "foo": "bar"}`
urlSTRING
OPTIONALOptional: The URL to open in the browser when a user clicks on the notification. Example: `http://www.google.com`
bigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
admBigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
chromeBigPictureSTRING
OPTIONALOptional: Large picture to display below the notification text. Must be a local URL.
buttonsJSON
OPTIONALOptional: Buttons to add to the notification. Icon only works for Android. Example: `[{"id": "id1", "text": "button1", "icon": "ic_menu_share"}, {"id": "id2", "text": "button2", "icon": "ic_menu_send"}]`
webButtonsJSON
OPTIONALOptional: Add action buttons to the notification. The id field is required. `[{"id": "like-button", "text": "Like", "icon": "http://i.imgur.com/N8SN8ZS.png", "url": "https://yoursite.com"}, {"id": "read-more-button", "text": "Read more", "icon": "http://i.imgur.com/MIxJp1L.png", "url": "https://yoursite.com"}]`
iosCategorySTRING
OPTIONALOptional: Category APS payload, use with registerUserNotificationSettings:categories in your Objective-C / Swift code. Example: `calendar` category which contains actions like `accept` and `decline`
smallIconSTRING
OPTIONALOptional: If blank the app icon is used. Must be the drawable resource name.
largeIconSTRING
OPTIONALOptional: If blank the small_icon is used. Can be a drawable resource name or a URL.
admSmallIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
admLargeIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
chromeIconSTRING
OPTIONALOptional: For web push, please see chromeWebIcon instead.
iosSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. Pass 'nil' to disable vibration and sound for the notification.
androidSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. NOTE: Leave off file extension for Android.
admSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. NOTE: Leave off file extension for Android.
wpSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
wpWnsSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
androidLedColorSTRING
OPTIONALOptional: Sets the devices LED notification light if the device has one. ARGB Hex format.
androidAccentColorSTRING
OPTIONALOptional: Sets the background color of the notification circle to the left of the notification text. Only applies to apps targeting Android API level 21+ on Android 5.0+ devices.
androidVisibilitySELECT
OPTIONALOptional: `1` = Public (default) (Shows the full message on the lock screen unless the user has disabled all notifications from showing on the lock screen. Please consider the user and mark private if the contents are.) `0` = Private (Hides message contents on lock screen if the user set "Hide sensitive notification content" in the system settings) `-1` = Secret (Notification does not show on the lock screen at all)
iosBadgeTypeSTRING
OPTIONALOptional: Describes whether to set or increase/decrease your app's iOS badge count by the `ios_badgeCount` specified count. Can specify `None`, `SetTo`, or `Increase`. `None` leaves the count unaffected.`SetTo` directly sets the badge count to the number specified in ios_badgeCount. `Increase` adds the number specified in ios_badgeCount to the total. Use a negative number to decrease the badge count.
iosBadgeCountNUMBER
OPTIONALOptional: Used with `ios_badgeType`, describes the value to set or amount to increase/decrease your app's iOS badge count by. You can use a negative number to decrease the badge count when used with an `ios_badgeType` of `Increase`.
delayedOptionSTRING
OPTIONALOptional: Possible values are: `timezone` (Deliver at a specific time-of-day in each users own timezone); `last-active` (Deliver at the same time of day as each user last used your app). If `send_after` is used, this takes effect after the send_after time has elapsed.
ttlNUMBER
OPTIONALOptional: Time To Live - In seconds. The notification will be expired if the device does not come back online within this time. The default is 259,200 seconds (3 days).
isAndroidSELECT
OPTIONALOptional: Indicats whether to send to all devices registered under your app's Google Android platform.
isChromeWebSELECT
OPTIONALOptional: Indicates whether to send to all Google Chrome, Chrome on Android, and Mozilla Firefox users registered under your Chrome & Firefox web push platform.
isSafariSELECT
OPTIONALOptional: Indicates whether to send to all Apple's Safari desktop users registered under your Safari web push platform.isWP
isWPSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.0 platform.
isAdmSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Amazon Fire platform.
largeIconSTRING
OPTIONALOptional: If blank the small_icon is used. Can be a drawable resource name or a URL.
wpSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
admSmallIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
androidVisibilitySELECT
OPTIONALOptional: `1` = Public (default) (Shows the full message on the lock screen unless the user has disabled all notifications from showing on the lock screen. Please consider the user and mark private if the contents are.) `0` = Private (Hides message contents on lock screen if the user set "Hide sensitive notification content" in the system settings) `-1` = Secret (Notification does not show on the lock screen at all)
delayedOptionSTRING
OPTIONALOptional: Possible values are: `timezone` (Deliver at a specific time-of-day in each users own timezone); `last-active` (Deliver at the same time of day as each user last used your app). If `send_after` is used, this takes effect after the send_after time has elapsed.
chromeIconSTRING
OPTIONALOptional: For web push, please see chromeWebIcon instead.
androidLedColorSTRING
OPTIONALOptional: Sets the devices LED notification light if the device has one. ARGB Hex format.
androidSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. NOTE: Leave off file extension for Android.
iosBadgeCountNUMBER
OPTIONALOptional: Used with `ios_badgeType`, describes the value to set or amount to increase/decrease your app's iOS badge count by. You can use a negative number to decrease the badge count when used with an `ios_badgeType` of `Increase`.
dataJSON
OPTIONALOptional: A custom map of data that is passed back to your app. Example: `{"abc": "123", "foo": "bar"}`
isIosSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Apple iOS platform.
webButtonsJSON
OPTIONALOptional: Add action buttons to the notification. The id field is required. `[{"id": "like-button", "text": "Like", "icon": "http://i.imgur.com/N8SN8ZS.png", "url": "https://yoursite.com"}, {"id": "read-more-button", "text": "Read more", "icon": "http://i.imgur.com/MIxJp1L.png", "url": "https://yoursite.com"}]`
isAnyWebSELECT
OPTIONALOptional: Indicates whether to send to all subscribed web browser users, including Chrome, Firefox, and Safari. You may use this instead as a combined flag instead of separately enabling `isChromeWeb`, `isFirefox`, and `isSafari`, though the three options are equivalent to this one.
bigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
isWPSTRING
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.0 platform.
chromeBigPictureSTRING
OPTIONALOptional: Large picture to display below the notification text. Must be a local URL.
templateIdSTRING
OPTIONALOptional: Use a template you setup on our dashboard. You can override the template values by sending other parameters with the request. The template_id is the UUID found in the URL when viewing a template on our dashboard.
androidBackgroundLayoutJSON
OPTIONALOptional: Allowing setting a background image for the notification. This is a JSON object containing the following keys. `image` - Asset file, android resource name, or URL to remote image. recommend size: 1582x256; `headings_color` - Title text color ARGB Hex format. Example(Blue): "FF0000FF". `contents_color` - Body text color ARGB Hex format. Example(Red): "FFFF0000". Example: `{"image": "https://domain.com/background_image.jpg", "headings_color": "FFFF0000", "contents_color": "FF00FF00"}`
filtersSTRING
OPTIONALOptional: The filters parameter targets notification recipients using an array of JSON objects containing field conditions to check.
isAdmSTRING
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Amazon Fire platform.
isFirefoxSELECT
OPTIONALOptional: Indicates whether to send to all Mozilla Firefox desktop users registered under your Firefox web push platform.
mutableContentSTRING
OPTIONALOptional: Allows you to change the notification content in your app before it is displayed.
buttonsJSON
OPTIONALOptional: Buttons to add to the notification. Icon only works for Android. Example: `[{"id": "id1", "text": "button1", "icon": "ic_menu_share"}, {"id": "id2", "text": "button2", "icon": "ic_menu_send"}]`
urlSTRING
OPTIONALOptional: The URL to open in the browser when a user clicks on the notification. Example: `http://www.google.com`
contentAvailableSTRING
OPTIONALOptional: Sends content-available=1 to wake your app to run custom native code.
ttlSTRING
OPTIONALOptional: Time To Live - In seconds. The notification will be expired if the device does not come back online within this time. The default is 259,200 seconds (3 days).
wpWnsSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
admBigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
chromeWebIconSTRING
OPTIONALOptional: Sets the web push notification's icon. An image URL linking to a valid image. Common image types are supported; GIF will not animate. We recommend 256x256 (at least 80x80) to display well on high DPI devices
isAndroidSELECT
OPTIONALOptional: Indicats whether to send to all devices registered under your app's Google Android platform.
iosSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. Pass 'nil' to disable vibration and sound for the notification.
isChromeWebSELECT
OPTIONALOptional: Indicates whether to send to all Google Chrome, Chrome on Android, and Mozilla Firefox users registered under your Chrome & Firefox web push platform.
isChromeSELECT
OPTIONALOptional: Please see `isChromeWeb` for sending to web push users. This flag only applies to Google Chrome Apps & Extensions.
iosBadgeTypeSTRING
OPTIONALOptional: Describes whether to set or increase/decrease your app's iOS badge count by the `ios_badgeCount` specified count. Can specify `None`, `SetTo`, or `Increase`. `None` leaves the count unaffected.`SetTo` directly sets the badge count to the number specified in ios_badgeCount. `Increase` adds the number specified in ios_badgeCount to the total. Use a negative number to decrease the badge count.
isSafariSELECT
OPTIONALOptional: Indicates whether to send to all Apple's Safari desktop users registered under your Safari web push platform.isWP
androidAccentColorSTRING
OPTIONALOptional: Sets the background color of the notification circle to the left of the notification text. Only applies to apps targeting Android API level 21+ on Android 5.0+ devices.
sendAfterSTRING
OPTIONALOptional: Schedule notification for future delivery. Examples: All examples are the exact same date & time. `Thu Sep 24 2015 14:00:00 GMT-0700 (PDT)`; `September 24th 2015, 2:00:00 pm UTC-07:00`; `2015-09-24 14:00:00 GMT-0700`; `Sept 24 2015 14:00:00 GMT-0700`; `Thu Sep 24 2015 14:00:00 GMT-0700 (Pacific Daylight Time)`
smallIconSTRING
OPTIONALOptional: If blank the app icon is used. Must be the drawable resource name.
admSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. NOTE: Leave off file extension for Android.
headingsJSON
OPTIONALOptional: The notification`s title, a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. A default title may be displayed if a title is not provided. Example: `{"en": "English Title", "es": "Spanish Title"}`
admLargeIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
isWP_WNSSTRING
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.1+ platform.
iosCategorySTRING
OPTIONALOptional: Category APS payload, use with registerUserNotificationSettings:categories in your Objective-C / Swift code. Example: `calendar` category which contains actions like `accept` and `decline`
contentsJSON
OPTIONALREQUIRED: unless content_available=true or template_id is set. The notification`s content (excluding the title), a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. English must be included in the hash.Example: `{"en": "English Message", "es": "Spanish Message"}`
templateIdSTRING
OPTIONALOptional: Use a template you setup on our dashboard. You can override the template values by sending other parameters with the request. The template_id is the UUID found in the URL when viewing a template on our dashboard.
mutableContentSTRING
OPTIONALOptional: Allows you to change the notification content in your app before it is displayed.
dataJSON
OPTIONALOptional: A custom map of data that is passed back to your app. Example: `{"abc": "123", "foo": "bar"}`
urlSTRING
OPTIONALOptional: The URL to open in the browser when a user clicks on the notification. Example: `http://www.google.com`
bigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
admBigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
chromeBigPictureSTRING
OPTIONALOptional: Large picture to display below the notification text. Must be a local URL.
buttonsJSON
OPTIONALOptional: Buttons to add to the notification. Icon only works for Android. Example: `[{"id": "id1", "text": "button1", "icon": "ic_menu_share"}, {"id": "id2", "text": "button2", "icon": "ic_menu_send"}]`
webButtonsJSON
OPTIONALOptional: Add action buttons to the notification. The id field is required. `[{"id": "like-button", "text": "Like", "icon": "http://i.imgur.com/N8SN8ZS.png", "url": "https://yoursite.com"}, {"id": "read-more-button", "text": "Read more", "icon": "http://i.imgur.com/MIxJp1L.png", "url": "https://yoursite.com"}]`
iosCategorySTRING
OPTIONALOptional: Category APS payload, use with registerUserNotificationSettings:categories in your Objective-C / Swift code. Example: `calendar` category which contains actions like `accept` and `decline`
androidBackgroundLayoutJSON
OPTIONALOptional: Allowing setting a background image for the notification. This is a JSON object containing the following keys. `image` - Asset file, android resource name, or URL to remote image. recommend size: 1582x256; `headings_color` - Title text color ARGB Hex format. Example(Blue): "FF0000FF". `contents_color` - Body text color ARGB Hex format. Example(Red): "FFFF0000". Example: `{"image": "https://domain.com/background_image.jpg", "headings_color": "FFFF0000", "contents_color": "FF00FF00"}`
smallIconSTRING
OPTIONALOptional: If blank the app icon is used. Must be the drawable resource name.
chromeWebIconSTRING
OPTIONALOptional: Sets the web push notification's icon. An image URL linking to a valid image. Common image types are supported; GIF will not animate. We recommend 256x256 (at least 80x80) to display well on high DPI devices
admSmallIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
chromeIconSTRING
OPTIONALOptional: For web push, please see chromeWebIcon instead.
iosSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. Pass 'nil' to disable vibration and sound for the notification.
wpSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
wpWnsSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
androidLedColorSTRING
OPTIONALOptional: Sets the devices LED notification light if the device has one. ARGB Hex format.
androidAccentColorSTRING
OPTIONALOptional: Sets the background color of the notification circle to the left of the notification text. Only applies to apps targeting Android API level 21+ on Android 5.0+ devices.
androidVisibilitySELECT
OPTIONALOptional: `1` = Public (default) (Shows the full message on the lock screen unless the user has disabled all notifications from showing on the lock screen. Please consider the user and mark private if the contents are.) `0` = Private (Hides message contents on lock screen if the user set "Hide sensitive notification content" in the system settings) `-1` = Secret (Notification does not show on the lock screen at all)
iosBadgeCountNUMBER
OPTIONALOptional: Used with `ios_badgeType`, describes the value to set or amount to increase/decrease your app's iOS badge count by. You can use a negative number to decrease the badge count when used with an `ios_badgeType` of `Increase`.
sendAfterSTRING
OPTIONALOptional: Schedule notification for future delivery. Examples: All examples are the exact same date & time. `Thu Sep 24 2015 14:00:00 GMT-0700 (PDT)`; `September 24th 2015, 2:00:00 pm UTC-07:00`; `2015-09-24 14:00:00 GMT-0700`; `Sept 24 2015 14:00:00 GMT-0700`; `Thu Sep 24 2015 14:00:00 GMT-0700 (Pacific Daylight Time)`
delayedOptionSTRING
OPTIONALOptional: Possible values are: `timezone` (Deliver at a specific time-of-day in each users own timezone); `last-active` (Deliver at the same time of day as each user last used your app). If `send_after` is used, this takes effect after the send_after time has elapsed.
ttlNUMBER
OPTIONALOptional: Time To Live - In seconds. The notification will be expired if the device does not come back online within this time. The default is 259,200 seconds (3 days).
isIosSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Apple iOS platform.
isAndroidSELECT
OPTIONALOptional: Indicats whether to send to all devices registered under your app's Google Android platform.
isAnyWebSELECT
OPTIONALOptional: Indicates whether to send to all subscribed web browser users, including Chrome, Firefox, and Safari. You may use this instead as a combined flag instead of separately enabling `isChromeWeb`, `isFirefox`, and `isSafari`, though the three options are equivalent to this one.
isChromeWebSELECT
OPTIONALOptional: Indicates whether to send to all Google Chrome, Chrome on Android, and Mozilla Firefox users registered under your Chrome & Firefox web push platform.
isFirefoxSELECT
OPTIONALOptional: Indicates whether to send to all Mozilla Firefox desktop users registered under your Firefox web push platform.
isWPSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.0 platform.
isWP_WNSSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.1+ platform.
isAdmSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Amazon Fire platform.
isChromeSELECT
OPTIONALOptional: Please see `isChromeWeb` for sending to web push users. This flag only applies to Google Chrome Apps & Extensions.
contentsJSON
OPTIONALREQUIRED: unless content_available=true or template_id is set. The notification`s content (excluding the title), a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. English must be included in the hash.Example: `{"en": "English Message", "es": "Spanish Message"}`
headingsJSON
OPTIONALOptional: The notification`s title, a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. A default title may be displayed if a title is not provided. Example: `{"en": "English Title", "es": "Spanish Title"}`
contentAvailableSTRING
OPTIONALOptional: Sends content-available=1 to wake your app to run custom native code.
filtersSTRING
OPTIONALOptional: The filters parameter targets notification recipients using an array of JSON objects containing field conditions to check.
mutableContentSTRING
OPTIONALOptional: Allows you to change the notification content in your app before it is displayed.
dataJSON
OPTIONALOptional: A custom map of data that is passed back to your app. Example: `{"abc": "123", "foo": "bar"}`
urlSTRING
OPTIONALOptional: The URL to open in the browser when a user clicks on the notification. Example: `http://www.google.com`
bigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
chromeBigPictureSTRING
OPTIONALOptional: Large picture to display below the notification text. Must be a local URL.
buttonsJSON
OPTIONALOptional: Buttons to add to the notification. Icon only works for Android. Example: `[{"id": "id1", "text": "button1", "icon": "ic_menu_share"}, {"id": "id2", "text": "button2", "icon": "ic_menu_send"}]`
webButtonsJSON
OPTIONALOptional: Add action buttons to the notification. The id field is required. `[{"id": "like-button", "text": "Like", "icon": "http://i.imgur.com/N8SN8ZS.png", "url": "https://yoursite.com"}, {"id": "read-more-button", "text": "Read more", "icon": "http://i.imgur.com/MIxJp1L.png", "url": "https://yoursite.com"}]`
iosCategorySTRING
OPTIONALOptional: Category APS payload, use with registerUserNotificationSettings:categories in your Objective-C / Swift code. Example: `calendar` category which contains actions like `accept` and `decline`
androidBackgroundLayoutJSON
OPTIONALOptional: Allowing setting a background image for the notification. This is a JSON object containing the following keys. `image` - Asset file, android resource name, or URL to remote image. recommend size: 1582x256; `headings_color` - Title text color ARGB Hex format. Example(Blue): "FF0000FF". `contents_color` - Body text color ARGB Hex format. Example(Red): "FFFF0000". Example: `{"image": "https://domain.com/background_image.jpg", "headings_color": "FFFF0000", "contents_color": "FF00FF00"}`
smallIconSTRING
OPTIONALOptional: If blank the app icon is used. Must be the drawable resource name.
largeIconSTRING
OPTIONALOptional: If blank the small_icon is used. Can be a drawable resource name or a URL.
chromeWebIconSTRING
OPTIONALOptional: Sets the web push notification's icon. An image URL linking to a valid image. Common image types are supported; GIF will not animate. We recommend 256x256 (at least 80x80) to display well on high DPI devices
admSmallIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
admLargeIconSTRING
OPTIONALOptional: Specific Amazon icon to use. If blank the app icon is used. Must be the drawable resource name.
chromeIconSTRING
OPTIONALOptional: For web push, please see chromeWebIcon instead.
iosSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound. Pass 'nil' to disable vibration and sound for the notification.
wpSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
wpWnsSoundSTRING
OPTIONALOptional: Sound file that is included in your app to play instead of the default device notification sound.
androidLedColorSTRING
OPTIONALOptional: Sets the devices LED notification light if the device has one. ARGB Hex format.
androidAccentColorSTRING
OPTIONALOptional: Sets the background color of the notification circle to the left of the notification text. Only applies to apps targeting Android API level 21+ on Android 5.0+ devices.
iosBadgeCountNUMBER
OPTIONALOptional: Used with `ios_badgeType`, describes the value to set or amount to increase/decrease your app's iOS badge count by. You can use a negative number to decrease the badge count when used with an `ios_badgeType` of `Increase`.
sendAfterSTRING
OPTIONALOptional: Schedule notification for future delivery. Examples: All examples are the exact same date & time. `Thu Sep 24 2015 14:00:00 GMT-0700 (PDT)`; `September 24th 2015, 2:00:00 pm UTC-07:00`; `2015-09-24 14:00:00 GMT-0700`; `Sept 24 2015 14:00:00 GMT-0700`; `Thu Sep 24 2015 14:00:00 GMT-0700 (Pacific Daylight Time)`
delayedOptionSTRING
OPTIONALOptional: Possible values are: `timezone` (Deliver at a specific time-of-day in each users own timezone); `last-active` (Deliver at the same time of day as each user last used your app). If `send_after` is used, this takes effect after the send_after time has elapsed.
ttlNUMBER
OPTIONALOptional: Time To Live - In seconds. The notification will be expired if the device does not come back online within this time. The default is 259,200 seconds (3 days).
isAnyWebSELECT
OPTIONALOptional: Indicates whether to send to all subscribed web browser users, including Chrome, Firefox, and Safari. You may use this instead as a combined flag instead of separately enabling `isChromeWeb`, `isFirefox`, and `isSafari`, though the three options are equivalent to this one.
isChromeWebSELECT
OPTIONALOptional: Indicates whether to send to all Google Chrome, Chrome on Android, and Mozilla Firefox users registered under your Chrome & Firefox web push platform.
isFirefoxSELECT
OPTIONALOptional: Indicates whether to send to all Mozilla Firefox desktop users registered under your Firefox web push platform.
isSafariSELECT
OPTIONALOptional: Indicates whether to send to all Apple's Safari desktop users registered under your Safari web push platform.isWP
contentsJSON
OPTIONALREQUIRED: unless content_available=true or template_id is set. The notification`s content (excluding the title), a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. English must be included in the hash.Example: `{"en": "English Message", "es": "Spanish Message"}`
isWPSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Windows Phone 8.0 platform.
headingsJSON
OPTIONALOptional: The notification`s title, a map of language codes to text for each language. Each hash must have a language code string for a key, mapped to the localized text you would like users to receive for that language. A default title may be displayed if a title is not provided. Example: `{"en": "English Title", "es": "Spanish Title"}`
isAdmSELECT
OPTIONALOptional: Indicates whether to send to all devices registered under your app's Amazon Fire platform.
templateIdSTRING
OPTIONALOptional: Use a template you setup on our dashboard. You can override the template values by sending other parameters with the request. The template_id is the UUID found in the URL when viewing a template on our dashboard.
contentAvailableSTRING
OPTIONALOptional: Sends content-available=1 to wake your app to run custom native code.
filtersSTRING
OPTIONALOptional: The filters parameter targets notification recipients using an array of JSON objects containing field conditions to check.
mutableContentSTRING
OPTIONALOptional: Allows you to change the notification content in your app before it is displayed.
dataJSON
OPTIONALOptional: A custom map of data that is passed back to your app. Example: `{"abc": "123", "foo": "bar"}`
admBigPictureSTRING
OPTIONALOptional: Picture to display in the expanded view. Can be a drawable resource name or a URL.
chromeBigPictureSTRING
OPTIONALOptional: Large picture to display below the notification text. Must be a local URL.
buttonsJSON
OPTIONALOptional: Buttons to add to the notification. Icon only works for Android. Example: `[{"id": "id1", "text": "button1", "icon": "ic_menu_share"}, {"id": "id2", "text": "button2", "icon": "ic_menu_send"}]`
webButtonsJSON
OPTIONALOptional: Add action buttons to the notification. The id field is required. `[{"id": "like-button", "text": "Like", "icon": "http://i.imgur.com/N8SN8ZS.png", "url": "https://yoursite.com"}, {"id": "read-more-button", "text": "Read more", "icon": "http://i.imgur.com/MIxJp1L.png", "url": "https://yoursite.com"}]`
iosCategorySTRING
OPTIONALOptional: Category APS payload, use with registerUserNotificationSettings:categories in your Objective-C / Swift code. Example: `calendar` category which contains actions like `accept` and `decline`
androidBackgroundLayoutJSON
OPTIONALOptional: Allowing setting a background image for the notification. This is a JSON object containing the following keys. `image` - Asset file, android resource name, or URL to remote image. recommend size: 1582x256; `headings_color` - Title text color ARGB Hex format. Example(Blue): "FF0000FF". `contents_color` - Body text color ARGB Hex format. Example(Red): "FFFF0000". Example: `{"image": "https://domain.com/background_image.jpg", "headings_color": "FFFF0000", "contents_color": "FF00FF00"}`
smallIconSTRING
OPTIONALOptional: If blank the app icon is used. Must be the drawable resource name.
largeIconSTRING
OPTIONALOptional: If blank the small_icon is used. Can be a drawable resource name or a URL.
Code Snippet
Install SDK
Response ExampleSchema

Install SDK for (Node.js)Unirest

OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication