---
title: "Set correspondent policy mode"
method: PUT
path: "/v1/policy/mode"
tags: ["policy"]
---

# Set correspondent policy mode

`PUT /v1/policy/mode`

## Request

- Base URL: `https://api.openmail.sh`
- URL: `https://api.openmail.sh/v1/policy/mode`
- Auth: HTTP bearer

Set the filtering mode for one direction of a scope's policy, without touching rules. Inbox-scoped keys are rejected. A pod-scoped key may mutate its own pod or an inbox in that pod, never account-wide policy. Pod keys cannot set `none`.

## Query parameters

- `podId` string
- `inboxId` string

## Request body

- object
  - `mode` 'none' | 'allowlist' | 'inherit', required: `none` = no filtering; `allowlist` = only listed correspondents are permitted (empty allowlist denies all — fail closed); `inherit` = defer to the parent scope (pod, then account). Not valid at the account scope.
  - `direction` 'inbound' | 'outbound': `inbound` governs who may send to the inbox; `outbound` governs who the inbox may send to (enforced across To, Cc, Bcc, and Reply-To on every send path).

## Response `200`

The updated mode

- object: The updated mode

## Other responses

- `403`: The authenticating key is scoped and cannot manage policy
- `404`: Pod or inbox not found
- `422`: Invalid mode for the scope

---

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