The toy response starts with a status line.

highlighted = computed this step

The response starts with a status line

The first response row gives the version and status before any headers or body bytes.

status line first\text{status line first}
Response status lineThe response rows, body rows, and length check are recomputed from pinned bytes.Response status line - 200 OK body hello is 5 bytes, Content-Length 5sectionnamevaluecheckrequest linemethodGETparsedrequest linepath/hello.txtparsedrequest lineversionHTTP/1.1parsedheaderHoststatic.exampleexactheaderAccepttext/plainexactstatusversionHTTP/1.1parsedstatusstatus200 OKokheaderContent-Typetext/plainexactheaderContent-Length5declared bytesbodytexthelloafter blank linebodyhex68656c6c6fASCII bytesbodybyte length5countedcheckContent-Length5declaredcheckbody bytes5recomputedcheckmatchyessame number

The status is OK

The status code is 200, and the reason text is OK.

status=200\text{status}=200
Response status lineThe response rows, body rows, and length check are recomputed from pinned bytes.Response status line - 200 OK body hello is 5 bytes, Content-Length 5sectionnamevaluecheckrequest linemethodGETparsedrequest linepath/hello.txtparsedrequest lineversionHTTP/1.1parsedheaderHoststatic.exampleexactheaderAccepttext/plainexactstatusversionHTTP/1.1parsedstatusstatus200 OKokheaderContent-Typetext/plainexactheaderContent-Length5declared bytesbodytexthelloafter blank linebodyhex68656c6c6fASCII bytesbodybyte length5countedcheckContent-Length5declaredcheckbody bytes5recomputedcheckmatchyessame number

The request asked for the text file

The request rows show path /hello.txt and Accept text/plain.

/hello.txt requested\text{/hello.txt requested}
Response status lineThe response rows, body rows, and length check are recomputed from pinned bytes.Response status line - 200 OK body hello is 5 bytes, Content-Length 5sectionnamevaluecheckrequest linemethodGETparsedrequest linepath/hello.txtparsedrequest lineversionHTTP/1.1parsedheaderHoststatic.exampleexactheaderAccepttext/plainexactstatusversionHTTP/1.1parsedstatusstatus200 OKokheaderContent-Typetext/plainexactheaderContent-Length5declared bytesbodytexthelloafter blank linebodyhex68656c6c6fASCII bytesbodybyte length5countedcheckContent-Length5declaredcheckbody bytes5recomputedcheckmatchyessame number

Summary

The response line tells us the request succeeded before the body is counted.

response begins with status\text{response begins with status}
Response status lineThe response rows, body rows, and length check are recomputed from pinned bytes.Response status line - 200 OK body hello is 5 bytes, Content-Length 5sectionnamevaluecheckrequest linemethodGETparsedrequest linepath/hello.txtparsedrequest lineversionHTTP/1.1parsedheaderHoststatic.exampleexactheaderAccepttext/plainexactstatusversionHTTP/1.1parsedstatusstatus200 OKokheaderContent-Typetext/plainexactheaderContent-Length5declared bytesbodytexthelloafter blank linebodyhex68656c6c6fASCII bytesbodybyte length5countedcheckContent-Length5declaredcheckbody bytes5recomputedcheckmatchyessame number