# HTTP Methods

Usage

See here for usage information for below methods.

Note

Each http method returns a Promise

# delete

# get

  • arguments: (url, options?)
  • resolves: Response
  • rejects: Error

These methods corresponds to the similar named HTTP/1.1 methods.

# patch

# post

# put

  • arguments: (url, body?, options?)
  • resolves: Response
  • rejects: Error

These methods corresponds to the similar named HTTP/1.1 methods.

# $delete

# $get

# $head

  • arguments: (url, options?)
  • resolves: JSON
  • rejects: Error

These $-prefixed convenience methods always return the requested content as JSON.

# $patch

# $post

# $put

  • arguments: (url, body?, options?)
  • resolves: JSON
  • rejects: Error

These $-prefixed convenience methods always return the requested content as JSON.