garmin-connect-export icon indicating copy to clipboard operation
garmin-connect-export copied to clipboard

urllib.error.HTTPError: HTTP Error 403: Forbidden

Open emilybradley00 opened this issue 2 years ago • 7 comments

Having problems with the logging in process, errors as follows:

Connecting to Garmin Connect... Done. [ERROR] Server couldn't fulfill the request, url https://sso.garmin.com/sso/signin?service=https%3A%2F%2Fconnect.garmin.com%2Fmodern%2F&webhost=https%3A%2F%2Fconnect.garmin.com&source=https%3A%2F%2Fconnect.garmin.com%2Fen-US%2Fsignin&redirectAfterAccountLoginUrl=https%3A%2F%2Fconnect.garmin.com%2Fmodern%2F&redirectAfterAccountCreationUrl=https%3A%2F%2Fconnect.garmin.com%2Fmodern%2F&gauthHost=https%3A%2F%2Fsso.garmin.com%2Fsso&locale=en_US&id=gauth-widget&cssUrl=https%3A%2F%2Fstatic.garmincdn.com%2Fcom.garmin.connect%2Fui%2Fcss%2Fgauth-custom-v1.2-min.css&clientId=GarminConnect&rememberMeShown=true&rememberMeChecked=false&createAccountShown=true&openCreateAccount=false&displayNameShown=false&consumeServiceTicket=false&initialFocus=true&embedWidget=false&generateExtraServiceTicket=true&generateTwoExtraServiceTickets=false&generateNoServiceTicket=false&globalOptInShown=true&globalOptInChecked=false&mobile=false&connectLegalTerms=true&locationPromptShown=true&showPassword=true#, code 403, error: HTTP Error 403: Forbidden Requesting Login ticket...Traceback (most recent call last): File "./gcexport.py", line 1342, in main(sys.argv) File "./gcexport.py", line 1292, in main login_to_garmin_connect(args) File "./gcexport.py", line 536, in login_to_garmin_connect login_response = http_req_as_string(f'{URL_GC_LOGIN}#', post_data, headers) File "./gcexport.py", line 266, in http_req_as_string return http_req(url, post, headers).decode() File "./gcexport.py", line 238, in http_req response = OPENER.open(request, data=post) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 531, in open response = meth(req, response) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 641, in http_response 'http', request, response, code, msg, hdrs) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 569, in error return self._call_chain(*args) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 503, in _call_chain result = func(*args) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 649, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 403: Forbidden

emilybradley00 avatar Oct 24 '22 14:10 emilybradley00

The HTTP Error 403: Forbidden message tells that you are not allowed to login (I assume that your password is correct? As I get a 401 Unauthorized with a wrong password).

Hmm... Can you login to the web interface with the same credentials?

pe-st avatar Oct 27 '22 04:10 pe-st

Yep can login with the same username and password (on the normal garmin connect login interface and also when I follow the link that the error gives)!

emilybradley00 avatar Oct 27 '22 05:10 emilybradley00

I have the same issue 😐

meksiAziz avatar Oct 31 '22 13:10 meksiAziz

same here

gianni4711 avatar Oct 31 '22 18:10 gianni4711

now it works again

gianni4711 avatar Oct 31 '22 19:10 gianni4711

ahh I still get the same error. When I login following the link that comes up in the error I get this garmin error, could they have changed the links that are required at the start of the code? Screen Shot 2022-11-01 at 9 47 07 am

emilybradley00 avatar Nov 01 '22 01:11 emilybradley00

back working again!

emilybradley00 avatar Nov 06 '22 14:11 emilybradley00