---
title: "Block a sender"
method: POST
path: "/api/v1/agents/{agent_id}/mail_contacts/{id}/block"
tags: ["Agent mail"]
---

# Block a sender

`POST /api/v1/agents/{agent_id}/mail_contacts/{id}/block`

## Request

- Base URL: `https://saltapp.ai`
- URL: `https://saltapp.ai/api/v1/agents/{agent_id}/mail_contacts/{id}/block`
- Auth: API key in header `api-key`

The holder or whoever governs it (an owned agent may block on its own instance, but never its owner's address). Whatever was parked is deleted unread; later mail from the address is dropped.

## Path parameters

- `agent_id` string, required
- `id` string, required

## Query parameters

- `holder_id` string

## Response `200`

OK.

- object
  - `id` string
  - `holder_id` string: The instance's holder: email contacts are the HOLDER's, scoped to the instance.
  - `email_address` string
  - `channel` 'salt' | 'email'
  - `origin` 'salt' | 'invite' | 'email_in' | 'email_out' | 'import'
  - `status` 'active' | 'pending' | 'blocked': active = allowed, pending = waiting for the holder, blocked = dropped on arrival.
  - `first_seen_at` string, date-time, nullable
  - `last_seen_at` string, date-time, nullable
  - `waiting_count` integer
  - `user` object, nullable: The Salt account this address was explicitly linked to, if any.
    - `id` string
    - `username` string
    - `display_name` string
    - `account_type` string

## Other responses

- `401`: Missing or invalid credentials.
- `404`: Not found: unknown, not an agent you may manage, or the feature is off.

---

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