API Gateway Count Metrics per API Key

0

Customer would like to know if there is a CloudWatch metric, or other mechanism, to report on the number of requests against their AWS API Gateway per API Key. The goal is to distinguish how many requests are coming from each API Key.

2回答
1

Hi, @Adam R

You can create a usage plan in API Gateway and export a report (JSON / CSV) for each usage plan from there.
In the report, you can get the number of accesses for each associated API key.

profile picture
エキスパート
iwasa
回答済み 2年前
  • With the usage plan is there a way to query the data via API or just JSON/CSV export?

  • I was late in replying. sorry.
    In the Usage Plan, you just export.
    You can query using other services (eg Athena).

1

I created a solution that queries an API quota defined by a usage plan, publishes to CloudWatch and sends a notification if it exceeds a threshold. A description and link to code is available on Medium:

https://medium.com/@allenbrodjeski/monitoring-aws-api-gateway-quota-usage-188d440c9c44

回答済み 2年前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン