Module 25: APIs and JSON

Lesson 1 of 5 · 15–25 minutes

What an API is

🏠The everyday picture

A restaurant menu and a waiter. You don't walk into the kitchen; you order from the menu, in the agreed way, and the waiter brings back what you asked for. The menu and waiter together are the kitchen's interface.

📘What it really is

🖱️Try it

Open https://api.github.com/users/octocat in your browser. That's a real API response: data about one GitHub user, in JSON. Find the user's name and number of public repositories in it.

✅Quick check

In the restaurant picture, what's the endpoint?

Show the answer

A specific item you can order from the menu: one address you can send a request to.

Your app uses a weather API and it suddenly breaks without any change on your side. What might have happened?

Show the answer

The API changed, is down, or your access (key, limit) changed. Check its status and documentation.

← BackModule 25
ProLearners Assist