oauth-2.0

Is there a raw Http request way of OAuth2ing with Google?


I'm trying to Oauth with react native. There aren't any libraries that work for free with Android, iOS, and Web, however Oauth2 is a pretty standard procedure. Seems like there should be a way to make a couple Http requests, configure some redirects, and receive an auth token but I'm having a hard time finding documentation for the procedure for Google.

Here's an example that shows the full OAuth2 procedure in Rust.

I've got the process to work on web using expo-auth-session but it's deprecated and losing support and instead of paying for a solution, I'd rather just implement it myself using some react native primitives.

Does Google have a documented way of authing with Http requests? If not, is there a security reason for why it can't be provided?


Solution

  • Here is the google docs for doing this - https://developers.google.com/identity/protocols/oauth2

    You can also try asking ChatGPT with this one, gives you a clear understanding of whats required