---
title: "Revoke a session using a signed email token"
method: POST
path: "/auth/sessions/revoke-via-email"
tags: ["Auth"]
---

# Revoke a session using a signed email token

`POST /auth/sessions/revoke-via-email`

## Request

- Base URL: `https://api.mnemom.ai/v1`
- URL: `https://api.mnemom.ai/v1/auth/sessions/revoke-via-email`
- Auth: none required

Consumes a signed token minted at email-send time by the new-device notification flow. Possession of the token is the auth factor — no existing session cookie is required, no MFA. Returns 200 on any verified-valid token even if the underlying sid is already revoked (idempotent, non-enumerating). Returns 400 on malformed, tampered, expired, or key-mismatched tokens. Public endpoint, rate-limited. See ADR-031.

## Request body

- object
  - `token` string, required: HS256-signed token from the new-device email link.

## Response `200`

Session revocation accepted (idempotent — 200 returned even if the session was already gone).

- object
  - `revoked_at` string, date-time, required

## Other responses

- `400`: Bad request
- `403`: Cross-origin write refused (`cross_origin_rejected`). A state-changing request that carries the browser session cookie must come from a first-party origin (`Origin`, or failing that `Referer`) and must not send a form-style body (text/plain, urlencoded, multipart) the operation does not declare. Bearer and API-key callers are never subject to this check.
- `429`: Rate-limit exceeded. The global per-IP limiter (100 requests/minute, applied to every `/v1/*` route) rejected this request. Back off until the window resets — `Retry-After` carries the cooldown in seconds and `X-RateLimit-Reset` the absolute reset time.
- `500`: Server error — request was well-formed but the server failed to fulfill it. Typically a downstream dependency (DB / RPC / external API) returned an unexpected error.

---

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