---
title: "Edit mails in Quarantine"
method: POST
path: "/api/v1/edit/qitem"
tags: ["Quarantine"]
---

# Edit mails in Quarantine

`POST /api/v1/edit/qitem`

Using this endpoint you can perform actions on quarantine items. It is possible to release emails from quarantine into to the inbox, or learn them as ham to improve Rspamd filtering. You must provide the quarantine item IDs. You can get the IDs using the GET method.

## Request body

- object
  - `items` object — contains list of quarantine item IDs to release or learn as ham
  - `attr` object — attributes for the action
    - `action` 'release' | 'learnham' — release - return email to inbox; learnham - learn as ham to improve filtering

## Response `200`

OK

- object
  - `log` unknown[] — contains request object
    - unknown
  - `msg` unknown[]
    - unknown
  - `type` 'success' | 'danger' | 'error'

## Other responses

- `401` — Unauthorized

## Changes

- **2026-02-03** `1f4ab48664a8` — 1 info
  - endpoint added
- **2020-06-07** `47523aca063a` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/mailcow/apis/mailcow-api/changes/api/v1/edit/qitem/post.md)

---

[API](https://skmtc.dev/mailcow/apis/mailcow-api.md) · [All operations](https://skmtc.dev/mailcow/apis/mailcow-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/mailcow/mailcow-api/revisions/ae01d1d7886a/schema)
