|Join Nairaland / LOGIN! / Trending / Recent / New|
Stats: 2,598,430 members, 6,030,920 topics. Date: Friday, 04 December 2020 at 12:09 AM
Pls I'm at open ears if one can explain
API means Application Programming Interface. It allows you to interact with another software from your own software. For example, if you integrate google map API in your website, you will be able to display google map in your site.
Another example - if you want to create a website that displays lists of all foods on earth, you do not need to type all the foods in your code. All you have to do is to integrate with an API software that has all lists of foods and loop through them in your code.
Codedreamer:Thanks a million... I could use a little more Explanation on your second explanation... but thanks nonetheless.. God bless u for this
An API (Application Programming Interface) is a means of sharing data across different applications.
For example google has a YouTube data-API that allows 3rd party users to consume YouTube data on their sites. With this API you can make a request to YouTube database and do something like a channel search or video search, the YouTube server will give you a response of all videos or channels that match your search in JSON format. You then use this JSON data to render the YouTube videos on your site or if it was a channel search you can display the channel and info about the channel such as name, subscribers, views, etc. You can also display all the videos on that channel on your site.
There are many more things you can do with Google's YouTube data-API and other API's in general. But at their core they are simply a means to query 3rd party servers and get data from them or even perform other CRUD operations according to the rules set by the operator of that Server.
Firstly APIs is a general programming, in fact computer science concept.
Imagine a tv and remote, you don't change channels by loosing the board and manipulating transitors, you press the remote and the TV does something.
The remote is the API, it gives you access to get, modify or delete channels in the TV, you don't know how it does this, you just know that the delete button on the remote(API) deletes whichever channel you call
So you interact with the API, and not the server directly.
IN JS(the web in general as web apis can be written in any backend language)
you get a series of links, which might take data.
Calling these links will do something
website/get-all-books.... would give you all the books in the database(usually in JSON for REST API)
website/delete-book/id=1.... would delete the book with id=1
the mechanism that deletes or fetches the book is hidden within the server serving the apis, you don't know how that works, you just know it does what you want it to do
This is a simplified explanation, do read up more advanced explanations
API, Microservices, Software Architecture, Object Oriented Programming/Analysis/Design, Encapsulation, Framework, Functional Programming, Abstraction and lots more are big words that tech people throw around to sound smart.
In reality, these big words mean very simple things.
I was even reading a book that differentiated between encapsulation and information hiding. I mean, the difference can be negligible.
|Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health |
religion celebs tv-movies music-radio literature webmasters programming techmarket
Nairaland - Copyright © 2005 - 2020 Oluwaseun Osewa. All rights reserved. See How To Advertise. 49