Expo Google login

I'm using better-auth with Expo for Google social login.
In the socialProviders config, I see that Google requires both clientId and clientSecret, but as far as I understand, when using the Android client (for mobile), Google doesn't provide a clientSecret.

If I try to leave it as undefined, I get a type error.

socialProviders: {
  google: {
    clientId: process.env.GOOGLE_CLIENT_ID as string,
    clientSecret: ??? // ← what should I put here?
  },
},


Since I'm using Expo (and not a web app), is there a correct way to omit clientSecret? Or is there a workaround to bypass the type check?

Any advice appreciated!
Solution
Oh wait, if you’re authenticating in the expo app, you should get idToken and you should use id token auth instead.
Was this page helpful?