What is API:Application Programing Interface provides a medium of interaction between software components. Now-a-days API programing is one of the most important components of software development. Know more about API
API is something like URL that provides some intended data to the user. Let me explain it with some real world example.
Consider you have an account in Facebook and you want to access your friend list, status, photos through codding. Here Facebook is a total different entity which has no relation with your code (application), neither you can access Facebook’s code nor its database. So how can you access those data in your FB account via your application?
Here comes the role of API, Facebook provides an interface (URL/Graph API) that gives you all the intended details of your account, those can be used in any application. So your work is just to call the API provides by the client (here Facebook) and to use the response in your application. That’s it.