http

package
v0.0.0-...-6ac6f58 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2024 License: Apache-2.0, BSD-3-Clause, MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetResponse

func GetResponse(code int, message string, data interface{}) ([]byte, error)

GetResponse adaptor

func GetResponseEx

func GetResponseEx(code int, message string, data interface{}, extra map[string]interface{}) ([]byte, error)

GetResponseEx extension adaptor

Types

type APIResponse

type APIResponse struct {
	Result  bool        `json:"result"`
	Code    int         `json:"code"`
	Message string      `json:"message"`
	Data    interface{} `json:"data"`
}

APIResponse response for api request

type HeaderSet

type HeaderSet struct {
	Key   string
	Value string
}

HeaderSet http header set

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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