httpmethods

package
v0.0.0-...-079c60b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 3, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AvailableHttpMethods = []string{
	"GET",
	"POST",
	"PUT",
	"PATCH",
	"DELETE",
	"HEAD",
	"OPTIONS",
}

Functions

func RunHttpMethod

func RunHttpMethod(input Input) (*http.Response, error)

Types

type Command

type Command struct {
	Name  string
	Short string
	Run   func(Input) (*http.Response, error)
}

type Input

type Input struct {
	HTTPMethod string `arg:"-m,--http-method,required"`
	URL        string `arg:"-u,--url,required"`
	Body       string `arg:"-b,--body"`
	Header     string `arg:"-H,--header"`
	Output     string `arg:"-o"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL