mrkgnao: Thank you. Just to be certain I tried and it did not work.
Sude: POSTing the values to
https://login.gog.com/login_check is not enough. You still need to follow redirect url that you get as response to the POST.
https://login.gog.com/login doesn't give a proper token, or at least it didn't give one when I was implementing the login for LGOGDownloader.
I use
https://auth.gog.com/auth?client_id=<span class="bold">ID_NUMBER_HERE</span>&redirect_uri=https%3A%2F%2Fwww.gog.com%2Fon_logi n_success&response_type=code&layout=default to get the token for lgogdownloader
I think you can use a random number as the id number. For lgogdownloader I just find the auth url from GOG front page and follow it.
Thank you, Sude! And thank you, Pyron, for the initial suggestion.
With your additional information, I succeeded in logging in.
Apparently, I had got it all wrong. I was under the impression that OAuth was needed for logging in, while I now understand that it is needed only for accessing the API (which I don't need).
I managed to log in, get my library listing, get game info for one game, and get file properties for one installer and a few bonuses, so now I just need to automate the whole process and we will have an ongoing record of all changes to all downloadable files (
for the games I own).
Expect MaGog 4.0.0 sometime in January/February.