Skip to content

Go Client Library. Simple & Fast HTTP Client For Requests

Notifications You must be signed in to change notification settings

hackincloud-com/hic-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Very Simple Http Client For Requests

Integrated with Heimdall and FastHTTP

Installation

go get github.com/hackincloud-com/hic-client

Usage

Just like this

package main

import (
	httpclient "github.com/hackincloud-com/hic-client"
)
func main() {
	// if POST
	client := &httpclient.ReqStruct{
		Url:     "https://google.com",
		Method:  "POST",
		Body:    io.ReaderBody,
		Timeout: 60,
	}

	res := client.DoRequests()
	if res.Error != nil {
		cobra.CheckErr(res.Error)
	}
    // if GET
    client := &httpclient.ReqStruct{
		Url:     "https://google.com",
		Method:  "GET",
		Timeout: 60,
	}

	res := client.DoRequests()
	if res.Error != nil {
		cobra.CheckErr(res.Error)
	}
}

About

Go Client Library. Simple & Fast HTTP Client For Requests

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages