---
title: "Toggle the global email opt-out flag"
method: PUT
path: "/v2/settings/users/{userId}/notification-preferences/email-global"
tags: ["Notification Preferences Api Service"]
---

# Toggle the global email opt-out flag

`PUT /v2/settings/users/{userId}/notification-preferences/email-global`

## Request

- Base URL: `https://app.metricool.com/api`
- URL: `https://app.metricool.com/api/v2/settings/users/{userId}/notification-preferences/email-global`
- Auth: none declared

## Path parameters

- `userId` integer, required

## Request body

- UpdateEmailGloballyOffRequest: Request to toggle the global email opt-out flag
  - `emailGloballyOff` boolean, required: When true, all EMAIL channel notifications are disabled regardless of per-event overrides

## Response `200`

Resolved notification preferences matrix after the update

- JsonOkResponseNotificationPreferencesDto
  - `metadata` object
  - `page` JsonPaging
    - `next` string
  - `data` NotificationPreferencesDto: Full resolved notification preferences matrix for the authenticated user
    - `events` NotificationEventPreferenceDto[]: Resolved matrix, one entry per event
      - `event` string: Event id
      - `channels` NotificationChannelPreferenceDto[]: Effective state per channel
        - `channel` string: Channel id
        - `enabled` boolean: Effective enabled state after applying the per-cell override, the global email opt-out and the event default
    - `emailGloballyOff` boolean: Global email opt-out flag; when true, every EMAIL channel is effectively disabled

---

[API](https://skmtc.dev/metricool/apis/metricool-api.md) · [All operations](https://skmtc.dev/metricool/apis/metricool-api/llms.txt) · [OpenAPI document](https://skmtc.dev/metricool/apis/metricool-api/revisions/cd0ca612fa01?raw)
