What do we mean by 360 Degree API Testing and Monitoring?
Historically, testing would take place only at the GUI level, and only at the end of the development process. When a developer would finish their work they would hand it off to the QA team. The engineers had limited time so they would test the code at the highest level - the GUI. This would cover both the frontend and backend development.
In the age of Agile, testing must take place at a lower level, i.e at the API level. Developers can even do it themselves. API testing, because of “API contracts” can even be created before development is complete. This means developers can validate their code based on pre-written tests (aka Test Driven Development).
Continuous testing means testing our API’s both pre-production, and post production (shift right testing). Testing doesn’t stop once we hit production. An API going down can have a dramatic effect on your site and its functionality, so real continuous testing has to include API Monitoring.
360 API Testing and Monitoring with BlazeMeter
With BlazeMeter’s new Continuous Testing functionality, you can test and monitor your APIs throughout the entire SDLC. I’ll talk you through how to do it.
3 Easy ways to run API Tests in BlazeMeter
There are several easy ways to create an API Test with BlazeMeter
1. you can simply create it within the UI
2. Toggle to add your own script in Taurus
Now these tests can be data driven, if we look at the scenario level in the next screenshot data can be imported from a CSV file and variables can be defined at a scenario level to be used by all of the tests within the scenario.
Now we click Run Test.
You can see all your API test results here. You can also see more detailed reporting.
We can also look for the content of the response to validate that the data is correct within the API Test.
API Monitoring within BlazeMeter
Having an API down can be devastating to your business. We need to be able to understand not only “Is the API down” but also, is the vendor sticking to the SLA they supplied to us.
We don’t always have access to the 3rd party infrastructure, so we need a way to be alerted if that third party API is no longer available.
We can check this in the API Monitoring screen of the BlazeMeter platform.
You can click on the test itself within the application to look at the output.
Here we sent a request, got back a “200”, and we can see the details of the response, both for passed or failed API tests, as in the example below.
You can also enable the scheduler to easily run API Monitoring tests on a specific API at regular intervals.
BlazeMeter’s API Monitoring feature provides access to enterprise level reporting, so that you can continuously monitor and track and multiple reports, that can then easily be shared with other users in your workspace.
These reports show:
- Average response rate
- Success rate
- You can change the time frame to adjust the view
- You can also drill into the failures to better understand what the problem was.
- You can connect the monitoring features to your daily workflow solutions to be notified if an API goes down.
Current integrations include:
- AWS CodePipeline
- Ghost Inspector
You can also sign up for our webinar here that covers all the new features of the BlazeMeter Continuous Testing platform.