Stop the email notices from an email’s link
Opts a card out with the token of its emails’ stop link, without a key: n and t in the query (a mail program’s one-click POST, RFC 8058) or {"n", "token"} in the body.
/v1/notices/unsubscribe- Access
- Creates temporary data
- Client
- Local or server client
Parameters#
| Name | Location | Meaning |
|---|---|---|
nRequired | Query | Card number. |
tRequired | Query | The token of the stop link. |
Request examples#
curl -fsS -X POST "https://veil.rip/v1/notices/unsubscribe?n=CARD_NUMBER&t=TOKEN"Response#
The card’s number and on: false.
| Field | Type | Meaning |
|---|---|---|
n | integer | Card number. |
on | boolean | Always false. |
Response headers#
| Header | Value | Meaning |
|---|---|---|
Content-Type | application/json | Use the declared media type before choosing a parser. |
Date | HTTP date | Server time. Compare it with your clock when signing requests. |
Retry-After | integer seconds, on rate_limited or busy | Wait at least this long before retrying. Other 429/503 codes do not necessarily include it. |
Usage notes#
- The token is the server’s Ed25519 signature for the card’s number, so it works only for that card. The emails link to the page /notices/stop with the number and the token after the #, so they never reach a log; opening that page changes nothing until the person presses the button.
Errors#
API errors return an error object. Use error.code for program logic; error.message is English text for people and can change. Response and error guide
| HTTP | Code | Meaning and next step |
|---|---|---|
| 400 | invalid_parameter | A path, query or body field is missing, malformed or outside its accepted range. Correct the field named in |
| 403 | invalid_token | The stop link’s token is not the server’s signature for this card. Copy the whole link from the email, or opt out from the account page. |
Shared request errors
| HTTP | Code | Meaning and next step |
|---|---|---|
| 429 | rate_limited | An anonymous, signed-request or API-key allowance was exceeded. Wait at least |
| 500 | internal_error | An unexpected server error occurred. Internal details are not returned. Retry reads with bounded backoff. Check write results before sending a new signed operation. |
| 503 | busy | The application has reached a temporary concurrency or database limit. Wait |