Groups
Create and manage WhatsApp groups.
| Method | Path | Does |
|---|---|---|
| GET | /v1/sessions/{session}/groups | List groups |
| POST | /v1/sessions/{session}/groups | Create a group |
| GET | /v1/sessions/{session}/groups/{groupId} | Group details |
| DELETE | /v1/sessions/{session}/groups/{groupId} | Delete a group |
| POST | /v1/sessions/{session}/groups/{groupId}/leave | Leave a group |
| PUT | /v1/sessions/{session}/groups/{groupId}/subject | Rename |
| PUT | /v1/sessions/{session}/groups/{groupId}/description | Update description |
| POST | /v1/sessions/{session}/groups/{groupId}/participants/add | Add members |
| POST | /v1/sessions/{session}/groups/{groupId}/participants/remove | Remove members |
| POST | /v1/sessions/{session}/groups/{groupId}/admin/promote | Make admin |
| POST | /v1/sessions/{session}/groups/{groupId}/admin/demote | Remove admin |
Create a group
curl -X POST https://wp-rapidapi.retentionstack.agency/v1/sessions/SESSION_NAME/groups \
-H "Authorization: Bearer ak_live_YOUR_ACCOUNT_KEY" -H "Content-Type: application/json" \
-d '{"name": "Project updates", "participants": [{"id": "15551234567@c.us"}]}'Send messages to the group with its id (ending in @g.us) as chatId.
Adding members is rate-sensitive
Failures when adding members, even after several successes, come from WhatsApp's anti-spam protection, not from an API limit, and a triggered flag can log the session out. Space out adds instead of looping, check numbers with check-exists first, and do not re-add existing members. A number that is not on WhatsApp returns 404 and does not harm the session.
Was this page helpful?