Boost
C++ Libraries
...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
This version of Boost is under active development. You are currently in the master branch. The current version is 1.91.0.
Prepare the message payload fields for the body.
void prepare_payload();
This function will adjust the Content-Length and Transfer-Encoding field values based on the properties of the body.
request<string_body> req{verb::post, "/" }; req.set(field::user_agent, "Beast" ); req.body() = "Hello, world!" ; req.prepare_payload();
This function is not necessary to call in the following situations: