Right, so my app is an electron app, and you can hook into the redirect. It’s still a little bit hacking the flow but not as bad as full browser automation
If you control the client, you can. Because when you get the redirect response, you then take the auth code that is included there, and you don’t follow the redirect.
Then you send the auth code to your backend instead.