1 package storm
2 3 import (
4 liquidweb "github.com/liquidweb/liquidweb-go"
5 "github.com/liquidweb/liquidweb-go/types"
6 )
7 8 // Config represents the configuration of the server.
9 type Config struct {
10 ID types.FlexInt `json:"id"`
11 Active types.NumericalBoolean `json:"active,omitempty"`
12 Available types.NumericalBoolean `json:"available,omitempty"`
13 Category string `json:"category,omitempty"`
14 Description string `json:"description,omitempty"`
15 Disk types.FlexInt `json:"disk,omitempty"`
16 Featured types.NumericalBoolean `json:"featured,omitempty"`
17 Memory types.FlexInt `json:"memory,omitempty"`
18 VCPU types.FlexInt `json:"vcpu,omitempty"`
19 ZoneAvailability map[string]types.NumericalBoolean `json:"zone_availability,omitempty"`
20 }
21 22 // ConfigParams is the set of parameters used when fetching storm configuration details
23 type ConfigParams struct {
24 ID string `json:"id,omitempty"`
25 }
26 27 // ConfigList is an envelope for the API result containing either a list of storm configs or an error.
28 type ConfigList struct {
29 liquidweb.ListMeta
30 Items []Config
31 }
32 33 // ConfigListParams are the set of parameters you can pass to the API for listing storm configs.
34 type ConfigListParams struct {
35 Available bool `json:"available,omitempty"`
36 Category string `json:"category,omitempty"`
37 PageNum int `json:"page_num,omitempty"`
38 PageSize int `json:"page_size,omitempty"`
39 }
40