Progress will discontinue Telerik Platform on May 10th, 2018. Learn more

Reading Push Notifications

Reading Push Notifications

You can read push notification data similarly to any other content type item. A push notification contains all the information that you have set when creating it, plus system fields that convey information such as state, dates, and App ID.

You can use the following variations of the read operation:

Read All

Use the following sample to get a list of all push notifications:

Request:
    GET https://api.everlive.com/v1/your-app-id/Push/Notifications
Headers:
    Authorization  Masterkey your-master-key
Response:
    Status: 200 OK
    Content-Type: application/json
$.ajax({
    type: "GET",
    url: 'https://api.everlive.com/v1/your-app-id/Push/Notifications',
    headers: {
        "Authorization": "Masterkey your-master-key"
    },
    success: function (data) {
        alert(JSON.stringify(data));
    },
    error: function (error) {
        alert(JSON.stringify(error));
    }
});

The above request returns an array of all push notification objects. For information about the push notification object content, see Push Notification Object Field Reference.

Read by Filter

Applying a filter allows you to narrow down the results based on the push notifications' field values.

The next example shows how to get a list of all notifications whose status is "Pending":

Request:
    GET https://api.everlive.com/v1/your-app-id/Push/Notifications  
Headers:
    Authorization  Masterkey your-master-key
    X-Everlive-Filter { "Status": 10 }  
Response:
    Status: 200 OK
    Content-Type: application/json
$.ajax({
    type: "GET",
    url: 'https://api.everlive.com/v1/your-app-id/Push/Notifications',
    headers: {
        "Authorization": "Masterkey your-master-key",
        "X-Everlive-Filter": JSON.stringify({
            "Status": 10
        })
    },
    success: function (data) {
        alert(JSON.stringify(data));
    },
    error: function (error) {
        alert(JSON.stringify(error));
    }
});

See Also


Contact us: +1-888-365-2779
sales@telerik.com
Copyright © 2016-2017, Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved.