When I first started coding, people kept saying "API" everywhere.
Tutorials → API
Projects → API
Job descriptions → API
And I kept thinking, okay but WHAT EVEN IS IT 😭
Everyone explained it in complicated words, so I just nodded and moved on.
If you're confused too : keep reading. This will finally make sense.
Think of a restaurant 🍽️
You sit at the table and order food
You don't walk into the kitchen and cook it yourself
You tell the waiter → waiter goes to the kitchen → brings food back
That waiter is the API.
you - your app
waiter - api
kitchen - another company's system
The API takes your request, goes to get what you need, and brings back the answer. That's the whole job.
Where do you actually see APIs in real life? 👀
☁️ Weather app → asks a weather service for today's weather
🔐 "Login with Google" → website asks Google to confirm who you are
🗺️ Swiggy / Uber maps → uses Google Maps API to show your location
💳 Online payments → Razorpay / Stripe API processes the transaction
Once you know what an API is, you'll start seeing them everywhere.
What does it look like in code? 💻
- You open a weather app and search Delhi.
- Your app sends a request: GET /weather?city=Delhi
- API replies: { "temperature": "34°C", "condition": "Sunny" }
- Your app shows: 🌤️ Delhi → 34°C
See what happened?
Your app didn't calculate the weather.
It didn't store any weather data
It just asked someone who already had it
That's exactly what APIs do.
So what is an API? One line:
API = messenger between two applications.
You ask → API gets it → you receive the answer.
That's genuinely it. 🙂
I'm learning in public and writing about everything that confused me as a beginner. Follow if you want more of this 👋
Top comments (0)