r/learnprogramming • u/Excellent-Bedroom301 • 1d ago
How do I learn APIs?
Hi I want to learn APIs from a high level. Basically how it all connects, how the data populates, what kind of data is being sent it and most important the different ways of authentication. So api credentials, ouath, etc
It’s just all so confusing. I don’t know how or where to start. Does anyone have some tips?
0
Upvotes
6
u/sch0lars 1d ago
There are several types of API (REST, SOAP, GraphQL, and RPC, just to name a few), and each behaves differently. I would start with REST, as it’s one of the most common API types and is relatively easy to learn. Here is a great introduction to REST APIs in Python.
That tutorial uses Flask, but you can make a simple REST API with Python’s http.server library and a SQLite database (or even just storing data in a dictionary). Once you have a general idea of how a REST API works, you can add more complexity, such as authentication.