Omit empty fields
This commit is contained in:
parent
b3138a42e5
commit
63c2a86871
1 changed files with 14 additions and 14 deletions
|
@ -14,23 +14,23 @@ type VirtualizationInterfacesService service
|
|||
|
||||
// NewVirtualizationInterface is used for creating a new virtualization interface
|
||||
type NewVirtualizationInterface struct {
|
||||
CustomFields interface{} `json:"custom_fields"`
|
||||
Name string `json:"name"`
|
||||
Mode string `json:"mode"`
|
||||
Description string `json:"description"`
|
||||
MACAddress string `json:"mac_address"`
|
||||
Tags []struct {
|
||||
CustomFields *interface{} `json:"custom_fields,omitempty"`
|
||||
Name string `json:"name"`
|
||||
Mode string `json:"mode,omitempty"`
|
||||
Description string `json:"description,omitempty"`
|
||||
MACAddress string `json:"mac_address,omitempty"`
|
||||
Tags *[]struct {
|
||||
Name string `json:"name"`
|
||||
Slug string `json:"slug"`
|
||||
Color string `json:"color"`
|
||||
} `json:"tags"`
|
||||
TaggedVLANs []int `json:"tagged_vlans"`
|
||||
Bridge int `json:"bridge"`
|
||||
Parent int `json:"parent"`
|
||||
UntaggedVLAN int `json:"untagged_vlan"`
|
||||
MTU int `json:"mtu"`
|
||||
VirtualMachine int `json:"virtual_machine"`
|
||||
Enabled bool `json:"enabled"`
|
||||
} `json:"tags,omitempty"`
|
||||
TaggedVLANs *[]int `json:"tagged_vlans,omitempty"`
|
||||
Bridge int `json:"bridge,omitempty"`
|
||||
Parent int `json:"parent,omitempty"`
|
||||
UntaggedVLAN int `json:"untagged_vlan,omitempty"`
|
||||
MTU int `json:"mtu,omitempty"`
|
||||
VirtualMachine int `json:"virtual_machine"`
|
||||
Enabled bool `json:"enabled,omitempty"`
|
||||
}
|
||||
|
||||
// VirtualizationInterfaces is a list of interfaces
|
||||
|
|
Loading…
Reference in a new issue