Handle WorkOS callback (browser redirect)
Auth
Handle WorkOS callback (browser redirect)
Called by the WorkOS/Okta provider in the browser after authorization. Exchanges the code with WorkOS (SSO first, then AuthKit fallback), upserts the user in MongoDB, and 302 redirects back to the frontend sign-in page so the SPA can finalize the session via POST callback.
GET
Handle WorkOS callback (browser redirect)