Web APIs

Sangeevan Siventhirarajah
4 min readOct 24, 2020

--

Web API is an application programming interface for the Web. API is a kind of interface which have a set of functions. These set of functions will allow programmers to get some specific features or the data of an application. Web API can be accessed over the web using the HTTP protocol. Basically it’s a web development concept. It is a framework to create and develop HTTP based RESTFUL services. Web API can be used in a web server or a web browser. Web API can be developed by using different technologies such as java, ASP.NET, etc. Web API is the enhanced form of the web application to provide services on different devices like laptop, mobile, and others.

Main reason for using the web API is to develop a platform agnostic solution and integration with others. A platform agnostic solution will work same way as on mobile app as well as on web browser. This will eliminate the need for separate development and support team for mobile app and web based system. This will also reduce development cost and man hours. Providing web API will enable you to integrate with third-party.

A server side web API is an automatic interface comprising of at least one openly presented endpoints to a defined request response message system, ordinarily communicated in JSON or XML, which is uncovered through the web most regularly by means of a HTTP based web server. Mashups are web applications which combine the use of multiple server-side web APIs. Webhooks are server side web APIs that accept input as a Uniform Resource Identifier (URI) that is intended to be utilized like a remote named pipe or a sort of callback such that the server acts as a client to dereference the provided URI and trigger an event on another server which handles this event thus providing a type of peer-to-peer IPC.

Endpoints are significant parts of interacting with server side web APIs, as they determine where assets lie that can be accessed by third party software. Typically the access is through a URI to which HTTP requests are posted, and from which the response is consequently anticipated. Endpoints should be static, otherwise the functionalities of the software can’t be ensured. If the location of a resource changed then previously written software will break, as the required resource can no longer be found at the same place.

Client side web API is a programmatic interface to extend functionality within a web browser or other HTTP client. Originally these were most commonly in the form of native plug-in browser extensions however most newer ones target standardized JavaScript bindings. Web APIs use a well known protocol called HTTP. Each time load something in browser, chances are that sending request and receiving the response via HTTP. HTTP requests use methods like GET, POST, PUT, HEAD, DELETE, PATCH and OPTIONS.

While considering some examples for web APIs: YouTube API Allows to display videos on a web site, Twitter API Allows to display Tweets on a web site, Uber cabs can be booked from Google maps, Facebook API Allows to display Facebook info on a web site. One common API usage is come across on a daily basis is weather data. Another prominent example of API usage is the log in using Facebook / Twitter / Google / GitHub. In the payment gateways pay with PayPal also another use of API. Google APIs allow communication with Google Services and their integration to other services. Examples of these include Search, Gmail, Translate or Google Maps. Third-party apps can use these APIs to take advantage of or extend the functionality of the existing services.

In general the disadvantage with Restful APIs are related to latency in request processing times and bandwidth usage but that depends on the network and the performing actions. The more obvious challenge is that the application’s performance is dependent upon that of the APIs used if access them at runtime. Another limitation of http is the point to point communication which limits available room for decoupling microservices; a more advanced decoupling is messaging more specifically publish-subscribe via persistent third party brokers like Apache Kafka.

--

--

No responses yet