controller

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DashboardController

type DashboardController interface{}

type HealthDependency

type HealthDependency struct {
	Name   string `json:"name"`
	Status string `json:"status"`
}

type HealthResponse

type HealthResponse struct {
	Status       string             `json:"status"`
	Timestamp    string             `json:"timestamp"`
	Dependencies []HealthDependency `json:"dependencies"`
}

type PairController

type PairController interface {
	Pairs(ctx *gin.Context)
	Pair(ctx *gin.Context)
}

func InitPairController

func InitPairController(s service2.Getter[service2.Pair], route *gin.RouterGroup, networkMetadata pkg.NetworkMetadata, logger logging.Logger) PairController

type PairRes

type PairRes struct {
	*dezswap.PairRes
}

type PairsRes

type PairsRes struct {
	Pairs []PairRes `json:"pairs"`
}

type PoolController

type PoolController interface {
	Pools(ctx *gin.Context)
	Pool(ctx *gin.Context)
}

func InitPoolController

func InitPoolController(s service2.Getter[service2.Pool], route *gin.RouterGroup, networkMetadata pkg.NetworkMetadata, logger logging.Logger) PoolController

type PoolRes

type PoolRes struct {
	Address string `json:"address"`
	*dezswap.PoolRes
}

type PoolsRes

type PoolsRes []PoolRes

type StatController

type StatController interface {
	Stats(ctx *gin.Context)
	Stat(ctx *gin.Context)
}

type StatRes

type StatRes struct {
	Volume []StatValueRes `json:"volume"`
	Fee    []StatValueRes `json:"fee"`
	Apr    []StatValueRes `json:"apr"`
}

type StatValueRes

type StatValueRes struct {
	Address string `json:"address"`
	Value   string `json:"value"`
}

type StatsRes

type StatsRes struct {
	Stats24h  StatRes `json:"stats_24h"`
	Stats7d   StatRes `json:"stats_7d"`
	Stats1mon StatRes `json:"stats_1mon"`
}

type StatusController

type StatusController interface {
	Version(ctx *gin.Context)
	Health(ctx *gin.Context)
}

func InitStatusController

func InitStatusController(service service.StatusService, r *gin.RouterGroup, version string, logger logging.Logger) StatusController

type TickerController

type TickerController interface {
	Tickers(ctx *gin.Context)
	Ticker(ctx *gin.Context)
}

type TokenController

type TokenController interface {
	Tokens(ctx *gin.Context)
	Token(ctx *gin.Context)
}

func InitTokenController

func InitTokenController(s service2.Getter[service2.Token], route *gin.RouterGroup, logger logging.Logger) TokenController

type TokenRes

type TokenRes struct {
	ChainId     string `json:"chainId"`
	Token       string `json:"token"`
	Name        string `json:"name"`
	Symbol      string `json:"symbol"`
	Decimals    uint8  `json:"decimals"`
	TotalSupply string `json:"total_supply" `
	Icon        string `json:"icon"`
	Protocol    string `json:"protocol"`
	Verified    bool   `json:"verified"`
}

type TokensRes

type TokensRes []TokenRes

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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