Replace the email domain
Moves the app’s email sending to a different domain it already owns.
The current domain is left in place until the new one verifies, so a domain that was already sending keeps sending while DNS propagates. That only holds if it was sending: replacing a domain whose own setup never finished leaves you with no working sender until the new one verifies. During the changeover List email domains returns both.
The new domain has the same requirements as Enable email sending for a domain: connected, ready, and different from the current one. Sending the domain already in use is a 400.
This works only when exactly one email domain is set up. If a previous replacement is still in flight you get a 400, so let it finish or remove one first.
This endpoint is limited to 10 requests per minute.
configuration_status moves through pending_dns_configuration, pending_user_dns_configuration, pending_domain_verification and then active. The three failed_ values mean setup stopped and you can retry with Retry email domain setup. Only active sends mail.Authorizations
Personal API key.
Path Parameters
ID of the app whose email domains you want to work with.
Body
Request to replace email domain with a new one.
Domain to move to. It has to be connected to this app and different from the current one.
"mail.example.com"
Name recipients see in the From line.
"Nordwind Furniture"
Address mail is sent from once the new domain verifies.
"no-reply@mail.example.com"
Response
The new domain's setup started. The old one keeps sending until it verifies.
Response for replacing email domain.
The domain being moved to.
"mail.example.com"
Where the new domain's setup got to. The old one keeps sending until this reads active.
"pending_domain_verification"
ID of this app's email configuration. It identifies the configuration, not the individual domain.
"68b1c0d4e7b91d003c45a1f2"
true when you brought the new domain yourself, false when it was bought through Base44.
false
Records to publish for the new domain.