-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
informresponse.go
98 lines (92 loc) · 2.96 KB
/
informresponse.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
package unifi
// An InformHeartbeatResponse is a heartbeat response to an Inform request.
//
// swagger:response informResponse
type InformHeartbeatResponse struct {
// value "noop"
Type string `json:"_type"`
Interval int64 `json:"interval"`
ServerTimeUTC int64 `json:"server_time_in_utc"`
}
// An InformUpgradeResponse is an upgrade command
type InformUpgradeResponse struct {
// value "upgrade"
Type string `json:"_type"`
URL string `json:"url"`
// rfc3339 formatted date, server time
DateTime string `json:"datetime"`
ServerTimeUTC int64 `json:"server_time_in_utc"`
// Firmware version
Version string `json:"version"`
// Server time as unix timestamp
Time int64 `json:"time"`
// unknown id string (5232701de4b0457a2f2f031f)
ID string `json:"_id"`
// device ID from database
DeviceID string `json:"device_id"`
}
// InformConfigUpdateResponse is a config update command
type InformConfigUpdateResponse struct {
// value "setparam"
Type string `json:"_type"`
PortConfig string `json:"port_cfg"`
AnalogConfig string `json:"analog_cfg"`
AuthorizedGuests string `json:"authorized_guests"`
BlockedStations string `json:"blocked_stations"`
ConfigVersion string `json:"cfg_version"`
ManagementConfig string `json:"mgmt_cfg"`
SystemConfig string `json:"system_cfg"`
ServerTimeUTC int64 `json:"server_time_in_utc"`
}
// InformRebootResponse is a reboot command
type InformRebootResponse struct {
// value "reboot"
Type string `json:"_type"`
// device ID from database
DeviceID string `json:"device_id"`
ServerTimeUTC int64 `json:"server_time_in_utc"`
// server time as unix timestamp
Time int64 `json:"time"`
// unknown id string (5232701de4b0457a2f2f031f)
ID string `json:"_id"`
}
// InformLocateResponse is a locate command
type InformLocateResponse struct {
// value "cmd"
Type string `json:"_type"`
// value "locate"
Command string `json:"cmd"`
// rfc3339 formatted date, server time
DateTime string `json:"datetime"`
// device ID from database
DeviceID string `json:"device_id"`
ServerTimeUTC int64 `json:"server_time_in_utc"`
// server time as unix timestamp
Time int64 `json:"time"`
// unknown id string (5232701de4b0457a2f2f031f)
ID string `json:"_id"`
}
// InformCommandResponse is a command response
type InformCommandResponse struct {
// value "cmd"
Type string `json:"_type"`
Admin struct {
// database id of admin
ID string `json:"_id"`
// admin language (en_US)
Lang string `json:"lang"`
Name string `json:"name"`
Password string `json:"x_password"`
} `json:"_admin"`
// unknown id string (5232701de4b0457a2f2f031f)
ID string `json:"_id"`
DateTime string `json:"datetime"`
ServerTimeUTC int64 `json:"server_time_in_utc"`
Time int64 `json:"time"`
// device ID from database
DeviceID string `json:"device_id"`
Command string `json:"cmd"`
MAC string `json:"mac"`
Model string `json:"model"`
Parameters string `json:"-"`
}