1. What’s an API?
An API, or “Application Programming Interface,” is a set of rules and protocols that allow two applications to communicate with each other by making requests to a server. It is essentially an intermediary that facilitates the interaction between different systems even if they do not share the same configuration or programming language, allowing them to share data and functionalities efficiently, which is why they are fundamental in the development of modern software, since they enable the integration of services and the creation of more robust and flexible applications.
2. What’s the function of API?
They are used in a wide variety of contexts, from social networks and cloud services to online payment platforms. A use case could be a REST API for the development of Machine Learning and Deep Learning, they are useful since they will execute the code of the algorithms through the HTTP protocol and that these will be accessible to the end user, in this way the user could upload their own data to the API and that it is responsible for executing the Machine Learning or Deep Learning model, thus processing the data entered by the user.
A simple example could be an API with a classification algorithm trained with health data from patients in a clinic, and when the user enters the data of new patients, the algorithm within the API is able to predict whether these new patients can be prone or not to suffer from a certain disease based on their health data. Another example is company APIs which give you access to certain information from the platform, for example in the case of the Instagram API it is possible to see the number of users on the social network who are using a certain hashtag.