Invalid grant issue Google OAuth2

Has anyone managed to resolve the invalid grant issue when trying to generate an access token using the code retrieved from the Google OAuth2 response?

Code preview: 4/0AY0e-g4eVWen0Waie-OqkA71fpv7vkbJZnDlM53UQWmRaIdW25O5Xue_7PuHxd3bTcrQ

Screenshot - 2021-06-04T123335.421

1 Like

Did you try this URL ?
Personnaly, I never put space in parameters. But I don’t know if this can broke something.

You can consider sending the request to a endpoint for testing and debugging


Try this

In addition your body should be a Json object for a post like you’ve shown. You’rs is in a query string format which won’t work. It tries to send a badly formed Json object which is unexpected and not needed. This is likely the badly formed request issue you’re experiencing.