Skip to content

Cloud Run deployment: invalid_token (401) on /mcp after successful OAuth #99

Description

@jeisysai

Deployed to Cloud Run following the official guide. OAuth flow completes successfully with Claude as MCP client, but all requests to /mcp return 401 invalid_token. Google tokeninfo returns 200 OK for the same access token.

Logs:
POST 401 https://[my-service]/mcp
INFO:httpx2:HTTP Request: GET https://oauth2.googleapis.com/tokeninfo?access_token=... "HTTP/1.1 200 OK"
INFO Auth error returned: invalid_token (status=401) middleware.py:196
INFO Issued new FastMCP tokens (rotated refresh) proxy.py:1986

Client: Claude (claude.ai)
Developer token access level: Analytics Access

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions