steampipe plugin install aws

Table: aws_api_gateway_usage_plan - Query AWS API Gateway Usage Plans using SQL

The AWS API Gateway Usage Plans are a feature of Amazon API Gateway that allows developers to manage and restrict the usage of their APIs. These plans can be associated with API keys to enable cost recovery, as well as to control the usage of APIs by third-party developers. This ensures a smooth and controlled distribution of your APIs, protecting them from misuse and overuse.

Table Usage Guide

The aws_api_gateway_usage_plan table in Steampipe provides you with information about usage plans within AWS API Gateway. This table allows you, as a DevOps engineer, to query usage plan specific details, including associated API stages, throttle and quota limits, and associated metadata. You can utilize this table to gather insights on usage plans, such as plans with specific rate limits, the number of requests your clients can make per a given period, and more. The schema outlines the various attributes of the usage plan, including the plan ID, name, description, associated API keys, and associated tags for you.

Examples

Basic info

Explore the various usage plans associated with your AWS API Gateway. This can help you better manage and monitor your API usage, ensuring optimal performance and cost-effectiveness.

select
name,
id,
product_code,
description,
api_stages
from
aws_api_gateway_usage_plan;
select
name,
id,
product_code,
description,
api_stages
from
aws_api_gateway_usage_plan;

List the API gateway usage plans where quota ( i.e the number of api call a user can make within a time period) is disabled

Identify instances where the API gateway usage plans do not have a set quota, which indicates that there is no limit to the number of API calls a user can make within a certain time period. This might be useful in understanding potential areas of vulnerability or overuse in your system.

select
name,
id,
quota
from
aws_api_gateway_usage_plan
where
quota is null;
select
name,
id,
quota
from
aws_api_gateway_usage_plan
where
quota is null;

List the API gateway usage plan where throttle ( i.e the rate at which user can make request ) is disabled

Determine the areas in which the API gateway usage plan lacks a throttle feature, indicating that there are no restrictions on user request rates.

select
name,
id,
throttle
from
aws_api_gateway_usage_plan
where
throttle is null;
select
name,
id,
throttle
from
aws_api_gateway_usage_plan
where
throttle is null;

Schema for aws_api_gateway_usage_plan

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form, e.g. connection_name.
account_idtextThe AWS Account ID in which the resource is located.
akasjsonbArray of globally unique identifier strings (also known as) for the resource.
api_stagesjsonbThe associated API stages of a usage plan
descriptiontextThe description of a usage plan
idtext=The identifier of a UsagePlan resource
nametextThe name of a usage plan
partitiontextThe AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).
product_codetextThe AWS Markeplace product identifier to associate with the usage plan as a SaaS product on AWS Marketplace
quotajsonbThe maximum number of permitted requests per a given unit time interval
regiontextThe AWS Region in which the resource is located.
tagsjsonbA map of tags for the resource.
throttlejsonbThe request throttle limits of a usage plan
titletextTitle of the resource.

Export

This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.

You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh script:

/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- aws

You can pass the configuration to the command with the --config argument:

steampipe_export_aws --config '<your_config>' aws_api_gateway_usage_plan