Rotate the email key of a site
rotate_site_email_key
Replaces the email key of a site with a new one, so the old key stops working at once and everywhere.
The preview gets the new key right away, but a published site keeps the old one until it is published again, so its emails fail until then, and the tool tells the client to remind you to publish right after. Anything outside Modulify that used the old key breaks until the new one is pasted in.
The new key is not returned, and get_site_email_key reads it. The tool tells the client to rotate only when a key has leaked or you ask, never as routine maintenance. Like get_site_email_key, it is refused while the site's own EMAIL_URL or EMAIL_PRIVATE_KEY secret keeps Modulify email off. It needs the Delete projects permission. See The email key.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
projectId |
string | Yes | The site id. |