Is there any way to extract all API proxies with their target endpoint configuration ?

Hello,


My use case is: to extract all proxies endpoints along with their target endpoint details. currently management api only list all proxies but doesn't share target config and there is only 1 way to do that is going 1 api proxy at a time.

In our system we have 700 proxies and we have to consolidate / refactor them, going one by one will not help, any suggestions would really help.

0 2 255
2 REPLIES 2

That is exactly why having functionally complete Management API is an advantage.

You can easily create a bash script (or any other preferred scripting/programming language) to automate this [or other] operation.

After you fetch the list of all proxies, you can then use fork features of your language to batch target configuration requests, if you're worried about waiting for 700+1 total request processing time.

If you want a good starting point with Apigee mAPI and bash script, you can look at this script: https://github.com/yuriylesyuk/eco/blob/master/eco.sh.

Yup.

If you prefer nodejs to bash, you can try following the examples in this repo, to "crawl" the list of proxies. You will need to take care to examine... only the latest revision of the proxy, or maybe only deployed revisions of proxies. (Some people keep >100 revisions of a proxy in their Apigee orgs, I hope you're not one of those people!)