AWS drives everything via API. Why don't they have a simple list of regions and endpoints?
Amazon Web Services (AWS) drives everything via API. You can start and stop servers, create new databases, and even ingest data from satellites. Frankly, I find it magical. But one thing I couldn't find, even after Googling and asking in various Slacks, was any way to get a current, up to date list of AWS regions in an API format.
Why do you care about the list of regions? Each region is an island, and for the most part services are self contained within regions (a few like Route53 and IAM are not).
Given this, you might want to:
OK, probably not that last one.
The options that I found to get the new regions via API:
Note that this is limited to the regions to which my AWS accounts has access (because I am pulling the data from the EC2 describe regions call using my credentials). I have access to all the standard regions, but not the special ones like GovCloud or the Chinese regions.
If, on the other hand you wanted to have access to all the regions to which you had access, you'd need to provide your own credentials. The easiest way to do that is to fork the app (you can do so here) and provide your own AWS keys.