I'm executing this on command line from command line app written in Node:
openapi2apigee generateApi petStore -s '/Users/rafaelpaz/Documents/python/mapping-api_0.0.3.yml' -d /Users/rafaelpaz/Documents/python -D
That basically connects to my google apigee account and generate some files to me locally. After generated the files(with connection still opened from the command line) on terminal I have to enter some inputs end press enter on my keyboard to each of those inputs in order to achieve what I want, which is to deploy those file to my google apigee account (not getting to much into this as it is outside the scope of the question). Here's what I'm talking about:
Would like to know if someone has an example of how to do this automatically on python, I mean entering all those inputs. I'll have a python web app, so this code will be inside an endpoint.
The easiest way to do this is via the calling shell. Where you're using Bash (as we discussed in the comments), you can use a literal heredoc, which feeds multiple lines of input into the process's stdin.
Firstly, a syntax example:
So this case: