WA.cr APP - API v2
  1. Groups
WA.cr APP - API v2
  • API v2 Documentation
    • Account
      • Get Account Info
      • Get Usage Statistics
      • Get Plan Limits
    • Authentication (OTP Verification)
      • Send OTP/Verification Code
      • Resend OTP
      • Verify OTP
      • Check OTP Status
      • List Authentication Templates
    • Comments
      • Get Comments
      • Add Comment
    • Contacts
      • List Contacts
      • Create Contact
      • Get Contact
      • Update Contact
      • Delete Contact
      • Batch Create Contacts
      • Batch Delete Contacts
    • Groups
      • List Groups
        GET
      • Create Group
        POST
      • Get Group
        GET
      • Update Group
        PATCH
      • Delete Group
        DELETE
      • Add Contacts to Group
        POST
      • Remove Contacts from Group
        DELETE
    • Messages
      • Send Text Message
      • Send Template Message
      • Send Media Message
      • Send Interactive Message
      • List Messages
      • Get Message
    • Sources
      • List Sources
      • Create Source
      • Get Source
      • Update Source
      • Delete Source
    • Statuses
      • List Statuses
      • Create Status
      • Get Status
      • Update Status
      • Delete Status
    • Templates
      • List Templates
      • Sync Templates from WhatsApp
      • Get Template
  1. Groups

Add Contacts to Group

POST
/groups/1/contacts
Add multiple contacts to a group. Contacts that are already in the group will be skipped (not duplicated).

Authentication#

Required Scope: groups:write

Path Parameters#

ParameterTypeDescription
idintegerRequired. The group ID to add contacts to

Request Body#

FieldTypeRequiredValidationDescription
contact_idsarrayYesmin:1, each must be integer and exist in contacts tableArray of contact IDs to add

Behavior#

Each contact's group_id JSON array is updated to include this group ID
Contacts already in the group are silently skipped (not counted in contacts_added)
All contacts must belong to the same tenant, otherwise a validation error is returned

Response#

Success (200 OK): Returns the group ID and count of contacts actually added.

Response Data#

FieldTypeDescription
group_idintegerThe group ID
contacts_addedintegerNumber of contacts newly added (excludes already-in-group)

Error Responses#

StatusCodeDescription
404NOT_FOUNDGroup not found
422VALIDATION_ERRORValidation failed (missing contact_ids, invalid IDs, contacts not belonging to tenant)
500INTERNAL_ERRORFailed to add contacts to group

Validation Error Messages#

FieldMessage
contact_idsContact IDs are required / Contact IDs must be an array
contact_ids.*One or more contact IDs do not exist

Request

Authorization
Bearer Token
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
or
Header Params

Body Params application/json

Examples

Responses

🟢200
application/json
Successful response
Body

Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/groups/1/contacts' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "contact_ids": [
        123,
        124,
        125
    ]
}'
Response Response Example
{}
Modified at 2026-02-25 01:06:20
Previous
Delete Group
Next
Remove Contacts from Group
Built with