Skip to main content

List all resources in an AWS account, all regions, all services(*). Writes JSON files for further processing.

(*) No guarantees for completeness. Use billing alerts if you are worried about costs.

PyPI https://github.com/JohannesEbke/aws_list_all/actions/workflows/tests.yaml/badge.svg

(Note that the build will break on some boto3 updates)

Usage

You need to have python (only python3 tested) as well as AWS credentials set up as usual.

Quick Start with virtualenv:

mkvirtualenv -p $(which python3) aws
pip install aws-list-all
aws-list-all query --region eu-west-1 --service ec2 --directory ./data/

Quick Start Output:

---------------8<--(snip)--8<-------------------
--- ec2 eu-west-1 DescribeVolumes Volumes
--- ec2 eu-west-1 DescribeVolumesModifications VolumesModifications
--- ec2 eu-west-1 DescribeVpcEndpointConnectionNotifications ConnectionNotificationSet
--- ec2 eu-west-1 DescribeVpcEndpointConnections VpcEndpointConnections
--- ec2 eu-west-1 DescribeVpcEndpointServiceConfigurations ServiceConfigurations
--- ec2 eu-west-1 DescribeVpcEndpoints VpcEndpoints
--- ec2 eu-west-1 DescribeVpcPeeringConnections VpcPeeringConnections
--- ec2 eu-west-1 DescribeVpcs Vpcs
--- ec2 eu-west-1 DescribeVpnConnections VpnConnections
--- ec2 eu-west-1 DescribeVpnGateways VpnGateways
+++ ec2 eu-west-1 DescribeKeyPairs KeyPairs
+++ ec2 eu-west-1 DescribeSecurityGroups SecurityGroups
+++ ec2 eu-west-1 DescribeTags Tags
!!! ec2 eu-west-1 DescribeClientVpnEndpoints ClientError('An error occurred (InternalError) when calling the DescribeClientVpnEndpoints operation (reached max retries: 4): An internal error has occurred')

Lines start with “---” if no resources of this type have been found, and start with “+++” if at least one resource has been found. “>:|” denotes an error due to missing permissions, other errors are prefixed with “!!!”,

Currently, some default resources are still considered “user-created” and thus listed, this may change in the future.

Details about found resources are saved in json files named after the service, region, and operation used to find them. They can be dumped with:

aws-list-all show data/ec2_*
aws-list-all show --verbose data/ec2_DescribeSecurityGroups_eu-west-1.json

How do I really list everything?

Warning: As AWS has over 1024 API endpoints, aws-list-all tries to increase your allowed number of open files See https://github.com/JohannesEbke/aws_list_all/issues/6

Restricting the region and service is optional, a simple query without arguments lists everything. It uses a thread pool to parallelize queries and randomizes the order to avoid hitting one endpoint in close succession. One run takes around two minutes for me.

More Examples

Add immediate, more verbose output to a query with --verbose. Use twice for even more verbosity:

aws-list-all query --region eu-west-1 --service ec2 --operation DescribeVpcs --directory data --verbose

Show resources for all returned queries:

aws-list-all show --verbose data/*

Show resources for all ec2 returned queries:

aws-list-all show --verbose data/ec2*

List available services to query:

aws-list-all introspect list-services

List available operations for a given service, do:

aws-list-all introspect list-operations --service ec2

List all resources in sequence to avoid throttling:

aws-list-all query --parallel 1

Release files for aws-list-all 0.9.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aws-list-all 0.9.2
File Size Uploaded
aws_list_all-0.9.2.tar.gz 66.5 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for aws-list-all 0.9.2
File Interpreter ABI Platform
aws_list_all-0.9.2-py3.10.egg Legacy Egg format - - Details
aws_list_all-0.9.2-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 224.2 kB

Release files / aws_list_all-0.9.2.tar.gz

Download URL aws_list_all-0.9.2.tar.gz
Size 66.5 kB
Tags Source
SHA-256 checksum
How to use checksums
5efd85caba36a12be38ba5d9a23bb9a59e92b2290f552eaf33311ab1e37efc67
BLAKE2b-256 checksum
How to use checksums
ce9a269c97a844a07981aebcbaf81aa2fa947bf60e57ca05ea379b0265240c03
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.8

Release files / aws_list_all-0.9.2-py3.10.egg

Download URL aws_list_all-0.9.2-py3.10.egg
Size 92.7 kB
Tags Egg
SHA-256 checksum
How to use checksums
d5b2c5700c5e778a9e70d263bb0ced54bee8b7c392e8cfe61436a1284b225756
BLAKE2b-256 checksum
How to use checksums
12e4933e1663136d2f2c882bd4978d13fefa533536b28b5827c2c0de3f26d151
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.8

Release files / aws_list_all-0.9.2-py2.py3-none-any.whl

Download URL aws_list_all-0.9.2-py2.py3-none-any.whl
Size 65.0 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
c98fa6ffb422c50ca517358f07d1ee7c32bcea9a1ed96cdb178288fd6265f4fc
BLAKE2b-256 checksum
How to use checksums
e1994f5576b372c3d0628493a42202cb076d4309124feaa7d71680d9c35233ad
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.8

Release history Release notifications | RSS feed

This release

0.9.2 This release

3 release files

0.9.1

2 release files

0.9.0

2 release files

0.8.0

3 release files

0.7.3

3 release files

0.7.1

3 release files

0.7.0

3 release files

0.6.1

3 release files

0.6.0

2 release files

0.5.0

2 release files

0.3.0

2 release files

0.2.0

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page