diff --git a/doc/api/http.md b/doc/api/http.md index e71b22649ea59c..f7843fe2be180f 100644 --- a/doc/api/http.md +++ b/doc/api/http.md @@ -519,7 +519,7 @@ unsent, it will flush them to the stream. If the request is chunked, this will send the terminating `'0\r\n\r\n'`. If `data` is specified, it is equivalent to calling -[`response.write(data, encoding)`][] followed by `request.end(callback)`. +[`request.write(data, encoding)`][] followed by `request.end(callback)`. If `callback` is specified, it will be called when the request stream is finished. @@ -1900,6 +1900,7 @@ const req = http.request(options, (res) => { [`net.createConnection()`]: net.html#net_net_createconnection_options_connectlistener [`request.socket`]: #http_request_socket [`request.socket.getPeerCertificate()`]: tls.html#tls_tlssocket_getpeercertificate_detailed +[`request.write(data, encoding)`]: #http_request_write_chunk_encoding_callback [`response.end()`]: #http_response_end_data_encoding_callback [`response.setHeader()`]: #http_response_setheader_name_value [`response.socket`]: #http_response_socket