Adding documentation for 'agent' option in http.request().

Fixes #1243.
v0.7.4-release
Kip Gebhardt 2011-06-28 12:50:42 -07:00 committed by koichik
parent 5208abe723
commit 7097eca5a7
1 changed files with 4 additions and 0 deletions

View File

@ -393,6 +393,10 @@ Options:
- `path`: Request path. Should include query string and fragments if any.
E.G. `'/index.html?page=12'`
- `headers`: An object containing request headers.
- `agent`: Controls `Agent` behavior. Possible values:
- `undefined` (default): use default `Agent` for this host and port.
- `Agent` object: explicitly use the passed in `Agent`.
- `false`: explicitly generate a new `Agent` for this host and port. `Agent` will not be re-used.
`http.request()` returns an instance of the `http.ClientRequest`
class. The `ClientRequest` instance is a writable stream. If one needs to