API Call to "users/login" endpoint fails with "connection refused" error

Dear OD Users and Python experts, I am trying to log-in to ONE DATA via Python + an API call to the “users/login” endpoint (using the requests package and a post request).
I am receiving the following error message:
HTTPSConnectionPool(host='xxxxxxxxxxxxxxxx.com', port=443): Max retries exceeded with url: /api/v1/users/login (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x7f19ce8a0fd0>: Failed to establish a new connection: [Errno 111] Connection refused')).

Has one of you seen this before and can maybe help me if the error could come from the ONE DATA API itself (too many open connections or something), or if my request might be wrong?. Thanks a lot for your help.

Hi Christian, can you show a small code sample? Are you using Python in Python Processors or OD Functions?

Hi,

maybe that is an issue with the ports. The ONE DATA reverse proxy listens on ports 80 (HTTP) and 443 (HTTPS) and forwards any request to the respective backend. Maybe the specified hostname is resolved to a different host from the Python processor. You could try to access the ONE DATA Core backend directly via its internal hostname, i.e. http://onedata-server:8080/api/v1/users/login (in docker-compose based deployments - for Kubernetes deployments this needs to be replaced with the service of the ONE DATA Core backend).

Bests,

Matthias

Thanks for your very helpful answers.
The problem could be detected and boiled down to what happens after the API call reaches the ONE DATA server. Investigating further routed us towards the email-registration step for new ONE DATA users and the problem could be resolved by updating the configuration of the ONE DATA mail server.