Welcome to the Treehouse Community
Looking to learn something new?
Alex Gervais5,290 Points
At its most basic level an Application Programming Interface (API) helps different software applications interact/communicate with each-other. Let's say Google developed an application (ex. google maps) and you wanted to include part of it in your website, they provide an API (an interface) that defines the rules for how your website can 'talk' to google maps and retrieve the information it needs. Take a TV for example, without the buttons on the remote or front of the TV, we wouldn't be able to tell the TV to turn on, change channel, or do anything. It's the same with applications, it needs to have an interface so other applications can communicate with it.
In Node Js for example: console.log();
console is an API
var http = require('http');
http is an API.
So, these are pre defined node objects which are also called as APIs. These are interfaces, a middle ware to program an application.
Vedant Laskar6,755 Points
just to added on top of that, an API is a function that does the job for you.
Check that link out. If you would like some abstractions, or have more questions, I can give some more examples and answers.