This repository was archived by the owner on Jun 4, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathserver_types.go
More file actions
54 lines (48 loc) · 1.62 KB
/
server_types.go
File metadata and controls
54 lines (48 loc) · 1.62 KB
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
package hetzner
import . "github.com/appscode/go/encoding/json/types"
type ServerSummary struct {
ServerIP string `json:"server_ip"`
ServerNumber int `json:"server_number"`
ServerName string `json:"server_name"`
Product string `json:"product"`
Dc string `json:"dc"`
Traffic string `json:"traffic"`
Flatrate bool `json:"flatrate"`
Status string `json:"status"`
Throttled bool `json:"throttled"`
Cancelled bool `json:"cancelled"`
PaidUntil string `json:"paid_until"`
}
type Server struct {
ServerSummary
IP []string `json:"ip"`
Subnet []struct {
IP string `json:"ip"`
Mask string `json:"mask"`
} `json:"subnet"`
Reset bool `json:"reset"`
Rescue bool `json:"rescue"`
Vnc bool `json:"vnc"`
Windows bool `json:"windows"`
Plesk bool `json:"plesk"`
Cpanel bool `json:"cpanel"`
Wol bool `json:"wol"`
}
type ServerUpdateRequest struct {
ServerIP string
ServerName string `url:"server_name"`
}
type Cancellation struct {
ServerIP string `json:"server_ip"`
ServerNumber int `json:"server_number"`
ServerName string `json:"server_name"`
EarliestCancellationDate string `json:"earliest_cancellation_date"`
Cancelled bool `json:"cancelled"`
CancellationDate string `json:"cancellation_date"`
CancellationReason ArrayOrString `json:"cancellation_reason"`
}
type CancelServerRequest struct {
ServerIP string
CancellationDate string `url:"cancellation_date"`
CancellationReason string `url:"cancellation_reason,omitempty"`
}