Serve Google's OAuth callback on /api/email/oauth/callback

FeatureEmailService
Shipped
August 25, 2026 at 1:12 AM UTC
Author
Kamo
Commit
4c7abfd

The platform console needs an address to show an operator setting up the Google Workspace registration, the way VOIP has /api/voip/oauth/callback. The only email callback that existed was **************** shared by Microsoft 365, Google and Zoho through one configured redirect. Give Google its own, on the shorter path, and leave the other two where they are: a redirect URI lives in a vendor console, so repointing all three would have meant re-registering Entra and Zoho to move one. EmailOAuthCallbackController is a second door onto ProviderController's callback, not a second implementation — the result page, the state decoding and the token exchange stay in one place. The redirect is now chosen per provider, and because the token exchange has to replay whatever the authorization request sent, the callback reads the provider back out of the state it was handed.

All changes

Like what you see shipping?

Every one of these updates lands in your workspace automatically. Start free and watch it grow week after week.

Start Free ForeverView Pricing