Pushes messages to iOS devices. These messages are delivered through the proprietary channel of Alibaba Cloud Mobile Push. After the app on a device receives a message, it must handle subsequent actions, such as implementing business behaviors or creating local notifications.
Operation description
This API is deprecated. Use the advanced push API for more push capabilities. In that API, set the push platform DeviceType to iOS and the push type PushType to MESSAGE to achieve the same effect.
Before you use this API, review the billing methods and pricing for EMAS Mobile Push.
By default, this API sends messages only to online devices. If a device is offline, you can set the StoreOffline parameter. The push system then saves the message and automatically delivers it when the device comes back online.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
mpush:PushMessageToiOS |
none |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| AppKey |
integer |
Yes |
AppKey information. |
24780725 |
| Target |
string |
Yes |
Push target. Valid values:
|
ALL |
| TargetValue |
string |
Yes |
Set based on Target. Separate multiple values with commas. If the limit is exceeded, push multiple times.
|
all |
| Title |
string |
Yes |
The title of the message. |
my title |
| Body |
string |
Yes |
The content of the message. |
my body |
| StoreOffline |
boolean |
No |
Whether to store the message offline. StoreOffline is set to false by default. If stored, and the user is offline during the push, the message is sent again when the user comes online within the time-to-live (TTL). The default time-to-live (TTL) is 72 hours. |
true |
| JobKey |
string |
No |
The custom ID for the push Job. If JobKey is not empty, this field is included in the receipt log. For receipt logs, see Receipt Logs. |
123 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| MessageId |
string |
The message ID that identifies a push. |
501029 |
| RequestId |
string |
The request ID. |
9998B3CC-ED9E-4CB3-A8FB-DCC61296BFBC |
Examples
Success response
JSON format
{
"MessageId": "501029",
"RequestId": "9998B3CC-ED9E-4CB3-A8FB-DCC61296BFBC"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.