Skip to main content
POST
/
api
/
community
/
link
/
:instance
Link groups
curl --request POST \
  --url https://api.example.com/api/community/link/:instance \
  --header 'Content-Type: <content-type>' \
  --header 'token: <token>' \
  --data '
{
  "communityJid": "<string>",
  "groupJid": [
    "<string>"
  ]
}
'

Documentation Index

Fetch the complete documentation index at: https://docs.ryzeapi.cloud/llms.txt

Use this file to discover all available pages before exploring further.

Auth: TokenAccount or TokenInstanceRate-limit: Global (100/min) • Idempotent: no

Description

Links one or more existing groups to a community. Each link has an internal 1s delay to avoid throttling from the WhatsApp server. Individual failures do not abort the operation, they go to the failed array.

Examples

Bulk-attaches 2 existing groups to the community 120363406289005073@g.us in a single call. The service applies an internal 1s delay between links to avoid throttling.
curl -X POST "https://ryzeapi.cloud/api/community/link/$Instance_Name" \
  -H "token: $Token_Instance" \
  -H "Content-Type: application/json" \
  -d '{
    "communityJid": "120363406289005073@g.us",
    "groupJid": [
      "120363406289005074@g.us",
      "120363406289005075@g.us"
    ]
  }'
Links a single group to the community. The groupJid array accepts 1 or more items, useful when you want to add subgroups one by one.
curl -X POST "https://ryzeapi.cloud/api/community/link/$Instance_Name" \
  -H "token: $Token_Instance" \
  -H "Content-Type: application/json" \
  -d '{
    "communityJid": "120363406289005073@g.us",
    "groupJid": ["120363406289005074@g.us"]
  }'

Success response

Returns the count in message (format "Linked N of M groups to community"), the linked array with the JIDs successfully linked, and failed with the ones that were not processed (invalid JID, group already linked to another community, or bot lacking permission). success is true when at least one group was linked.
200 OK
{
  "success": true,
  "message": "Linked 2 of 2 groups to community",
  "linked": [
    "120363406289005074@g.us",
    "120363406289005075@g.us"
  ],
  "failed": []
}
Partial success and total failure both return HTTP 200. Always check success + failed[] on the client to detect per-group errors.

Path parameters

instance
string
required
Instance name.

Headers

token
string
required
TokenAccount or TokenInstance.
Content-Type
string
required
application/json

Request body

communityJid
string
required
Community @g.us JID.
groupJid
string[]
required
Array of @g.us JIDs of the groups to link. At least 1 item.

Notes

  • A group already linked to another community lands in failed[], unlink it first via /unlink.
  • Limit of 50 subgroups per community. Extras fail silently.
  • The Announcements group already belongs to the community since creation and cannot be linked.
  • The bot must be admin of both the community and the group being linked.

Errors

HTTPMessage
400community jid is required
400group jid is required
400Instance is not connected to WhatsApp
500error parse community jid: <reason>
Envelope:
{
  "success": false,
  "error": { "message": "community jid is required" }
}

Next

Unlink groups

Remove groups from the community.

List subgroups

Confirm the linked subgroups.