🔌API Endpoint
Also known as Endpoint, API Route, Endpoints
One address in an API, plus its method, like GET /users/42.
Think of it like
Think of it like one counter in a post office. Each counter does one kind of job.
Example
Jack's app uses three endpoints. GET /products lists items, POST /orders buys, and GET /orders/1042 tracks a parcel.
Why it matters
Endpoints are what other people's code is written against. A clear, stable list makes an API easy to use.
Definition
Example code
http
GET /api/orders/1042 HTTP/1.1
Host: example.comCommon mistake
Key takeaways
- 1Method plus path. GET /users/42.
- 2One kind of job. Set inputs, set answer.
- 3Keep it stable. Apps depend on it.