Client and Server
The browser (client) asks; a remote computer (server) answers.
An API request is a message from your page to a server.
The server sends back a response. No fetch yet —
label the parts of a typical HTTP exchange (builds on Phase 13 promises
for “later” results).
Request
Response
Roles
Pick an example to label request and response parts.
Important JavaScript
// HTTP pieces (conceptual — fetch comes next)
// Request: method + URL + headers + optional body
// Response: status + headers + body
// GET /posts/1 → read one resource (usually no body)
// POST /posts → create (JSON body often)
// PUT /posts/1 → replace/update
// DELETE /posts/1 → remove