1Writer

JavaScript Documentation / http

This object contains methods for performing HTTP requests.

http.request(options, [callback])

Performs a HTTP request.

Parameters

Example

http.get(url, [data], [callback])

Performs a HTTP GET request. This function is equivalent to:

http.request({
    url: url,
    data: data
}, callback);

Parameters

http.post(url, [data], [callback])

Performs a HTTP POST request. This function is equivalent to:

http.request({
    url: url,
    type: 'POST',
    data: data
}, callback);

Parameters