# Mute someone

`POST https://rest.wordplus.cloud/wordplus/realtime/calls/{name}/mute`

Turns off the microphone, camera or screen of someone in a group call, as a host does. They may turn it on again: to
keep them quiet, remove them, or give them a token that does not publish.

In the packages: `realtime.call( name ).mute( user, track )`.

## Parameters

| Name | In | |
|---|---|---|
| `name` (required) | path | The group call name, percent-encoded: `meeting:7` is `meeting%3A7`. |

## Request

```json
{
  "user": "43",
  "track": "microphone"
}
```

## Answer

Whether it was on.

```json
{
  "ok": true,
  "muted": true
}
```

## Refusals

- **400**: `bad_request`, `bad_room`: the request is not one the API takes. `reserved`: an event name kept for the room itself.
- **401**: `missing_signature`, `stale_signature` (a clock off by more than 5 minutes), `unknown_site`, `bad_signature` (a wrong secret, or a body or path other than the one signed).
- **403**: `not_included`: your plan does not include it.

## Examples

`wordplus()` (in Go `app.Request()`) signs and sends the request: https://docs.wordplus.cloud/api/signing/ has it in each language.

**curl**

```bash
wordplus POST '/wordplus/realtime/calls/meeting%3A7/mute' '{"user":"43","track":"microphone"}'
```

**Node**

```js
const { muted } = await wordplus('POST', `/wordplus/realtime/calls/${encodeURIComponent('meeting:7')}/mute`, { user: '43', track: 'microphone' });
```

**Python**

```python
muted = wordplus("POST", f"/wordplus/realtime/calls/{quote('meeting:7', safe='')}/mute", {"user": "43", "track": "microphone"})["muted"]
```

**PHP**

```php
$muted = wordplus('POST', '/wordplus/realtime/calls/'.rawurlencode('meeting:7').'/mute', ['user' => '43', 'track' => 'microphone'])['muted'];
```

**Go**

```go
answer, err := app.Request("POST", "/wordplus/realtime/calls/"+url.PathEscape("meeting:7")+"/mute", map[string]any{"user": "43", "track": "microphone"})
```

