Skip to content

adamkeys/httpua

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

httpua

A Go package to set a custom User-Agent when placing HTTP requests using http.Client.

Usage

Creating a new http client:

client := httpua.NewClient("MyUserAgent/1.0") // Returns *http.Client
client.Get("...")

Extending an initialized http client:

client := httpua.WithClient(http.DefaultClient, "MyUserAgent/1.0") // Returns *http.Client
client.Get("...")

Documentation

https://pkg.go.dev/github.com/adamkeys/httpua

About

A Go package to set a custom User-Agent when placing HTTP requests using http.Client.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages