Evolution of Software
We all are encountering different types of Software in our day to day lives. The development process for each of this software is different and unique. Every software solves a separate purpose. Earlier we used to have big fat applications which used to serve a single purpose, but nowadays we see everything migrating towards Web apps or Mobile Apps. We see most of them integrated with Social media. We see many apps making use of SSO of popular social media apps like Facebook Linkedin etc. It is only fair to say there is heavy reuse of code everywhere and no one wants to re-invent the wheel
Why the hype behind API?
APIs help separate the modules by the functionality.
You interface with an API because it solves a particular problem for you. Take for example the Google Maps API. You interface with it if you want geolocation functionality.
Imagine the several new web applications that are being developed day in day out. Now there are several modules implemented in the backend to give that nice user interface to you. At the backend, a module might take care of authentication, another might take care of database etc. Now all the interaction between the modules is possible because of API. It allows programmers to develop their own module and expose the functionality through an API and not be concerned about what other programmers have developed.
You can develop and test your implemented function through API.
Typically all these modules might be implemented in a single system/server or they might even be distributed. Take the example of google maps API. Your application might reside on a server in India. The maps API could point to a server in California. So the app implemented by you in your server has to extend an API call to the California server, fetch the response and then present it to your clients in a nice GUI. Can we say this to be a distributed system? we sure can. We need to take care of the networking requirements we implement such distributed systems.
Documentation of APIs
The documentation for API forms key for people to efficiently use and implement the API in their code. The doc should mention clearly how you are expecting the data input, what is the output format etc. Also, the language you expect the API server and client to speak is very important. Shall we call it encoding? Most of the API design uses a standard encoding schema.
We shall see more about the encoding schemas in upcoming articles