I wanted to implement a flow described in this question:
Authenticating with OAuth2 for an app *and* a website
Google solution for this requirement was described in here:
https://developers.google.com/identity/protocols/CrossClientAuth#offlineAccess
I followed this guide but unfortunately when I use the authorization code in backend to get access to the token and refresh the token from google, google throw this error:
{
"error": "invalid_request",
"error_description": "Missing parameter: redirect_uri"
}
redirect_uri
has no meaning for this situation because the client-side is android.
There is also some advice who they said use "postmessage" as redirect uri or use http://localhost as redirect uri or add server address in redirect URIs in your google app console, but none works for this flow.