response

package
v0.0.0-...-e2602fe Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var WhiteList = []string{
	"/api.json",
	"/health",
}

Functions

func HttpForGrpcResponseMiddleware

func HttpForGrpcResponseMiddleware(r *ghttp.Request)

func HttpResponseMiddleware

func HttpResponseMiddleware(r *ghttp.Request)

Types

type DefaultHandlerResponse

type DefaultHandlerResponse struct {
	Code    int         `json:"code"    dc:"Error code"`
	Message string      `json:"message" dc:"Error message"`
	Data    interface{} `json:"data"    dc:"Result data for certain request according API definition"`
}

DefaultHandlerResponse is the default implementation of HandlerResponse.

Jump to

Keyboard shortcuts

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