Skip to content

Latest commit

 

History

History
46 lines (38 loc) · 2.72 KB

intro_to_api.md

File metadata and controls

46 lines (38 loc) · 2.72 KB

INTRODUCTION TO APIs

An application programming interface, or API, enables companies to open up their application’s data and functionality to external third-party developers and business partners, or to departments within their companies. This allows services and products to communicate with each other and leverage each other’s data and functionality through a documented interface. Programmers don't need to know how an API is implemented; they simply use the interface to communicate with other products and services. API use has surged over the past decade, to a degree that many of the popular web applications today would not be possible without APIs.

How Do APIs Work?

APIs work by sharing data and information between applications, systems, and devices—making it possible for these things to talk with each other.

Sometimes the easiest way to think about APIs is to think about a metaphor, and a common scenario that a lot of folks use is that of the customer, a waiter, and a restaurant kitchen: A customer talks to the waiter and tells the waiter what she wants. The waiter takes down the order and communicates it to the kitchen. The kitchen does their work, creating the food, and then the waiter delivers the order back to the customer.

In this metaphor, a customer is like a user, who tells the waiter what he/she wants. The waiter is like an API, receiving the customer’s order and translating the order into easy-to-follow instructions that the kitchen then uses to fulfill that order—often following a specific set of codes, or input, that the kitchen easily recognizes. The kitchen is like a server that does the work of creating the order in the manner the customer wants it, hopefully! When the food is ready, the waiter picks up the order and delivers it to the customer.

Advantages of APIs

  • Efficiency: API produces efficient, quicker and more reliable results than the outputs produced by human beings in an organization.
  • Flexible delivery of services: API provides fast and flexible delivery of services according to developers requirements.
  • Integration: The best feature of API is that it allows movement of data between various sites and thus enhances integrated user experience.
  • Automation: As API makes use of robotic computers rather than humans, it produces better and automated results.
  • New functionality: While using API the developers find new tools and functionality for API exchanges.

Disadvantages of APIs

  • Cost: Developing and implementing API is costly at times and requires high maintenance and support from developers.
  • Security issues: Using API adds another layer of surface which is then prone to attacks, and hence the security risk problem is common in API’s.