package unipede import ( "net/http" ) type ( UpInventoryModel struct { Count int `json:"count" bson:"count"` Data []UpInventoryData `json:"data" bson:"data"` } UpInventoryData struct { ChassisModel string `json:"chassis_model" bson:"chassis_model"` Container string `json:"container" bson:"container"` CoreId int `json:"core_id" bson:"core_id"` Created string `json:"created" bson:"created"` Dc string `json:"dc" bson:"dc"` Depth int `json:"depth" bson:"depth"` HostName string `json:"hostname" bson:"hostname"` Id int `json:id"` ManagementIp int `json:"management_ip" bson:"management_ip"` ModelName string `json:"model_name" bson:"model_name"` OsVersion string `josn:"string"` PathNorth string `json:"path_north" bson:"path_north"` Serial string `json:"serial" bson:"serial"` UpDeviceId int `json:"up_device_id" bson:"up_device_id"` Updated string `json:"updated" bson:"updated"` Vendor string `json:"vendor" bson:"vendor"` ZenosState string `json:"zenoss_state" bson:"zenoss_state"` ZenossUid string `json:"zenoss_uid" bson:"zenoss_uid"` ZenossUuid string `json:"zenoss_uuid" bson:"zenoss_uuid"` } ) func (u *Client) UpInventory(filter string, options ...*UnipedeOptions) (*UpInventoryModel, error) { o := processOptions(nil, nil, options...) o.SetFilter(filter) req, err := u.newRequest(unipedeURL+"device_property/UpInventory::Model", http.MethodGet, o, nil) if err != nil { return nil, err } ures := new(UpInventoryModel) _, err = u.do(req, o, ures) return ures, err }