liveBook · Manning

HTTP

As explained in Build Python Web Apps with Streamlit

HTTP is the application-layer protocol used to transfer web resources and exchange messages between clients and servers.

HTTP is the set of rules that lets software exchange messages over the web. A client such as a browser sends a well-formed request to a server. section 5.3.1

A typical HTTP-based API interaction includes:

  • A URL combines a base address with an endpoint that identifies the request type. section 5.3.1
  • GET requests can carry key-value parameters in the URL, while POST requests can carry them in a request payload. section 5.3.1
  • Headers can carry additional information such as an API key, and responses often use JSON. section 5.3.1

Requesting a forecast

A weather API might use https://api.weathersite.com/forecast?date=2024-08-01. The response can contain high and low temperatures together with forecast text in JSON.

How Build Python Web Apps with Streamlit covers it

How deep it goes
Defines clients, servers, URLs, methods, headers, parameters, and JSON, but does not descend into protocol internals.
Examples
Uses a weather forecast URL, date query parameter, JSON response, and API-key error response.
What you can do after
Apply it via API URLs, HTTP methods, parameters, headers, and JSON parsing.
How it connects
Ties HTTP to APIs, clients, servers, URLs, GET, POST, headers, request payloads, and JSON.

Also explained in

Compare how 8 books explain HTTP →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Build Python Web Apps with Streamlit. The section links point to the parts of the book it draws on.