rest

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ProcessIDContextKey = "processID"
	ContentType         = "Content-Type"
	ApplicationJSON     = "application/json"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Rest

type Rest interface {
	Post(ctx context.Context, url string, header map[string]string, payload any) ([]byte, int, error)
	Put(ctx context.Context, url string, header map[string]string, payload any) ([]byte, int, error)
	Get(ctx context.Context, url string, header map[string]string, queryParams map[string]string) ([]byte, int, error)
	Delete(ctx context.Context, url string, header map[string]string, queryParams map[string]string) ([]byte, int, error)
}

func New

func New(timeout time.Duration, addLogToExtraData bool) Rest

Jump to

Keyboard shortcuts

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