
How Group Messaging works
Create a group
To create a group, send a POST request to the group name with a list of registration IDs that will be part of that group. ADM returns the count of those registration IDs which were successful, as well as a list of any failed registration IDs.Request format
group_name acts as an identifier for all operations such as add, remove, or send downstream messages to the group. Be sure to save the group_name on your server, or associate it with a unique identifier on your server.
Keep these group_name requirements in mind:
- It’s made up of alphanumeric characters
- It does not include private or confidential information
Response format
A partially successful response looks like this:success field indicates 0, the group will not be created.
Add or remove registration IDs from a group
Use theadd operation to add registration IDs to a group, and the remove operation to remove registrations IDs from a group.
Here is an example of a request to add registration IDs to a group.
Request format
Response format
The response below indicates that 1 registration ID was successfully added to the group, andregId1 failed to be added.
Retrieve a list of registration IDs from a group
To retrieve a list of registration IDs from a group, send a POST request with the operation parameter set toretrieve.
Request format
Response format
Send downstream messages to group
Sending downstream message to a group is similar to sending messages to a topic. The difference is that for group-based messaging you replace"topic":"SomeTopic" with "group_name":"group_name", and change the URL to a group messaging URL.

