6 Common Ways To Publish APIs

First let me explain what is an API in simple terms

Imagine you're a customer (an application or program) sitting at a table (a device), and you want to order food (request data or services). Instead of going into the kitchen (the system or server) yourself, you interact with the waiter (API), who takes your order and communicates it to the kitchen on your behalf. The kitchen then prepares the food (performs the requested task), and the waiter brings it back to you.

Similarly, an API allows different software applications to communicate and share information or perform specific tasks without knowing the intricate details of each other's internal workings. It acts as a bridge, enabling applications to request and exchange data or functionalities in a standardized way.


Ok now lets explore 6 common ways to build APIs.

  1. REST: Architecture using standard HTTP methods for CRUD operations on resources.

  2. GraphQL: Query language enabling clients to request specific data structures.

  3. WebSocket: Full-duplex communication protocol for real-time applications.

  4. gRPC: High-performance RPC framework for efficient communication between services.

  5. MQTT: Lightweight messaging protocol for low-bandwidth, high-latency networks, common in IoT.

  6. Serverless: Cloud computing model where developers focus on code, and the provider manages infrastructure.

#APIs