Rewrite the httpie using Golang

go-http

In the previous time, I wrote raw HTTP request in a text and sent it to server by nc tool to test my API.
This hard-core style do help me to understand HTTP proto. But I think I could test API in a more effcient way.
One night I found a tool called httpie.
It's awesome and convenient. So I gonna make a new httpie with Golang. Only standard library, it's a good way to learn Golang for someone who new to Golang.

@auhtod: Mrbanana
@date: 2021-9-4
@licece: The MIT License

Usage

$ make clean
$ make
$ ./go-http httpbin.org/status/418

Generally, it looks like ./go-http [host:port]
If host is empty, like :8080, the host is assumed as localhost

Feature

  • In default the go-http use GET method;
  • Use ./go-http :8080 name:banana age:12 to add your request-headers;
  • Use ./go-http :8080 name=banana age=12 to send JSON data in POST method;
  • Use ./go-http :8080 name-banana age#12 to send FORM data in POST method;

Owner
常乐村喵蕉君
Deep ♂ Dark ♂ Fantasy
常乐村喵蕉君
Similar Resources

A fantastic HTTP request libarary used in Golang.

goz A fantastic HTTP request library used in golang. Inspired by guzzle Installation go get -u github.com/idoubi/goz Documentation API documentation

Dec 21, 2022

An HTTP performance testing tool written in GoLang

Gonce A HTTP API performance testing tool written in GoLang Description Installation Usage Description A performance testing tool written in GoLang. S

Jan 28, 2022

fhttp is a fork of net/http that provides an array of features pertaining to the fingerprint of the golang http client.

fhttp The f stands for flex. fhttp is a fork of net/http that provides an array of features pertaining to the fingerprint of the golang http client. T

Jan 1, 2023

NATS HTTP Round Tripper - This is a Golang http.RoundTripper that uses NATS as a transport.

This is a Golang http.RoundTripper that uses NATS as a transport. Included is a http.RoundTripper for clients, a server that uses normal HTTP Handlers and any existing http handler mux and a Caddy Server transport.

Dec 6, 2022

httpreq is an http request library written with Golang to make requests and handle responses easily.

httpreq is an http request library written with Golang to make requests and handle responses easily. Install go get github.com/binalyze/http

Feb 10, 2022

Declarative golang HTTP client

go-req Declarative golang HTTP client package req_test

Dec 20, 2022

A golang tool which makes http requests and prints the address of the request along with the MD5 hash of the response.

Golang Tool This repository is a golang tool which makes http requests to the external server and prints the address of the request along with the MD5

Oct 17, 2021

GoLang Smart HTTP Flood

smart-httpflood Golgang smart http flood This script supports HTTP Version, Cookie and Post Data. Installation: apt install snapd snap install go --cl

Dec 30, 2021

Advanced HTTP client for golang.

go-request Advanced HTTP client for golang. Installation go get github.com/mingming-cn/go-request Usage import ( "github.com/mingming-cn/go-reque

Nov 22, 2021
Related tags
Stream data over http using curl.
Stream data over http using curl.

PIPE TO ME Stream data over http using curl. Hosted at pipeto.me No javascript Go standard library only NAME pipeto.me: streaming data over http

Dec 28, 2022
Httpx - a fast and multi-purpose HTTP toolkit allow to run multiple probers using retryablehttp library
Httpx - a fast and multi-purpose HTTP toolkit allow to run multiple probers using retryablehttp library

httpx is a fast and multi-purpose HTTP toolkit allow to run multiple probers using retryablehttp library, it is designed to maintain the result reliability with increased threads.

Feb 3, 2022
An enhanced http client for Golang
An enhanced http client for Golang

go-http-client An enhanced http client for Golang Documentation on go.dev ?? This package provides you a http client package for your http requests. Y

Dec 23, 2022
Go (golang) http calls with retries and backoff

pester pester wraps Go's standard lib http client to provide several options to increase resiliency in your request. If you experience poor network co

Dec 28, 2022
http client for golang
http client for golang

Request HTTP client for golang, Inspired by Javascript-axios Python-request. If you have experience about axios or requests, you will love it. No 3rd

Dec 18, 2022
A nicer interface for golang stdlib HTTP client

rq A nicer interface for golang stdlib HTTP client Documents rq: here client: here jar: here Why? Because golang HTTP client is a pain in the a... Fea

Dec 12, 2022
golang curl(libcurl) binding.

go-curl my golang libcurl(curl) binding. See more examples in ./examples/ directory~! LICENSE go-curl is licensed under the Apache License, Version 2.

Dec 30, 2022
HTTP mocking for Golang

httpmock Easy mocking of http responses from external resources. Install Currently supports Go 1.7 - 1.15. v1 branch has to be used instead of master.

Dec 28, 2022
Speak HTTP like a local. (the simple, intuitive HTTP console, golang version)

http-gonsole This is the Go port of the http-console. Speak HTTP like a local Talking to an HTTP server with curl can be fun, but most of the time it'

Jul 14, 2021
Http client call for golang http api calls

httpclient-call-go This library is used to make http calls to different API services Install Package go get

Oct 7, 2022