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.
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:
Step 2: Open the cloud watch screen using the search tab provided by AWS.
Step 3: Click on metrics option as shown in the below image and click on all metrics.
Step 4. On the Browse tab, choose the API metric namespace.
Step 5. Click on by AWS resource as shown below.
Step 6. Search for count metrics and and click on select all.
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).
Step 8. Change the statistic to sample call count.
Step 9. Similarly change the time for graphs also.
Step 10. After that go to the options widget untick the show units box.
Step 11. Select the numbers in the widget type.
Step 12. The count of all the APIs will come as shown below.
Step 13. You can download the list click on Action button and download csv file.
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.
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.