How to read API docs
You will live in API documentation, so here's how to get what you need fast without reading all of it. For any endpoint, hunt for five things:
- The method and URL —
GET /forecast. What it does, in two tokens. - Authentication — what header or key it needs. Usually one shared section for the whole API.
- Parameters — the inputs you can send (here,
city), which are required, and their types. - An example response — the JSON shape you'll get back. This is gold; copy it.
- Errors — what comes back when something's wrong, and the status codes (
401unauthorized,404not found,429rate-limited).
Good docs include a copy-pasteable example request and response. Those two snippets tell you more than paragraphs of prose — grab them and hand them to the AI.