I couldn't get clear documentation around how to get a bearer token for making management API calls using an API. I am able to get bearer token using gcloud commands and do an export but would like to get it programmatically using an API Call.
Any help related to this would be great.
Thanks
Solved! Go to Solution.
I was more referring to populating KVMs with required entries.
You can do that with this repo. https://github.com/apigee/devrel/tree/main/references/kvm-admin-api
Since Apigee X is inside of Google Cloud we don't need the Service Account Keys?
Well I wouldn't say "don't need." It depends on what you're doing. But, it's possible to specify a service account to use, when you deploy an API Proxy. And then subsequently outbound calls via ServiceCallout or HTTPTargetConnection can use that service account. (You don't need to bother, inside the proxy logic, about getting and caching a JWT, bearer token, and etc). Here is the documentation for this feature.
Here is what it looks like in the Apigee X UI: https://youtu.be/uylH5qZ_WJY