What Is An API?

What Is An API?

As promised, today I'll be writing about API. The term "API" has been used so much in recent times by those who leverage technology and those who create software solutions, that one has to wonder about what special thing an API does.

As always, I'll attempt to make this subject as relatable as possible before jumping into technical jargon. Imagine for a second that you want to make coffee/tea (depending on your preference), you have your coffee/tea ingredients but you don't have water, it's safe to say you won't be drinking any beverages, yes?

dolphin-1548448_1280.jpg

AN API DESCRIBED RELATABLY

Let's again assume that you have your water and you brew your beverage. When your drink is fully brewed, you can't exactly see any water, you can see and smell the result of your tea ingredients, however, the water itself isn't apparent. Yes, we know water is in there but as far as visual confirmation goes, you're staring at a brownish liquid.

Now how does it apply to API? Well, an API is an abbreviation for Application Programming Interface. As far as modern programming goes, an API is just like water in that it can be used in multiple ways, with different other components and still provide the same utility to all types of components.

architecture-192192_1280.jpg

THE RESULT OF APIs ARE EXPOSED THROUGH FRONTEND PROGRAMMING

The same way water can be used to dilute coffee and tea is the way it's used to dilute other things. An API is a part of a software solution that provides access to processed or unprocessed data which is commonly obtained from a database in a way that makes it possible for this processed/unprocessed data to be exposed to the end-user through some fanciful programming languages that we typically call front-end programming.

Everything you see when you surf the web or make use of software solutions is front-end programming, APIs are backend programming. Tying this to my first example, remember we couldn't visually see the water after brewing the coffee/tea but we knew water was in there? It's the same for software solutions that leverage APIs, we know there's an API there, albeit we can't see it.

call-1866884_1280.jpg

TIMES WHEN YOU USED AN API

You probably want to know if you've ever used an API, yes? Have you ever tried to log in or register on a platform and you saw the option to log in/register using Google, Twitter, Facebook or LinkedIn? If you've ever clicked one of those icons that look like our popular social media platforms and were able to login or register, then you've made use of an API.

Typically, APIs return data or collect some data from you and return its processed form as a result. If you've ever downloaded videos from Facebook or YouTube using an app or a website where you pasted the link and got access to the video then you've been using an API.

loveourplanet-4851331_1280.jpg

FINALLY...

API does a very specific thing which is why it hardly fails; I've mostly described commercialized APIs that are put out there for people to leverage them. Within apps and websites that use APIs to interact with the database, it's more or less the same, only you're less aware of the API you're using.

When you search for things on a web app or software and you get results, you may have just leveraged an API, when you click a particular button and you see a response, when you click the "submit" button on a form, etc., you may be using an API. It's important to note that not all software solutions are built using APIs though.