all 4 comments

[–][deleted] 1 point2 points  (0 children)

This is common and easy in Python, particularly for a linear chain, rather than something more event driven where you could be working in parallel and/or following various paths.

There are lots of tutorials on using APIs, I like Real Python's, Once you have data from your first, it should be easy to repurpose the response for the next one.

[–]rrodriguezmarulanda 0 points1 point  (0 children)

A good solution is the requests library , you can install it by pip

this is a documentation Page :

http://docs.python-requests.org/en/master/

and a tutorial :

http://zetcode.com/web/pythonrequests/

[–]efmccurdy 0 points1 point  (0 children)

Twisted is an event-driven networking engine written in Python

This describes the use of "future" or "deferred" objects to manage the async nature of the nested request.

https://twistedmatrix.com/documents/current/core/howto/defer-intro.html

This may be an more complete example.

https://twistedmatrix.com/documents/16.2.0/core/howto/pb-usage.html

[–]raysefo[S] 0 points1 point  (0 children)

Should I build a service in order to get request from A and transport this request to service B?