# Silence all alerts

`PUT https://evohub.io/api/v1/silence`

Part of the [Uptime API](https://docs-dev.evohub.io/uptime.md) reference · operationId `setOrganizationSilence`.

Mutes every Uptime alert of the organization for `minutes` minutes
from now. Checks keep running and outages are still recorded; only
notifications stop. Sending it again replaces the end time.

Requires the `uptime:silence:write` scope.

## Authorization

Any one of:

- `bearerKey`
- `headerKey`

Where:

- `bearerKey`: HTTP Bearer — An EvoHub API key (`evohub_…`) as a bearer token.
- `headerKey`: API key in the header `X-API-Key` — An EvoHub API key (`evohub_…`).

## Request body (required)

Content type: `application/json`

Type: `object`

- `minutes` (integer, required, min 1): How long to stay silent, in minutes.

## Responses

### 200 — The organization's silence.

Content type: `application/json`

Type: `object`

- `data` (OrganizationSilence)
  - `org_id` (string)
  - `silenced_until` (string (date-time) | null): Alerts are muted until this time. `null` or past means not muted.
  - `updated_at` (string (date-time))

### 400 — The body is not JSON (`INVALID_JSON`), or `minutes` is missing or not above 0 (`VALIDATION_ERROR`).

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `MONITOR_NOT_FOUND`)
  - `message` (string, required, example `monitor not found`)
  - `request_id` (string)

### 401 — No API key was sent, or it is unknown, revoked or expired (`UNAUTHORIZED`).

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `MONITOR_NOT_FOUND`)
  - `message` (string, required, example `monitor not found`)
  - `request_id` (string)

### 403 — The key lacks the scope this endpoint needs (`FORBIDDEN`).

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `MONITOR_NOT_FOUND`)
  - `message` (string, required, example `monitor not found`)
  - `request_id` (string)

### 429 — Too many requests (`RATE_LIMITED`). Wait for `Retry-After` seconds.

Headers:

- `Retry-After` (integer): Seconds to wait before retrying.

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `MONITOR_NOT_FOUND`)
  - `message` (string, required, example `monitor not found`)
  - `request_id` (string)

### 500 — Something went wrong on EvoHub's side (`INTERNAL_ERROR`). Retry later.

Content type: `application/json`

Type: `Error`

- `error` (object, required)
  - `code` (string, required, example `MONITOR_NOT_FOUND`)
  - `message` (string, required, example `monitor not found`)
  - `request_id` (string)

## Example request

```bash
curl -X PUT 'https://evohub.io/api/v1/silence' \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer <TOKEN>' \
  -d '{
  "minutes": 60
}'
```
