How to Get the Count of API is Being Called in Aws Using Cloud Watch — Wakeupcoders

REST API’s are one of the common things which are being used in every software industry. It takes very less cost and it's very much scalable. In earlier days developing a REST API was still a tedious task because from scratch we need to develop the routes, connectivity with the database, debugging, improvements, server maintenance, and matrices, There are a lot many things required to perform while creating an API.

cloud watch
AWS API Gateway

Nowadays, Thanks to API gateway of AWS that can perform all these activities with just one click. But in this blog, we will see how to get the count of API’s are being called, Aws Using Cloud Watch, and Indirectly how to properly check the matrices of API gateway of AWS. Let’s get started.

Below are the steps which are required to perform the above action.

Step 1: Login with your AWS console. As image is being shown below:

AWS console login

Step 2: Open the cloud watch screen using the search tab provided by AWS.

Opening cloud watch UI

Step 3: Click on metrics option as shown in the below image and click on all metrics.

Cloud watch metrics UI

Step 4. On the Browse tab, choose the API metric namespace.

Step 5. Click on by AWS resource as shown below.

AWS Resource

Step 6. Search for count metrics and and click on select all.

API Gateway AWS

Step 7. Go to graphed metrics change the time period to 5 minutes(Its up to you of what time period data you, maximum you can get one month data).

graphed metrics of AWS cloud watch

Step 8. Change the statistic to sample call count.

AWS cloud watch metrics

Step 9. Similarly change the time for graphs also.

AWS cloud watch

Step 10. After that go to the options widget untick the show units box.

cloud watch metrics option

Step 11. Select the numbers in the widget type.

AWS Metrics cloud watch

Step 12. The count of all the APIs will come as shown below.

AWS cloud watch console call count

Step 13. You can download the list click on Action button and download csv file.

AWS cloud watch console

So finally in this way we can get the number of times a API is being called in a AWS API gateway. Its quiet easy in AWS rather than creating a REST API from scratch and developing a API hit counting feature.

Let’s wind up:

We hope this information is helpful for you and enjoyed reading. If it is so you can share this blog with others so that it can help others as well.

contact us now (wakeupcoders)

If you are having any feedback or looking a way to connect with us.

Let’s connect together www.wakeupcoders.com/contact & think beyond everything.

Thanks to the Wakeupcoders Team: For thinking beyond everything

Purnima Sinha (author), Narayan Jha (editor), Anjali Jha (digital marketing)

--

--

Wakeupcoders - Digital Marketing & Web App Company
Wakeupcoders - Digital Marketing & Web App Company

Written by Wakeupcoders - Digital Marketing & Web App Company

We make your business smarter and broader through the power of the internet. Researcher | Web developer | Internet of things | AI | www.wakeupcoders.com

Responses (2)