The toy request posts a small JSON body.

highlighted = computed this step

The request uses POST

The request line says POST and names path /api.

POST /api\text{POST /api}
JSON request lineThe JSON request rows, body rows, field rows, and length check are recomputed from pinned bytes.JSON request line - POST /api JSON body 17 bytes, fields ok=true and n=3sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/apiparsedrequest lineversionHTTP/1.1parsedheaderHostapi.exampleexactheaderContent-Typeapplication/jsonJSONheaderContent-Length17declared bytesbodydisplay wordsok true comma n threesafe display formbodyexact hex7b226f6b223a747275652c226e223a337dpinned bytesbodybyte length17countedfieldokok=trueparsedfieldnn=3parsedcheckContent-Length17declaredcheckbody bytes17recomputedcheckmatchyessame count

The Host header names api.example

The Host row pins the toy API site.

Host=api.example\text{Host}=\text{api.example}
JSON request lineThe JSON request rows, body rows, field rows, and length check are recomputed from pinned bytes.JSON request line - POST /api JSON body 17 bytes, fields ok=true and n=3sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/apiparsedrequest lineversionHTTP/1.1parsedheaderHostapi.exampleexactheaderContent-Typeapplication/jsonJSONheaderContent-Length17declared bytesbodydisplay wordsok true comma n threesafe display formbodyexact hex7b226f6b223a747275652c226e223a337dpinned bytesbodybyte length17countedfieldokok=trueparsedfieldnn=3parsedcheckContent-Length17declaredcheckbody bytes17recomputedcheckmatchyessame count

The version token is pinned

The request line ends with the pinned HTTP version token.

HTTP version token\text{HTTP version token}
JSON request lineThe JSON request rows, body rows, field rows, and length check are recomputed from pinned bytes.JSON request line - POST /api JSON body 17 bytes, fields ok=true and n=3sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/apiparsedrequest lineversionHTTP/1.1parsedheaderHostapi.exampleexactheaderContent-Typeapplication/jsonJSONheaderContent-Length17declared bytesbodydisplay wordsok true comma n threesafe display formbodyexact hex7b226f6b223a747275652c226e223a337dpinned bytesbodybyte length17countedfieldokok=trueparsedfieldnn=3parsedcheckContent-Length17declaredcheckbody bytes17recomputedcheckmatchyessame count

Summary

The request line and Host header say where this toy JSON request goes.

request line checked\text{request line checked}
JSON request lineThe JSON request rows, body rows, field rows, and length check are recomputed from pinned bytes.JSON request line - POST /api JSON body 17 bytes, fields ok=true and n=3sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/apiparsedrequest lineversionHTTP/1.1parsedheaderHostapi.exampleexactheaderContent-Typeapplication/jsonJSONheaderContent-Length17declared bytesbodydisplay wordsok true comma n threesafe display formbodyexact hex7b226f6b223a747275652c226e223a337dpinned bytesbodybyte length17countedfieldokok=trueparsedfieldnn=3parsedcheckContent-Length17declaredcheckbody bytes17recomputedcheckmatchyessame count