Keys / Postmark
POSTMARK_SERVER_TOKEN
The server API token your app sends email through one Postmark server with, in the X-Postmark-Server-Token header.
- Expires
- the docs don't say
- API
- read with the Servers API and an account token; no generate or delete
Get it
Create one on account.postmarkapp.com/servers. The steps aren't recorded yet.
Set it
POSTMARK_SERVER_TOKEN=...
No official Postmark library reads this variable. The Ruby gem's Mail handler reads POSTMARK_API_TOKEN; other apps pass the token in. Or keep it out of .env with keypin: keypin run -- npm run dev
Replace it
- Open the server, choose API Tokens and click Generate New.
- Deploy the new token everywhere that reads
POSTMARK_SERVER_TOKEN. - Check that nothing still uses the old token, then delete it from the same page.
Set rotate_every on the key in keypin.toml and a rotated date on its vault item, and keypin status shows when it's due.