api

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DatabaseMiddleware

func DatabaseMiddleware() gin.HandlerFunc

func RegisterRouter

func RegisterRouter() *gin.Engine

Types

type BroadcastRequest

type BroadcastRequest struct {
	Message string `json:"message"`
}

type EmptyResponse

type EmptyResponse struct{}

type ErrorResponse

type ErrorResponse struct {
	Error string `json:"error"`
}

type From

type From string
const (
	FromRcon From = "rcon"
	FromSav  From = "sav"
)

type LoginInfo

type LoginInfo struct {
	Password string `json:"password"`
}

type PlayerOrderBy

type PlayerOrderBy string
const (
	OrderByLastOnline PlayerOrderBy = "last_online"
	OrderByLevel      PlayerOrderBy = "level"
)

type ServerInfo

type ServerInfo struct {
	Version string `json:"version"`
	Name    string `json:"name"`
}

type ShutdownRequest

type ShutdownRequest struct {
	Seconds string `json:"seconds"`
	Message string `json:"message"`
}

type SuccessResponse

type SuccessResponse struct {
	Success bool `json:"success"`
}

Jump to

Keyboard shortcuts

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