I'm using python to make 2 APIs communicate between them, i made tests and both APIs work fine on their own, the problem arises when i try to send a request to API A (made with flask) so A can pass the data to API B(made with django) and then return the result to A again.
When i try to test this endpoint, the response is:
HTTPConnectionPool(host='0.0.0.0', port=7000): Max retries exceeded with url: /verify?0 (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fa0b939df50>: Failed to establish a new connection: [Errno 111] Connection refused'))
The test file and the manual test fail in this way, if i make a request to API B with the url that API A is making it returns a ok message.
I'm thinking i'm missing something about the config in API B, but where? and what?
Brief Summary:
API A it's made in flask and run locally in a dock container
API B it's made with django and has has ALLOWED_HOSTS = ["*"] in the config file settings.py adn running locally too
When i make a request to API A to call API B, B never register any event in the console log but API B calling to API A the request goes thru succesfully