Published on

Some Web API's definition you SHOULD know

Medium: Some Web API's definition you SHOULD know

Viblo: 12 khái niệm về Web API's - Bạn NÊN biết

Web API's definition you SHOULD know

What is a Web API?

The Web API stands for Application Programming Interfaces and is designed to allow web applications to communicate with each other and access data remotely. It works on HTTP and HTTPS protocols, using methods like GET, POST, PUT, and DELETE to access, create, modify, and delete data.

Web API Applications

  • Use data from different sources: Web APIs can be used to retrieve data from various sources, such as websites, web services, and other applications.
    • Example: Google Maps API: This API allows web applications to display maps and access location data.
  • Updates data
  • Create integrated web applications: Web APIs can be used to create web applications that integrate with each other, such as social networking applications and e-commerce applications.
  • And other applications...

Web API's definition - you SHOULD know

Storage API

Storage API is an important tool that allows applications to access and manage data. Storage API provides a standard and easy-to-use way to access data, regardless of platform or operating system.

In addition, the Storage API offers many other advanced features such as:

  • Version Management: Allows you to track and restore previous versions of data.
  • Data Backup: Allows you to back up your data to another location to prevent data loss.
  • Data Encryption: Allows you to protect your data from unauthorized access.

Examples of Storage API:

  • IndexedDB: Local Storage API is the most commonly used on web browsers.
  • WebSQL: Another Local Storage API used on web browsers.
  • Amazon S3, Google Cloud Storage,...

HTML Sanitizer API

HTML Sanitizer API is a new tool to protect your website from malware and cross-site attacks (XSS). It works by scanning and removing dangerous HTML parts from user-imported content, ensuring that only secure content is displayed on your website.

How HTML Sanitizer API works:

  • Step 1: When users import content to your site, the HTML Sanitizer API scans that content for dangerous HTML parts.
  • Step 2: Dangerous HTML parts will be removed or replaced with secure content.
  • Step 3: Content that has been desinfected will be displayed on your website.

Canvas API

Canvas API is used to draw 2D graphics directly on the website. It provides web developers with a powerful way to create interactive images, animations and graphic effects without the use of external plugins or software.

Example of Canvas API:

  • Draw charts and charts
  • Display animation * Create interactive graphical effects

Fullscreen API

Fullscreen API allows websites to display a part or the entire site in full-screen mode. It provides methods to request and exit full screen mode, as well as to track full screen status changes.


  • Display video in full screen mode
  • Display image in full screen mode
  • Create a full-screen image browser

History API

The History API allows you to manipulate the user's browsing history on your website. It provides methods for adding, deleting, and modifying items in history, as well as for moving back and forth between items.


  • Add back buttons and other customizations to your site
  • Update site URLs when users change content

Geo Location API

The Geolocation API allows websites to access a user's geolocation. It provides methods to get the latitude, length and accuracy of the location, as well as to track changes in the user's location.

  • Use the getCurrentPosition() method to get the location.

  • Application: Displays the location of the user on the map,...

Fetch API

The Fetch API is a modern JavaScript application programming interface (API) used to execute HTTP requests (GET, POST, PUT, DELETE, etc.) to servers and retrieve feedback.

Supposed to replace the old XMLHttpRequest method for its ease of use, flexibility and closer integration with other JavaScript features like Promise.

If you work a lot with React, you're probably too familiar with the Fetch API.

Formdata API

The FormData API allows you to create and manipulate form data. It provides a simple way to access form field values, uploaded files and other data sent from HTML forms.

Drag and Drop API

Drag and Drop API allows users to drag and drop HTML elements between different locations on a website or between different websites. It provides an intuitive and easy way to move data and perform various operations.

The most common application is to upload files by dragging and dropping.

Payment Request API

Introduced to standardize the payment experience on the website. It stores regularly used payment information and reduces the number of steps to make online payments.


The DOM API is an application programming interface (API) for HTML and XML documents that defines the functionality of each component in HTML. It allows access and control of HTML elements through DOM.

Clipboard API

Clipboard API allows websites to access and operate with the system's clipboard. It provides methods to read and write data to the clipboard, as well as to track changes on the clipboards.

For example, display notifications when users copy or paste data,...


Hopefully this article will help you understand and grasp some of the basic concepts of Web APIs.

Last word: Happy Lunar New Year! 🌸

I am always looking for feedback on my writing, so please let me know what you think. ❤️