forked from sleeyax/aternos-api
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserver_info.go
101 lines (70 loc) · 2.12 KB
/
server_info.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
package aternos_api
type ServerInfo struct {
// Server brand.
// Usually this is just "aternos".
Brand string `json:"brand"`
// Status code.
Status ServerStatus `json:"status"`
// Time since the server info, such as the status, has been updated.
LastChanged int `json:"change"`
// Maximum amount of players.
MaxPlayers int `json:"slots"`
// Number of logged issues or problems.
Problems int `json:"problems"`
// Amount of active players.
Players int `json:"players"`
// List of active players.
PlayerList []string `json:"playerlist"`
Message struct {
Text string `json:"text"`
Class string `json:"class"`
} `json:"message"`
// Dynamic IP address.
DynIP string `json:"dynip"`
// Whether this is a server for bedrock edition.
IsBedrock bool `json:"bedrock"`
Host string `json:"host"`
Port int `json:"port"`
HeadStarts int `json:"headstarts"`
RAM int `json:"ram"`
// Status label
// E.g. online, offline.
StatusLabel string `json:"lang"`
// Status label but in human-readable format.
// E.g. Starting..., Online, Offline.
StatusLabelFormatted string `json:"label"`
// CSS class that's applied to the status label.
StatusLabelClass string `json:"class"`
// Amount of time left to join the server.
Countdown int `json:"countdown"`
Queue Queue `json:"queue"`
// Unique server ID.
Id string `json:"id"`
// Name of the server.
Name string `json:"name"`
// Server software.
Software string `json:"software"`
SoftwareId string `json:"softwareId"`
// Software type.
// E.g vanilla, papermc.
SoftwareType string `json:"type"`
// Current Minecraft version.
Version string `json:"version"`
IsDeprecated bool `json:"deprecated"`
// IP address.
IP string `json:"ip"`
// Domain address.
Address string `json:"displayAddress"`
// Message Of The Day.
MOTD string `json:"motd"`
// Name of the class that's used to display an icon next to the status.
// E.g fa-stop-circle.
Icon string `json:"icon"`
DNS struct {
Type string `json:"type"`
Domains []string `json:"domains"`
Host string `json:"host"`
Port int `json:"port"`
IP string `json:"ip"`
} `json:"dns"`
}