Request an email-address change
/v1/auth/me/emailStarts a change of the signed-in administrator's email to new_email. The current email stays in use until the change is confirmed. A confirmation link valid for 24 hours goes to the new address and a notice goes to the current one. A new request replaces any pending one. An administrator with a second factor enrolled must present a fresh X-Mfa-Step-Up-Token (401 with mfa.step_up_required or mfa.step_up_invalid otherwise); one without a factor omits it. Refuses with 400 when the address is the current one or the account signs in only through SSO and has no password (auth.email_change_sso_managed). An address another user already has gets the same answer as a free one and no link, so the request never says whether an address is registered; the change is refused at confirmation. Limited to 5 requests a minute.
Headers
x-mfa-step-up-tokenThe step-up token `POST /v1/auth/mfa/step-up` returned. Required when the administrator has a second factor enrolled; one with none omits it
Request body
application/json
new_emailstring Required The new email address to move the account to
Responses
application/json
data *MessageResponseDto
application/json
error *ApiErrorBodyDto
application/json
error *ApiErrorBodyDto
application/json
error *ApiErrorBodyDto
application/json
error *ApiErrorBodyDto
application/json
error *ApiErrorBodyDto
Rate limit
Returned object
curl -X POST "https://auth.canopy-io.com/v1/auth/me/email" \ -H "x-mfa-step-up-token: value" \ -H "Content-Type: application/json" \ -d '{ "new_email": "string" }'
{ "data": { "message": "string" } }
Tell us how we can improve this guide.