Overview
This package provides a very simple API for retrieving the most up-to-date region list. The region info is pulled from the botocore Github project so this requires a network connection. The advantage to using botocore directly is that the region list is not reliant on the botocore version which is installed. This can be an issue if you are using system packages for example, which may get updates very infrequently and thus may be missing new regions.
Requirements
- requests
Installation
pip install aws-regions
Usage
There are two main functions in aws-regions. The first function will provide a list of regions based on the AWS partition. By default this is this public AWS partition:
from aws_regions.endpoints import get_regions
# Defaults to "aws" partition
regions = get_regions()
# "aws-cn" partition
cn_region = get_regions(partition='aws-cn')
The second function will return a list of all regions from all three partitions:
from aws_regions.endpoints import get_all_regions
all_regions = get_all_regions() # From aws, aws-cn and aws-us-gov
Issues/Enhancements
Please submit issues and requests to Github.
Contributing
Contributions to aws-regions are welcome and encouraged. See CONTRIBUTING for info on getting started.
License
Copyright (c) 2021 SUSE LLC.
Distributed under the terms of MIT license, see LICENSE for details.
Metadata
Release files for aws-regions 0.6.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| aws_regions-0.6.0.tar.gz | 74.6 kB | Without provenance | Details for aws_regions-0.6.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| aws_regions-0.6.0-py3-none-any.whl | Python 3 | none | any | Details for aws_regions-0.6.0-py3-none-any.whl |
Total release size: 80.6 kB
Release files / aws_regions-0.6.0.tar.gz
| Download URL | aws_regions-0.6.0.tar.gz |
|---|---|
| Size | 74.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ad3e894c96151a9c98adcdf6223fd78cee1545075ca2880a7b3732d14ebc8767
|
|
BLAKE2b-256 checksum How to use checksums |
540e116eb37860c5c599707b96442266230d04e912adb49391ae3a4b4bc85a14
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.3
|
Release files / aws_regions-0.6.0-py3-none-any.whl
| Download URL | aws_regions-0.6.0-py3-none-any.whl |
|---|---|
| Size | 6.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1f9d0b0b92a530649d6117a427c2fc589e3b37114ba189ea9884154699d7031a
|
|
BLAKE2b-256 checksum How to use checksums |
819800a56eb4d2ce65c3dd0c213ba89a0fb00938c38f2a1fe9bac106711d2876
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.3
|
Security for aws-regions 0.6.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.