# How to check and change admin-only mode in a WhatsApp group

### Checking the current setting

Call **GET** to get group details. In the response, look for the `announcements` field:

* `"announcements": true` is present — only admins can send messages.
* The `announcements` field is absent — everyone can send messages.

API reference:\
[Get groups](https://whapi.readme.io/reference/getgroups)\
[Get group](https://whapi.readme.io/reference/getgroup)

#### Changing the setting

Call **PATCH /groups/{GroupID}** with this body:

```json
{
  "setting": "send_messages",
  "policy": "admins"
}
```

Set `"policy"` to `"admins"` to restrict messaging to admins, or `"anyone"` to let all participants write.

```bash
curl --request PATCH \
  --url https://gate.whapi.cloud/groups/{GroupID} \
  --header 'accept: application/json' \
  --header 'authorization: Bearer YOUR_API_TOKEN' \
  --header 'content-type: application/json' \
  --data '{
    "setting": "send_messages",
    "policy": "admins"
  }'
```

Your channel must be an admin in the group to change this setting.

API reference: [Update group setting](https://whapi.readme.io/reference/updategroupsetting)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://support.whapi.cloud/help-desk/groups/groups-other-questions/how-to-check-and-change-admin-only-mode-in-a-whatsapp-group.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
