Skip to content

Feat/unified google oauth and connectors - #22

Merged
Miguel-DevOps merged 6 commits into
mainfrom
feat/unified-google-oauth-and-connectors
Nov 5, 2026
Merged

Miguel-DevOps merged 6 commits into
mainfrom
feat/unified-google-oauth-and-connectors

Conversation

@Miguel-DevOps

Copy link
Copy Markdown
Contributor

This pull request introduces a unified Google OAuth 2.0 authentication and token management system, simplifying credential handling for Google Ads, GA4, GTM, and YouTube integrations. It removes all references to the deprecated Google Ads developer token, adds an interactive CLI wizard for credential renewal, and implements hierarchical credential resolution. The changes also update documentation, environment variables, and add automated token management with proactive refresh and caching.

Unified Google OAuth and Token Management:

  • Added GoogleTokenManager for automatic access token caching, proactive refresh before expiry, and invalidation on HTTP 401 responses, supporting all Google connectors. (src/agency_analytics/google_auth.py)
  • Implemented hierarchical credential resolution: client-specific OAuth keys are used first, falling back to global agency keys, and finally legacy connector-specific variables. (src/agency_analytics/google_auth.py, src/agency_analytics/client_config.py) [1] [2] [3]

CLI and Developer Experience Improvements:

  • Added multitenant-elt auth google CLI command and make auth-google Makefile target for an interactive Google OAuth credential renewal wizard, supporting both global and per-client credentials. (src/agency_analytics/cli.py, Makefile) [1] [2] [3] [4]
  • Updated .env.example and documentation to reflect the new Google OAuth environment variables and credential flow, and removed all references to the deprecated GOOGLE_ADS_DEVELOPER_TOKEN. (.env.example, README.md) [1] [2] [3] [4]

Dependency and Compatibility Updates:

  • Added google-auth as a required dependency in pyproject.toml to support the new OAuth flow and token management.

These changes modernize Google integration authentication, reduce manual credential management, and ensure future compatibility as Google sunsets developer tokens.

@Miguel-DevOps
Miguel-DevOps merged commit 99c5478 into main Nov 5, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant