api_code

package
v0.0.0-...-e5308b5 Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiCode

type ApiCode int
const (
	InternalServerErr ApiCode = 500
	InvalidParams     ApiCode = 10000
)

type Response

type Response struct {
	Code    ApiCode `json:"code"`
	Message string  `json:"message"`
}

func NewResponse

func NewResponse(code ApiCode, message string) *Response

func (*Response) Error

func (r *Response) Error() string

Jump to

Keyboard shortcuts

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