scootpl / restreq

RestReq is a wrapper around standard Go net/http client. In a simple call you can use json encoding, add headers and parse result. This should be sufficient in most use cases.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

RestReq

Go Reference Go Report Card

RestReq is a wrapper around standard Go net/http client. In a simple call you can use json encoding, add headers and parse result. This should be sufficient in most use cases.

Features

  • Simple syntax
  • Only stdlib (no external dependencies)
  • JSON parsing
  • Debug logging

Quick Start

import "github.com/scootpl/restreq"

resp, err := restreq.New("http://example.com").
	AddHeader("X-TOKEN", authToken).
	Post()

Examples and Documentation

See GoDoc for more details.

About

RestReq is a wrapper around standard Go net/http client. In a simple call you can use json encoding, add headers and parse result. This should be sufficient in most use cases.

License:MIT License


Languages

Language:Go 100.0%