---
title: "MCP tools: Security"
description: "The tools of the MCP server under Security. Risk assessment and sender trust: the policy that warns, holds and guards sending, the senders an inbox knows, held mail and the audit log."
url: https://doorman.fyi/docs/mcp/tools/security
markdown: https://doorman.fyi/docs/mcp/tools/security.md
area: "SDKs and tools"
section: "MCP server"
---

# MCP tools: Security

The tools of the MCP server under Security. Risk assessment and sender trust: the policy that warns, holds and guards sending, the senders an inbox knows, held mail and the audit log.

Source: https://doorman.fyi/docs/mcp/tools/security

## security_get

Tool:
```text
security_get
```

Operation [`security.get`](https://doorman.fyi/docs/reference/security.md#security-get): `GET /v1/security`

The account's policy: the thresholds on the risk score (low from 0, medium from 30, high from 60, critical from 85) at which mail is warned about or held, the guards on sending, and what this deployment does with it. An account that never chose starts on `balanced`. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

The tool takes no input.

Example call:
```json
{
  "name": "security_get",
  "arguments": {}
}
```

## security_update

Tool:
```text
security_update
```

Operation [`security.update`](https://doorman.fyi/docs/reference/security.md#security-update): `PATCH /v1/security`

Applies a preset with `level`, or changes single values; fields left out stay as they are. Every inbox without a policy of its own follows the account's. A change that loosens protection needs a console session unless the account allows its account keys to (403 `session_required`); a change that tightens it does not. `allowKeyManagement` can only be switched on from a console session. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool changes something; calling it again with the same input has no further effect.

**Input**
- `level` ("relaxed" | "balanced" | "strict", optional): Apply this preset's thresholds and guards. It also clears the per-label rules, unless `labels` is given with it.
- `warnAt` (integer | null, optional): Mail scoring at least this is delivered with a warning and is never answered automatically. Null means never. Example: `60`
- `holdAt` (integer | null, optional): Mail scoring at least this is held for the owner and kept from agents. Null means never. Not below `warnAt`. Example: `85`
- `labels` (object of "warn" | "hold", optional): The least that happens to mail carrying a label, whatever its score: `warn` or `hold`. Replaced as a whole; {} clears it. Example: `{"prompt_injection":"hold"}`
- `holdUnauthenticatedNewSenders` (boolean, optional): Hold mail from a sender the inbox has never dealt with when it does not authenticate as its domain.
- `modelAnalysis` (boolean, optional): Let a model read the content of mail the signals leave undecided. The text goes to the deployment's AI gateway, is not kept and is never used for training. Off: assessments rest on the deterministic signals alone.
- `replyGuard` (boolean, optional): Refuse an agent's reply into a thread that holds a flagged message: one this policy warns about or holds, by its score or a label, or one the owner marked unsafe (403 `risk_blocked`). A message stops counting once the owner marks it safe, or while its sender is trusted and it passed authentication. A console session is never refused.
- `recipients` ("any" | "known", optional): `known`: an agent may write only to senders the inbox trusts or knows, and to the account's own inboxes (403 `risk_blocked` otherwise). Having written to the inbox, or being named in a message, does not make a recipient known: answering a stranger takes a person, or trusting them first. `any`: no such limit. A console session is never refused.
- `sendApproval` ("off" | "apps" | "all", optional): Whose sends wait for the owner when a recipient is not one the inbox knows or trusts, nor one of the account's own inboxes. `apps`: a connected app's. `all`: an app's and an API key's. `off`: nobody's. A send that waits answers 202 with a held send, which the owner sends or discards; it expires unsent after 7 days. A console session is never held, and neither is mail an inbox rule generates. It applies whatever the deployment's `enforcement`, except `off`, where no record of senders is kept and nothing is held. No preset changes it. An account that never chose starts on `apps`.
- `allowKeyManagement` (boolean, optional): Let account keys loosen protection (trust a sender, raise a threshold, release held mail, approve a held send). Off by default, and only a console session can switch it on. Account scope only.
- `deepScan` (boolean, optional): Run every attachment, in both directions, through the deployment's malware engine. The bytes go to an isolated scanner that keeps nothing. Off: attachments are still checked by their structure. No effect where the deployment has no engine (`deepScanAvailable`).
- `linkSandbox` (boolean, optional): Open the most suspect links of a message in an isolated browser before the message is delivered, to see where they lead. The site a link points at sees a visit. Links that verify an address, sign in, accept an invitation or unsubscribe are never opened, and neither are an authenticated sender's links to its own site. No effect where the deployment has no sandbox.
- `unscannable` ("deliver" | "warn" | "hold", optional): The least that happens to mail carrying something that could not be checked (a locked archive, or a scan that did not finish): `deliver`, `warn` or `hold`.

Example call:
```json
{
  "name": "security_update",
  "arguments": {
    "level": "strict"
  }
}
```

## inboxes_security_get

Tool:
```text
inboxes_security_get
```

Operation [`inboxes.security.get`](https://doorman.fyi/docs/reference/security.md#inboxes-security-get): `GET /v1/inboxes/{inboxId}/security`

The policy in force for one inbox: its own when it has one, the account's otherwise (`inherited` says which). OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string): The inbox. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the path parameter `inboxId` |

Example call:
```json
{
  "name": "inboxes_security_get",
  "arguments": {
    "inboxId": "inb_01jc4q7w9k2m5n8p3r6t1v4x7z"
  }
}
```

## inboxes_security_update

Tool:
```text
inboxes_security_update
```

Operation [`inboxes.security.update`](https://doorman.fyi/docs/reference/security.md#inboxes-security-update): `PATCH /v1/inboxes/{inboxId}/security`

Starts from the policy in force for the inbox and applies the change; from then on the inbox no longer follows the account's policy. `allowKeyManagement` is the account's and is refused here. A change that loosens protection needs a console session unless the account allows its account keys to (403 `session_required`); a change that tightens it does not. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool changes something; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string): The inbox. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `level` ("relaxed" | "balanced" | "strict", optional): Apply this preset's thresholds and guards. It also clears the per-label rules, unless `labels` is given with it.
- `warnAt` (integer | null, optional): Mail scoring at least this is delivered with a warning and is never answered automatically. Null means never. Example: `60`
- `holdAt` (integer | null, optional): Mail scoring at least this is held for the owner and kept from agents. Null means never. Not below `warnAt`. Example: `85`
- `labels` (object of "warn" | "hold", optional): The least that happens to mail carrying a label, whatever its score: `warn` or `hold`. Replaced as a whole; {} clears it. Example: `{"prompt_injection":"hold"}`
- `holdUnauthenticatedNewSenders` (boolean, optional): Hold mail from a sender the inbox has never dealt with when it does not authenticate as its domain.
- `modelAnalysis` (boolean, optional): Let a model read the content of mail the signals leave undecided. The text goes to the deployment's AI gateway, is not kept and is never used for training. Off: assessments rest on the deterministic signals alone.
- `replyGuard` (boolean, optional): Refuse an agent's reply into a thread that holds a flagged message: one this policy warns about or holds, by its score or a label, or one the owner marked unsafe (403 `risk_blocked`). A message stops counting once the owner marks it safe, or while its sender is trusted and it passed authentication. A console session is never refused.
- `recipients` ("any" | "known", optional): `known`: an agent may write only to senders the inbox trusts or knows, and to the account's own inboxes (403 `risk_blocked` otherwise). Having written to the inbox, or being named in a message, does not make a recipient known: answering a stranger takes a person, or trusting them first. `any`: no such limit. A console session is never refused.
- `sendApproval` ("off" | "apps" | "all", optional): Whose sends wait for the owner when a recipient is not one the inbox knows or trusts, nor one of the account's own inboxes. `apps`: a connected app's. `all`: an app's and an API key's. `off`: nobody's. A send that waits answers 202 with a held send, which the owner sends or discards; it expires unsent after 7 days. A console session is never held, and neither is mail an inbox rule generates. It applies whatever the deployment's `enforcement`, except `off`, where no record of senders is kept and nothing is held. No preset changes it. An account that never chose starts on `apps`.
- `allowKeyManagement` (boolean, optional): Let account keys loosen protection (trust a sender, raise a threshold, release held mail, approve a held send). Off by default, and only a console session can switch it on. Account scope only.
- `deepScan` (boolean, optional): Run every attachment, in both directions, through the deployment's malware engine. The bytes go to an isolated scanner that keeps nothing. Off: attachments are still checked by their structure. No effect where the deployment has no engine (`deepScanAvailable`).
- `linkSandbox` (boolean, optional): Open the most suspect links of a message in an isolated browser before the message is delivered, to see where they lead. The site a link points at sees a visit. Links that verify an address, sign in, accept an invitation or unsubscribe are never opened, and neither are an authenticated sender's links to its own site. No effect where the deployment has no sandbox.
- `unscannable` ("deliver" | "warn" | "hold", optional): The least that happens to mail carrying something that could not be checked (a locked archive, or a scan that did not finish): `deliver`, `warn` or `hold`.

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the path parameter `inboxId` |

Example call:
```json
{
  "name": "inboxes_security_update",
  "arguments": {
    "inboxId": "inb_01jc4q7w9k2m5n8p3r6t1v4x7z",
    "level": "strict"
  }
}
```

## inboxes_security_reset

Tool:
```text
inboxes_security_reset
```

Operation [`inboxes.security.reset`](https://doorman.fyi/docs/reference/security.md#inboxes-security-reset): `DELETE /v1/inboxes/{inboxId}/security`

Removes the inbox's own policy, so it follows the account's again. A change that loosens protection needs a console session unless the account allows its account keys to (403 `session_required`); a change that tightens it does not. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: true`, `idempotentHint: true`, `openWorldHint: false`. The tool changes something; can remove something, or replace a secret that stops verifying at once; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string): The inbox. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the path parameter `inboxId` |

Example call:
```json
{
  "name": "inboxes_security_reset",
  "arguments": {
    "inboxId": "inb_01jc4q7w9k2m5n8p3r6t1v4x7z"
  }
}
```

## inboxes_senders_list

Tool:
```text
inboxes_senders_list
```

Operation [`inboxes.senders.list`](https://doorman.fyi/docs/reference/security.md#inboxes-senders-list): `GET /v1/inboxes/{inboxId}/senders`

Everyone the inbox has received mail from or written to, most recently heard from first, with what arrived, what the inbox sent them and the standing that follows: `trusted` or `blocked` by a sender rule, `known` once the inbox wrote to them or they sent 3 authenticated messages over 7 days without a flag, `new` otherwise. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string): The inbox. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `standing` ("trusted" | "known" | "new" | "blocked", optional): Only senders with this standing.
- `q` (string, optional): Keep the senders whose address or name contains this text, case-insensitively.
- `limit` (integer, optional): Page size, 1 to 100. Defaults to 50.
- `offset` (integer, optional): Rows to skip. Defaults to 0.

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the path parameter `inboxId` |
| `standing` | the query parameter `standing` |
| `q` | the query parameter `q` |
| `limit` | the query parameter `limit` |
| `offset` | the query parameter `offset` |

Example call:
```json
{
  "name": "inboxes_senders_list",
  "arguments": {
    "inboxId": "inb_01jc4q7w9k2m5n8p3r6t1v4x7z"
  }
}
```

## senderRules_list

Tool:
```text
senderRules_list
```

Operation [`senderRules.list`](https://doorman.fyi/docs/reference/security.md#senderRules-list): `GET /v1/sender-rules`

The account's sender rules, newest first: the addresses and domains the owner trusts or blocks, for the whole account or for one inbox. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string, optional): Only the rules that apply to this inbox alone. Omit for every rule of the account. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `standing` ("trusted" | "blocked", optional): Only trusted or only blocked.
- `q` (string, optional): Keep the rules whose address or domain contains this text.
- `limit` (integer, optional): Page size, 1 to 100. Defaults to 50.
- `offset` (integer, optional): Rows to skip. Defaults to 0.

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the query parameter `inboxId` |
| `standing` | the query parameter `standing` |
| `q` | the query parameter `q` |
| `limit` | the query parameter `limit` |
| `offset` | the query parameter `offset` |

Example call:
```json
{
  "name": "senderRules_list",
  "arguments": {}
}
```

## senderRules_create

Tool:
```text
senderRules_create
```

Operation [`senderRules.create`](https://doorman.fyi/docs/reference/security.md#senderRules-create): `POST /v1/sender-rules`

Trusts or blocks an address or a whole domain, for one inbox or the whole account. A rule for the same match in the same scope is replaced. An inbox's own rule wins over the account's, and an address wins over its domain. Trust counts only for mail that authenticates as the sender: a trusted name that fails authentication is treated as an impersonation. Mail from a blocked sender is refused. Trusting needs a console session unless the account allows its account keys to (403 `session_required`); blocking does not. The domain every account's inboxes share cannot be trusted as a whole. An account holds at most 2000 rules. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: false`, `idempotentHint: false`, `openWorldHint: false`. The tool changes something.

**Input**
- `match` (string): An address (`sam@example.com`) or a domain (`example.com`, which covers every address at it, not its subdomains). Example: `sam@example.com`
- `standing` ("trusted" | "blocked"): `trusted`: their authenticated mail is treated as low risk and replies to them are never guarded. `blocked`: their mail is refused. Trusting needs a console session unless the account allows its account keys to.
- `inboxId` (string, optional): Apply to this inbox only. Omit for every inbox of the account. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `note` (string, optional): A label for whoever reads the list later, at most 200 characters.

Example call:
```json
{
  "name": "senderRules_create",
  "arguments": {
    "match": "sam@example.com",
    "standing": "trusted"
  }
}
```

## senderRules_delete

Tool:
```text
senderRules_delete
```

Operation [`senderRules.delete`](https://doorman.fyi/docs/reference/security.md#senderRules-delete): `DELETE /v1/sender-rules/{senderRuleId}`

The sender goes back to the standing they earned. Removing a block needs a console session unless the account allows its account keys to (403 `session_required`); removing trust does not. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: true`, `idempotentHint: true`, `openWorldHint: false`. The tool changes something; can remove something, or replace a secret that stops verifying at once; calling it again with the same input has no further effect.

**Input**
- `senderRuleId` (string): The sender rule. Example: `snr_01jc5f1a2b3c4d5e6f7g8h9j0k`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `senderRuleId` | the path parameter `senderRuleId` |

Example call:
```json
{
  "name": "senderRules_delete",
  "arguments": {
    "senderRuleId": "snr_01jc5f1a2b3c4d5e6f7g8h9j0k"
  }
}
```

## inboxes_held_list

Tool:
```text
inboxes_held_list
```

Operation [`inboxes.held.list`](https://doorman.fyi/docs/reference/security.md#inboxes-held-list): `GET /v1/inboxes/{inboxId}/held`

The messages held for the owner under the security policy, newest first. Every caller that can read the inbox gets the stub: who sent it, when, and why it is held. The subject is added for a caller that may review held mail; the body and the attachments are never here. A held message is in no thread and in no other list until it is released. OAuth: requires mail:read.

- Offered to: A connected agent with an approval that covers `mail:read`. The default agent permissions cover it. With a key: any API key, or a console session.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string): The inbox. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `limit` (integer, optional): Page size, 1 to 100. Defaults to 50.
- `offset` (integer, optional): Rows to skip. Defaults to 0.

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the path parameter `inboxId` |
| `limit` | the query parameter `limit` |
| `offset` | the query parameter `offset` |

Example call:
```json
{
  "name": "inboxes_held_list",
  "arguments": {
    "inboxId": "inb_01jc4q7w9k2m5n8p3r6t1v4x7z"
  }
}
```

## messages_release

Tool:
```text
messages_release
```

Operation [`messages.release`](https://doorman.fyi/docs/reference/security.md#messages-release): `POST /v1/messages/{messageId}/release`

Delivers a held message: it is threaded as if it had just arrived and `message.received` fires, with `risk.action` `released`. Agents can read it from then on, so releasing needs a console session unless the account allows its account keys to (403 `session_required`). It stays flagged: the reply guard applies to its thread until the message is marked safe or its sender is trusted. A message that is not held answers 404. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: false`, `idempotentHint: false`, `openWorldHint: false`. The tool changes something.

**Input**
- `messageId` (string): The message. Example: `msg_01jc5a6g7h8j9k0m1n2p3q4r5s`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `messageId` | the path parameter `messageId` |

Example call:
```json
{
  "name": "messages_release",
  "arguments": {
    "messageId": "msg_01jc5a6g7h8j9k0m1n2p3q4r5s"
  }
}
```

## messages_discard

Tool:
```text
messages_discard
```

Operation [`messages.discard`](https://doorman.fyi/docs/reference/security.md#messages-discard): `POST /v1/messages/{messageId}/discard`

Moves a held message to the trash without ever delivering it. Nothing brings it back, and where the deployment erases it is erased 30 days later. A message that is not held answers 404. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: true`, `idempotentHint: false`, `openWorldHint: false`. The tool changes something; can remove something, or replace a secret that stops verifying at once.

**Input**
- `messageId` (string): The message. Example: `msg_01jc5a6g7h8j9k0m1n2p3q4r5s`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `messageId` | the path parameter `messageId` |

Example call:
```json
{
  "name": "messages_discard",
  "arguments": {
    "messageId": "msg_01jc5a6g7h8j9k0m1n2p3q4r5s"
  }
}
```

## messages_feedback

Tool:
```text
messages_feedback
```

Operation [`messages.feedback`](https://doorman.fyi/docs/reference/security.md#messages-feedback): `POST /v1/messages/{messageId}/feedback`

The owner's verdict on a delivered inbound message that was assessed. `safe` lifts the reply guard for it, stops it counting toward its thread's risk level and withdraws the flag it put on its sender; it needs a console session unless the account allows its account keys to (403 `session_required`). `unsafe` flags the sender, which keeps them from being known, stops automatic replies to the message and makes the reply guard apply to its thread. The score stays what Doorman concluded. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: false`, `idempotentHint: false`, `openWorldHint: false`. The tool changes something.

**Input**
- `messageId` (string): The message. Example: `msg_01jc5a6g7h8j9k0m1n2p3q4r5s`
- `verdict` ("safe" | "unsafe")

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `messageId` | the path parameter `messageId` |

Example call:
```json
{
  "name": "messages_feedback",
  "arguments": {
    "messageId": "msg_01jc5a6g7h8j9k0m1n2p3q4r5s",
    "verdict": "safe"
  }
}
```

## security_audit

Tool:
```text
security_audit
```

Operation [`security.audit`](https://doorman.fyi/docs/reference/security.md#security-audit): `GET /v1/security/audit`

Every change to what protects the account, newest first: policy changes, sender rules, and held mail released, discarded or marked. Entries say who did it and carry no mail content. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string, optional): Only the entries about this inbox. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `limit` (integer, optional): Page size, 1 to 100. Defaults to 50.
- `offset` (integer, optional): Rows to skip. Defaults to 0.

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the query parameter `inboxId` |
| `limit` | the query parameter `limit` |
| `offset` | the query parameter `offset` |

Example call:
```json
{
  "name": "security_audit",
  "arguments": {}
}
```

## security_preview

Tool:
```text
security_preview
```

Operation [`security.preview`](https://doorman.fyi/docs/reference/security.md#security-preview): `POST /v1/security/preview`

Evaluates one message (a stored one, a built-in sample, or text of your own) under the policy in force or a draft, and answers what would happen and what an agent would be given. A message of your own is judged as one that passed authentication unless `authenticated` is false. Nothing is stored, sent or changed, and no model is called. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: false`, `idempotentHint: false`, `openWorldHint: false`. The tool changes something.

**Input**
- `inboxId` (string, optional): Evaluate as this inbox: its senders and, without `policy`, its policy. Defaults to the message's inbox, or to the account's policy with no sender history. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `messageId` (string, optional): A stored inbound message of the account that was assessed. A held one needs a caller that may review held mail. Example: `msg_01jc5a6g7h8j9k0m1n2p3q4r5s`
- `sample` ("ordinary" | "phishing" | "prompt_injection" | "impersonation", optional): A built-in message: ordinary mail, a phishing attempt, an injection hidden from the reader, or an impersonation.
- `from` (string, optional): The sender of your own message. Defaults to a sender the inbox has never seen. Example: `stranger@example.net`
- `authenticated` (boolean, optional): Whether your own message passed authentication for its sender's domain. Defaults to true, so the content decides; false shows what a forged sender looks like.
- `subject` (string, optional)
- `text` (string, optional): The plain-text body of your own message.
- `html` (string, optional): The HTML body of your own message.
- `policy` (object, optional): A draft to evaluate under, applied over the policy in force. Omit to use the policy in force. Example: `{"level":"strict"}`
  - `level` ("relaxed" | "balanced" | "strict", optional): Apply this preset's thresholds and guards. It also clears the per-label rules, unless `labels` is given with it.
  - `warnAt` (integer | null, optional): Mail scoring at least this is delivered with a warning and is never answered automatically. Null means never. Example: `60`
  - `holdAt` (integer | null, optional): Mail scoring at least this is held for the owner and kept from agents. Null means never. Not below `warnAt`. Example: `85`
  - `labels` (object of "warn" | "hold", optional): The least that happens to mail carrying a label, whatever its score: `warn` or `hold`. Replaced as a whole; {} clears it. Example: `{"prompt_injection":"hold"}`
  - `holdUnauthenticatedNewSenders` (boolean, optional): Hold mail from a sender the inbox has never dealt with when it does not authenticate as its domain.
  - `modelAnalysis` (boolean, optional): Let a model read the content of mail the signals leave undecided. The text goes to the deployment's AI gateway, is not kept and is never used for training. Off: assessments rest on the deterministic signals alone.
  - `replyGuard` (boolean, optional): Refuse an agent's reply into a thread that holds a flagged message: one this policy warns about or holds, by its score or a label, or one the owner marked unsafe (403 `risk_blocked`). A message stops counting once the owner marks it safe, or while its sender is trusted and it passed authentication. A console session is never refused.
  - `recipients` ("any" | "known", optional): `known`: an agent may write only to senders the inbox trusts or knows, and to the account's own inboxes (403 `risk_blocked` otherwise). Having written to the inbox, or being named in a message, does not make a recipient known: answering a stranger takes a person, or trusting them first. `any`: no such limit. A console session is never refused.
  - `sendApproval` ("off" | "apps" | "all", optional): Whose sends wait for the owner when a recipient is not one the inbox knows or trusts, nor one of the account's own inboxes. `apps`: a connected app's. `all`: an app's and an API key's. `off`: nobody's. A send that waits answers 202 with a held send, which the owner sends or discards; it expires unsent after 7 days. A console session is never held, and neither is mail an inbox rule generates. It applies whatever the deployment's `enforcement`, except `off`, where no record of senders is kept and nothing is held. No preset changes it. An account that never chose starts on `apps`.
  - `allowKeyManagement` (boolean, optional): Let account keys loosen protection (trust a sender, raise a threshold, release held mail, approve a held send). Off by default, and only a console session can switch it on. Account scope only.
  - `deepScan` (boolean, optional): Run every attachment, in both directions, through the deployment's malware engine. The bytes go to an isolated scanner that keeps nothing. Off: attachments are still checked by their structure. No effect where the deployment has no engine (`deepScanAvailable`).
  - `linkSandbox` (boolean, optional): Open the most suspect links of a message in an isolated browser before the message is delivered, to see where they lead. The site a link points at sees a visit. Links that verify an address, sign in, accept an invitation or unsubscribe are never opened, and neither are an authenticated sender's links to its own site. No effect where the deployment has no sandbox.
  - `unscannable` ("deliver" | "warn" | "hold", optional): The least that happens to mail carrying something that could not be checked (a locked archive, or a scan that did not finish): `deliver`, `warn` or `hold`.

Example call:
```json
{
  "name": "security_preview",
  "arguments": {
    "sample": "prompt_injection",
    "policy": {
      "level": "strict"
    }
  }
}
```

## inboxes_heldSends_list

Tool:
```text
inboxes_heldSends_list
```

Operation [`inboxes.heldSends.list`](https://doorman.fyi/docs/reference/security.md#inboxes-heldSends-list): `GET /v1/inboxes/{inboxId}/held-sends`

The messages that wait for the owner before they leave the inbox, newest first: the sends the security policy kept (`sendApproval`) and the drafts written for the owner to send. The ones still waiting unless `status` says otherwise. Every caller that can read the inbox gets who each is to and where it stands; the subject and the text are added for a caller that may decide. An inbox has at most 50 sends the policy kept and 100 drafts waiting; one that nobody decides expires unsent after 7 days, a draft after 30. A connected app is not offered the list: it reads the held send it was answered with. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: any API key, or a console session.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

**Input**
- `inboxId` (string): The inbox. Example: `inb_01jc4q7w9k2m5n8p3r6t1v4x7z`
- `status` ("held" | "sent" | "discarded" | "expired", optional): Only held sends in this state. Defaults to `held`.
- `kind` ("held" | "draft", optional): Only the sends the policy kept (`held`) or only drafts (`draft`). Both when left out.
- `limit` (integer, optional): Page size, 1 to 100. Defaults to 50.
- `offset` (integer, optional): Rows to skip. Defaults to 0.

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `inboxId` | the path parameter `inboxId` |
| `status` | the query parameter `status` |
| `kind` | the query parameter `kind` |
| `limit` | the query parameter `limit` |
| `offset` | the query parameter `offset` |

Example call:
```json
{
  "name": "inboxes_heldSends_list",
  "arguments": {
    "inboxId": "inb_01jc4q7w9k2m5n8p3r6t1v4x7z"
  }
}
```

## heldSends_get

Tool:
```text
heldSends_get
```

Operation [`heldSends.get`](https://doorman.fyi/docs/reference/security.md#heldSends-get): `GET /v1/held-sends/{heldSendId}`

Where a held send stands: waiting, sent, discarded or expired. What it says is shown only to a caller that may decide. OAuth: requires mail:read.

- Offered to: A connected agent with an approval that covers `mail:read`. The default agent permissions cover it. With a key: any API key, or a console session.
- Annotations: `readOnlyHint: true`, `destructiveHint: false`, `idempotentHint: true`, `openWorldHint: false`. The tool reads only; calling it again with the same input has no further effect.

**Input**
- `heldSendId` (string): The held send. Example: `hsd_01jc5f1a2b3c4d5e6f7g8h9j0k`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `heldSendId` | the path parameter `heldSendId` |

Example call:
```json
{
  "name": "heldSends_get",
  "arguments": {
    "heldSendId": "hsd_01jc5f1a2b3c4d5e6f7g8h9j0k"
  }
}
```

## heldSends_approve

Tool:
```text
heldSends_approve
```

Operation [`heldSends.approve`](https://doorman.fyi/docs/reference/security.md#heldSends-approve): `POST /v1/held-sends/{heldSendId}/approve`

Sends the message as it was asked for, now: the limits, the plan's cap and the thread are checked at this moment, and `message.sent` fires as for any send. Its recipients become known to the inbox, as with any mail the inbox sends. It needs a console session unless the account allows its account keys to (403 `session_required`). A send that fails stays held and answers the error a send would. One that is no longer held answers 404. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: false`, `idempotentHint: false`, `openWorldHint: true`. The tool changes something; reaches outside the account: it sends mail or posts to a URL.

**Input**
- `heldSendId` (string): The held send. Example: `hsd_01jc5f1a2b3c4d5e6f7g8h9j0k`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `heldSendId` | the path parameter `heldSendId` |

Example call:
```json
{
  "name": "heldSends_approve",
  "arguments": {
    "heldSendId": "hsd_01jc5f1a2b3c4d5e6f7g8h9j0k"
  }
}
```

## heldSends_discard

Tool:
```text
heldSends_discard
```

Operation [`heldSends.discard`](https://doorman.fyi/docs/reference/security.md#heldSends-discard): `POST /v1/held-sends/{heldSendId}/discard`

Ends a held send without sending it and removes what it carried; `send.discarded` fires. Nothing brings it back. One that is no longer held answers 404. Recorded in the audit log. OAuth: not available to apps.

- Offered to: API keys only. A connected agent is never offered this tool. With a key: an account-scoped key or a console session; an inbox-scoped key gets 403 `forbidden`.
- Annotations: `readOnlyHint: false`, `destructiveHint: true`, `idempotentHint: false`, `openWorldHint: false`. The tool changes something; can remove something, or replace a secret that stops verifying at once.

**Input**
- `heldSendId` (string): The held send. Example: `hsd_01jc5f1a2b3c4d5e6f7g8h9j0k`

**Inputs that are not fields of the request body**

| Input | Sent as |
| --- | --- |
| `heldSendId` | the path parameter `heldSendId` |

Example call:
```json
{
  "name": "heldSends_discard",
  "arguments": {
    "heldSendId": "hsd_01jc5f1a2b3c4d5e6f7g8h9j0k"
  }
}
```
