I’m integrating Google OAuth with Clerk in a Flutter app and encountering the invalid_client error: {"error":"invalid_client","error_description":"Client authentication failed (e.g., unknown client, no client authentication included, or unsupported authentication method). The requested OAuth 2.0 Client does not exist."}
Here’s what I’ve done so far: Created Two OAuth Client IDs in Google Cloud Console: Web Application Client ID: Used in Clerk Dashboard (Custom Credentials). Android Client ID: Used in clerk_config.dart.
Set Up Deep Linking: Configured pyop1://home as the Redirect URL in Clerk Dashboard.
Added deep link handling in AndroidManifest.xml and app code to navigate to the home page.
Verified Configuration:
1)The Web Application Client ID and Client Secret match in Google Cloud Console and 2)Clerk Dashboard. 3)The Android Client ID is used in clerk_config.dart. 4)The Redirect URL (pyop1://home) is configured in Clerk Dashboard and handled in the app.
Despite this, I’m still getting the invalid_client error.
Questions:
- What could be causing the invalid_client error?
- Are there any common pitfalls with Google OAuth + Clerk integration?
- How can I verify that the Redirect URL and Client ID/Secret are correctly configured?