Fix the address on an account that hasn't verified it yet, and send a new verification link.
POST/v1/auth/change-emailTry it
Session token
Changes the email address on your account before it's verified — to fix a typo, or to replace a GitHub noreply address that can't receive mail — and sends a new verification link to the new address.
Note
Requires a session JWT — a dashboard session or an stx login token. API keys are rejected with 401. Any plan. Only for accounts whose email isn't verified yet.
Every verification link sent earlier stops working, so a link that went to the mistyped address can't verify the account. A verified address can't be changed here.
Request Body
NameDescription
email:stringbodyRequired
The new address, up to 320 characters. Surrounding spaces are trimmed. Any other key is a 400 validation_error.
Response — 200 OK
NameDescription
email:stringbody
The address now on the account.
verificationSent:booleanbody
Whether the new verification email went out. The address is changed either way; when this is false, resend the link from the dashboard.
Error Responses
400 Bad Request
email_unchanged — the address is already the one on the account (compared without case). Resend the verification link instead:
json
{
"error": {
"code": "email_unchanged",
"message": "That is already the address on this account. Resend the verification link instead.",
rate_limited — over 5 requests to this endpoint from your account within an hour, counting ones that failed. Each change sends an email. The response has a Retry-After: 3600 header:
json
{
"error": {
"code": "rate_limited",
"message": "Too many email changes. Try again in an hour.",