The Push Notifications API is currently available as a
Private Beta product. The information contained in this document is subject to change. You acknowledge
and agree that your use of the Twilio Push Notifications API is subject to the terms of the Services in
Private Beta. This
means that some features are not yet implemented and others may be changed before the product is
declared as Generally Available. Private Beta products are not covered by the Twilio Support Terms or
Twilio Service Level Agreement.
An Operation resource represents a push notification request that targets one or more recipients. When you send a notification, the API validates the input and returns an HTTP 202 Accepted response with an operationId in the response body. Use the operationId to monitor the status and delivery progress of the request.
As the Operation is processed, it generates a PushNotification with an associated pushNotificationId for each recipient. Each PushNotification then creates at least one delivery attempt for each provider (FCM or APNs) that is tried.
(information)
Info
Records are available for 7 days after creation. Requests for data older than 7 days may return incomplete results.
The Operation ID is an identifier that can be used to correlate all of the
resources created in a request.
Issue a GET request to the resource list location, using the Operation ID as a query parameter
to retrieve the resources that correlate with the Operation.
Represents the stats of a sending operation of one or many Push Notifications.
total is the total number of Push Notifications in the Operation.
To get the status for each Push Notification, fetch the resource with:
GET /PushNotifications/{pushNotificationId}.
recipients is the total number of recipients targeted in an Operation.
unaddressable is the number of recipients to which no sending attempts were made because
a valid token could not be found in the recipient's Device Registration set for the
Credentials or App provided.
scheduled is the number of Push Notifications that are scheduled to be sent by
Twilio in the future.
queued is the number of Push Notifications that are queued in Twilio for sending.
sent is the number of Push Notifications that have been sent by Twilio.
failed is the number of Push Notifications that failed during processing by Twilio.
Get Errors with GET /PushNotifications/Operations/{operationId}/Errors fore more detail.
canceled is the number of Push Notifications that were canceled via API request.
All notifications in the operation have been processed.
CANCELED
The operation was canceled.
Operation stats
The stats object in the response provides aggregated delivery metrics:
Field
Description
total
Total push notifications in the operation.
recipients
Total targeted recipients.
unaddressable
Recipients with no valid device token found.
scheduled
Notifications scheduled for future sending.
queued
Notifications queued for sending.
sent
Notifications sent to the provider.
failed
Notifications that failed during processing.
canceled
Notifications canceled via the API.
Fetch an Operation
GET https://comms.twilio.com/v1/PushNotifications/Operations/{operationId}
Retrieve the status and delivery statistics of a push notification operation by making an HTTP GET request to the Operation resource URI with the Operation ID.
The Operation ID is an identifier that can be used to correlate all of the
resources created in a request.
Issue a GET request to the resource list location, using the Operation ID as a query parameter
to retrieve the resources that correlate with the Operation.
Represents the stats of a sending operation of one or many Push Notifications.
total is the total number of Push Notifications in the Operation.
To get the status for each Push Notification, fetch the resource with:
GET /PushNotifications/{pushNotificationId}.
recipients is the total number of recipients targeted in an Operation.
unaddressable is the number of recipients to which no sending attempts were made because
a valid token could not be found in the recipient's Device Registration set for the
Credentials or App provided.
scheduled is the number of Push Notifications that are scheduled to be sent by
Twilio in the future.
queued is the number of Push Notifications that are queued in Twilio for sending.
sent is the number of Push Notifications that have been sent by Twilio.
failed is the number of Push Notifications that failed during processing by Twilio.
Get Errors with GET /PushNotifications/Operations/{operationId}/Errors fore more detail.
canceled is the number of Push Notifications that were canceled via API request.
The Operation ID is an identifier that can be used to correlate all of the
resources created in a request.
Issue a GET request to the resource list location, using the Operation ID as a query parameter
to retrieve the resources that correlate with the Operation.
Represents the stats of a sending operation of one or many Push Notifications.
total is the total number of Push Notifications in the Operation.
To get the status for each Push Notification, fetch the resource with:
GET /PushNotifications/{pushNotificationId}.
recipients is the total number of recipients targeted in an Operation.
unaddressable is the number of recipients to which no sending attempts were made because
a valid token could not be found in the recipient's Device Registration set for the
Credentials or App provided.
scheduled is the number of Push Notifications that are scheduled to be sent by
Twilio in the future.
queued is the number of Push Notifications that are queued in Twilio for sending.
sent is the number of Push Notifications that have been sent by Twilio.
failed is the number of Push Notifications that failed during processing by Twilio.
Get Errors with GET /PushNotifications/Operations/{operationId}/Errors fore more detail.
canceled is the number of Push Notifications that were canceled via API request.