response

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIAllAccountDetailResponse

type APIAllAccountDetailResponse struct {
	Result []store.AccountDetail `json:"result"`
}

APIAllAccountDetailResponse holds all stored account details.

type APIAllMonitoredAccountResponse

type APIAllMonitoredAccountResponse struct {
	Result map[string]*store.AccountDetail `json:"result"`
}

APIAllMonitoredAccountResponse holds all monitored account.

type APIAllTokenDetailResponse

type APIAllTokenDetailResponse struct {
	Result map[string]store.TokenDetail `json:"result"`
}

APIAllTokenDetailResponse holds all stored account details.

type APIResponse

type APIResponse struct {
	Error string      `json:"error,omitempty"`
	Data  interface{} `json:"data,omitempty"`
}

func NewAPIJSONResponse

func NewAPIJSONResponse(c *gin.Context, data interface{}, err error) APIResponse

NewAPIJSONResponse creates a new APIResponse with given data. It also sets the header "Content-Type" to "application/json".

func NewAPIResponse

func NewAPIResponse(c *gin.Context, data interface{}, err error) APIResponse

NewAPIResponse creates a new APIResponse with given data.

Jump to

Keyboard shortcuts

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