π¦ ClawHub
a2a-Market-Google-OAuth
by @luoqianchenguni-max
Handle Google OAuth login, account linking, and session bootstrap for A2A market users and operators. Use when implementing identity login endpoints, callbac...
TERMINAL
clawhub install a2a-market-google-oauthπ About This Skill
name: a2a-market-google-oauth description: Handle Google OAuth login, account linking, and session bootstrap for A2A market users and operators. Use when implementing identity login endpoints, callback verification, and secure token/session lifecycle.
a2a-Market Google OAuth
Create a stable OAuth integration shell for buyer and merchant sign-in.
Current status: publish-ready scaffold. Keep flows explicit and deterministic before full SSO hardening.
Scope
Suggested Project Layout
app/integrations/oauth/google_client.pyapp/interfaces/api/auth_routes.pyapp/application/services/session_service.pyapp/protocol/identity/user_identity_mapper.pyMinimum Contracts (MVP P0)
1.GET /auth/google/start builds state + redirect URL.
2. GET /auth/google/callback validates state and exchanges code.
3. upsert_identity(provider, provider_user_id, email) returns internal principal id.
4. create_session(principal_id) returns short-lived access token and refresh token.Security Baseline
state and nonce against server-side cache.Events
Implementation Backlog
Runtime Implementation
runtime/src/integrations/oauth/google-oauth-service.jsruntime/tests and npm test in runtime/.