REST API/Web Service Testing – Overview

This Tutorial provides an introduction about REST APIs and Web services

No comments

Automation is nothing but the use of software to perform a manual task.

Test Automation is the process of using specialized software for performing manual testing and verifying the results/outcomes to predicted results.

Hence, Webservice automation is just the use of some dedicated software to perform the web service testing.

Then, what is web service testing?

Webservice testing is testing the webservices in middle-ware layer of an application manually/automated to validate its functionalities.

What is the middle-ware layer? – as the name states, it lies between the front-end and back-end of an application. That means it has no front-end UI.

Web services are web-application components hosted in web for performing specified jobs. They can be instructed by anyone calling the application to perform its job and provide the results.

The simplest & best example is a weather webservice that provides the current weather. Anybody can call the service to ask for the weather and it will provide the information. There are millions of webservices available in the internet for public, private and paid use.

Some common real life examples of WebServices and APIs are given below.

  • Google Maps APIs
  • Flight booking and reservation API/Services
  • Hotel Booking APIs
  • Facebook and other social media APIs
  • Google APIs/Services for user authentication.

So back to our topic, web service testing is testing the assigned functionalities of a web service before it is hosted in web and used by anyone.

There are many tools – software – available in market that helps in testing webservices and automating them. The greatest challenge in testing services is as you expected, yes, it has no User Interface. But the tools available in the market really helps us to overcome this concern. They provide some better interface than plain XMLs.

The medium for communicating with the services is through XML transactions. The input is sent as XML request and output is XML response from service.

WebServices uses SOAP protocol for communication.

API stands for Application Programming Interface. It is similar but a lighter version of web services. APIs are mostly built on REST.

REST stands for Representational State Transfer. It is an architecture for building REST based APIs. Such APIs are called RESTFUL APIs.

APIs communication usually takes place in XML or JSON format and it uses HTTP protocol for communication.

APIs are similar to Web Services in the sense, they are built to perform a specific function and they can be called by any systems to perform the operation.

Representational State Transfer (REST) is an architectural style that specifies constraints, such as the uniform interface, that if applied to a web service induce desirable properties, such as performance, Scalability, and modifiability, that enableservices to work best on the Web.

The common tools available in market for Service/API testing are as follows.

  • SoapUI
  • Postman
  • SOAtest
  • SOAPSonar
  • Apigee
  • Swagger
  • Mule Console
  • REST-Assured

We will discuss more about the tools in the comings articles.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s