---
title: "Unsubscribe"
method: POST
path: "/api/email/unsubscribe"
tags: ["Email"]
---

# Unsubscribe

`POST /api/email/unsubscribe`

## Request

- Base URL: `https://api.earmarkiq.app` (the document declares no server; this is the origin it was published from)
- URL: `https://api.earmarkiq.app/api/email/unsubscribe`
- Auth: none declared

Record a marketing-email opt-out.

Public and unauthenticated by design: the earmarkiq.app/unsubscribe
page POSTs the HMAC-signed token from the email's unsubscribe link,
and the recipient may not have an account at all. The token is the
authorisation — it can only have come from an email we sent to that
address, so nobody can unsubscribe an address they don't receive
mail for. Affects category="marketing" sends only; transactional
mail is never filtered.

## Request body

- UnsubscribeRequest
  - `token` string, required

## Response `200`

Successful Response

- UnsubscribeResponse
  - `status` string, required

## Other responses

- `422`: Validation Error

---

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