web dev//API
Application Programming Interface. A contract between two pieces of software: "send me this request, I'll give you this response." In web dev, almost always means HTTP endpoints that return JSON.
Application Programming Interface. A contract between two pieces of software: "send me this request, I'll give you this response." In web dev, almost always means HTTP endpoints that return JSON.
External APIs: third-party services your app calls via HTTP (Google, Stripe, Sentry, etc.)
Event-driven APIs: your app fires an event, processing happens asynchronously in a job queue
Internal APIs: your own backend endpoints that your frontend calls
In Next.js, API Routes define your internal API, deployed as Vercel Functions
The intuition against reading pages: instead of looking at the shop and reading the labels, you ask the warehouse directly, "give me product 123 in JSON". That is why an API beats scraping whenever one exists, and why a hybrid agent reaches for it first.