Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Delete

func Delete(url string, bodyType string, body io.Reader) (*http.Response, error)

func DeleteForm

func DeleteForm(url string, data url.Values) (*http.Response, error)

func Get

func Get(url string) (*http.Response, error)
func Head(url string) (*http.Response, error)

func NewHTTPClient

func NewHTTPClient() *http.Client

    Creates a new HTTP client with KeepAlive disabled.

    func Post

    func Post(url string, bodyType string, body io.Reader) (*http.Response, error)

    func PostForm

    func PostForm(url string, data url.Values) (*http.Response, error)

    func Put

    func Put(url string, bodyType string, body io.Reader) (*http.Response, error)

    func PutForm

    func PutForm(url string, data url.Values) (*http.Response, error)

    func ReadBody

    func ReadBody(resp *http.Response) []byte

      Reads the body from the response and closes it.

      func ReadBodyJSON

      func ReadBodyJSON(resp *http.Response) map[string]interface{}

        Reads the body from the response and parses it as JSON.

        func RunServer

        func RunServer(f func(*server.Server))

          Starts a new server.

          Types

          This section is empty.

          Directories

          Path Synopsis
          module