Fix listprefixes struct.
This commit is contained in:
parent
a94cdc3159
commit
42a0bb87e1
1 changed files with 43 additions and 17 deletions
|
@ -33,32 +33,58 @@ type IpamPrefixesCreate struct {
|
|||
|
||||
// IpamPrefixList is used for the return value from NetBox API ipam_prefixes_list
|
||||
type IpamPrefixesList struct {
|
||||
Count int `json:"count"`
|
||||
Next string `json:"next"`
|
||||
Previous interface{} `json:"previous"`
|
||||
Count int `json:"count"`
|
||||
Next string `json:"next"`
|
||||
Previous string `json:"previous"`
|
||||
Results []struct {
|
||||
ID int `json:"id"`
|
||||
Family struct {
|
||||
Value int `json:"value"`
|
||||
Label string `json:"label"`
|
||||
Value int `json:"value"`
|
||||
} `json:"family"`
|
||||
Prefix string `json:"prefix"`
|
||||
Site interface{} `json:"site"`
|
||||
Vrf interface{} `json:"vrf"`
|
||||
Tenant interface{} `json:"tenant"`
|
||||
Vlan interface{} `json:"vlan"`
|
||||
Prefix string `json:"prefix"`
|
||||
Site struct {
|
||||
ID int `json:"id"`
|
||||
URL string `json:"url"`
|
||||
Name string `json:"name"`
|
||||
Slug string `json:"slug"`
|
||||
} `json:"site"`
|
||||
Vrf struct {
|
||||
ID int `json:"id"`
|
||||
URL string `json:"url"`
|
||||
Name string `json:"name"`
|
||||
Rd string `json:"rd"`
|
||||
PrefixCount int `json:"prefix_count"`
|
||||
} `json:"vrf"`
|
||||
Tenant struct {
|
||||
ID int `json:"id"`
|
||||
URL string `json:"url"`
|
||||
Name string `json:"name"`
|
||||
Slug string `json:"slug"`
|
||||
} `json:"tenant"`
|
||||
Vlan struct {
|
||||
ID int `json:"id"`
|
||||
URL string `json:"url"`
|
||||
Vid int `json:"vid"`
|
||||
Name string `json:"name"`
|
||||
DisplayName string `json:"display_name"`
|
||||
} `json:"vlan"`
|
||||
Status struct {
|
||||
Value int `json:"value"`
|
||||
Label string `json:"label"`
|
||||
Value int `json:"value"`
|
||||
} `json:"status"`
|
||||
Role interface{} `json:"role"`
|
||||
IsPool bool `json:"is_pool"`
|
||||
Description string `json:"description"`
|
||||
Tags []interface{} `json:"tags"`
|
||||
Role struct {
|
||||
ID int `json:"id"`
|
||||
URL string `json:"url"`
|
||||
Name string `json:"name"`
|
||||
Slug string `json:"slug"`
|
||||
PrefixCount int `json:"prefix_count"`
|
||||
VlanCount int `json:"vlan_count"`
|
||||
} `json:"role"`
|
||||
IsPool bool `json:"is_pool"`
|
||||
Description string `json:"description"`
|
||||
Tags []string `json:"tags"`
|
||||
CustomFields struct {
|
||||
IpamPrefixRouted interface{} `json:"ipam_prefix_routed"`
|
||||
IpamPrefixRoutedLastUpdate interface{} `json:"ipam_prefix_routed_last_update"`
|
||||
IpamPrefixExitpoint interface{} `json:"ipam_prefix_exitpoint"`
|
||||
} `json:"custom_fields"`
|
||||
Created string `json:"created"`
|
||||
LastUpdated time.Time `json:"last_updated"`
|
||||
|
|
Loading…
Reference in a new issue