Topics
This section describes APIs to add devices to MPush and associate them with topics. Only clients (e.g. apps) should implement these APIs or use mobile SDKs.
Add Device
To register a new device token.
This API requires a JSON payload.
HTTP Request
POST https://app.mpush.cloud/api/tokens
Payload example to register a device to 3 topics:
Parameters
On success is returned an HTTP 200 and JSON like this:
Register
To register a device to one or more topics.
A topic can represent either a device or a list of devices, you can specify it through thesingle
parameter. If the specified topic doesn't exist it will be created.
This API requires a JSON payload.
HTTP Request
POST https://app.mpush.cloud/api/register
Payload example to register a device to 3 topics:
Parameters (JSON)
On success is returned an HTTP 200 and JSON like this:
Unregister
To unregister a device from one or more topics.
If the specified topic doesn't exist it will be ignored.
This API requires a JSON payload.
HTTP Request
POST https://app.mpush.cloud/api/unregister
Payload example to unregister a device from 2 topics (old version):
Payload example to unregister a device from 2 topics (new version):
Parameters (JSON)
On success is returned an HTTP 200 and JSON like this:
Unregister All
To unregister a device from all topics.
This API requires a JSON payload.
HTTP Request
POST https://app.mpush.cloud/api/unregister-all
Payload example to unregister a device from all topics:
Parameters (JSON)
On success is returned an HTTP 200 and JSON like this:
Last updated