Skip to content

Latest commit

 

History

History

request

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

request (HTTP/s)

Inspired by Your Server as a Function, request provides a composable interface for requesting data over HTTP/s

Request: Request => Promise[Response]

API

request

Transmit data over HTTP or HTTPS

Options supports the standard node request options as well as the additional:

  • secure {Boolean}: enable secure communication over HTTPS, default: false
  • timeout {Number}: request socket timeout in milliseconds, default: 15000
  • data {Buffer|String}: data to write to the request, default: undefined

http.request(options) => Promise~Response → Buffer