What are APIs?

Learn about the concepts of APIs.

We'll cover the following

What is an API?

In most applications, we’ll see that there are two parts:

  • Frontend
  • Backend

The frontend often handles the UI and how the application looks. The backend handles the database and other logic.

We need to establish a link between the backend and the frontend.

Web APIs

The term web APIs is frequently used when discussing APIs in relation to web development. A web API is an API that can be accessed using the HTTP protocol.

Typically, when we request a webpage, we get all sorts of data, like HTML, CSS, and JavaScript. On the other hand, when we use JavaScript to make an asynchronous request, we just need a portion of the data.

Web APIs receive queries from various client devices, such as mobile phones, laptops, etc., deliver them to the web server for processing, and give the processed data back to the client.

For example, Twitter’s API provides access to read and write data, which we can use to integrate Twitter’s capabilities into our application. For example, we could get data about a user’s tweets and use it in our application.

Get hands-on with 1400+ tech skills courses.