Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.
TypeScript agentaiai-agentsall-in-onecrmcrm-systememaillinearmcpmessagingnotesnotionofficerustslackslack-alternativestartupstartup-toolstypescriptworkspace
fix(auth): allow Google's sign-in origin in FusionAuth (#9139)
gbirman07d22ad1ac73
diff --git a/infra/stacks/fusionauth-instance/origins.ts b/infra/stacks/fusionauth-instance/origins.tsindex cf67f946fb..a1b7121ddf 100644--- a/infra/stacks/fusionauth-instance/origins.ts+++ b/infra/stacks/fusionauth-instance/origins.ts@@ -10,6 +10,9 @@ export const ALLOWED_ORIGINS = () => {'https://platform.openai.com','https://platform.claude.com','https://console.anthropic.com',+ // Google's sign-in pages send the browser back to FusionAuth, which reads+ // their origin and otherwise ends Google sign-in with `invalid_origin`.+ 'https://accounts.google.com',];switch (stack) {diff --git a/services/authentication_service/AGENTS.md b/services/authentication_service/AGENTS.mdindex 8c07cc1d85..e7c3ddae41 100644--- a/services/authentication_service/AGENTS.md+++ b/services/authentication_service/AGENTS.md@@ -104,6 +104,11 @@ inputs cannot select an agent, and ordinary user credentials remain unattributedcode redirects a link flow to its `original_url` with `email_link_error`(`admin_consent_required`, `cancelled`, `failed`); only the `AADSTS` codefrom `error_description` is logged, never the description.+- `/oauth/redirect` without a code answers "Sign-in failed" and logs+ `auth_handoff_failure=missing_code` with FusionAuth's error. `invalid_origin`+ ("Invalid origin uri <origin>") means the page that sent the browser to+ FusionAuth is missing from `infra/stacks/fusionauth-instance/origins.ts`;+ these failures carry no user id.## Relateddiff --git a/services/mcp_auth_proxy/README.md b/services/mcp_auth_proxy/README.mdindex 1e1262998b..20a9753cf0 100644--- a/services/mcp_auth_proxy/README.md+++ b/services/mcp_auth_proxy/README.md@@ -13,7 +13,8 @@ Two different values get checked during sign-in, by two different parties:header or, on a navigation, the `Referer`. FusionAuth checks it against theapplication's authorized origins (`infra/stacks/fusionauth-instance/origins.ts`)and fails with `invalid_request: Invalid origin uri` when it is not listed.- That list is for Macro's own apps that talk to FusionAuth directly.+ That list is for Macro's own apps that talk to FusionAuth directly, plus+ Google's sign-in pages, which send the browser back to FusionAuth.- The **redirect URI** is where the authorization code is delivered. The brokerchecks it, as described in the next two sections. FusionAuth only everredirects to the broker's own `/oauth/callback`.