Documentation
¶
Index ¶
- Constants
- type Client
- func (c *Client) HostGet(groupID string) (*HostGetResponse, error)
- func (c *Client) HostGroupGet(hostGroupName string) (string, error)
- func (c *Client) ItemGetLastValue(itemID string) (string, error)
- func (c *Client) Login(user, password string) (string, error)
- func (c *Client) Logout() error
- func (c *Client) TrendGetMin(itemID string, from, till int32) (int, error)
- type HostGetParams
- type HostGetResponse
- type HostGroupGetParams
- type HostGroupGetResponse
- type ItemGetParams
- type ItemGetResponse
- type LoginParams
- type LoginResponse
- type LogoutResponse
- type Method
- type Params
- type Request
- type Response
- type TrendGetParams
- type TrendGetResponse
Constants ¶
View Source
const ( UserLogin Method = "user.login" UserLogout = "user.logout" TrendGet = "trend.get" HostGroupGet = "hostgroup.get" HostGet = "host.get" ItemGet = "item.get" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) ItemGetLastValue ¶ added in v1.0.14
type HostGetParams ¶
type HostGetResponse ¶
type HostGetResponse struct {
Result []struct {
Hostid string `json:"hostid"`
Host string `json:"host"`
Items []struct {
Itemid string `json:"itemid"`
Name string `json:"name"`
Key string `json:"key_"`
} `json:"items"`
} `json:"result"`
}
host.get
type HostGroupGetParams ¶
type HostGroupGetParams struct {
//SelectHosts []string `json:"selectHosts"`
Filter struct {
Name []string `json:"name"`
} `json:"filter"`
}
hostgroup.get
type HostGroupGetResponse ¶
type HostGroupGetResponse struct {
Result []struct {
Groupid string `json:"groupid"`
Name string `json:"name"`
} `json:"result"`
}
hostgroup.get
type ItemGetParams ¶ added in v1.0.14
type ItemGetResponse ¶ added in v1.0.14
type ItemGetResponse struct {
Result []struct {
Itemid string `json:"itemid"`
Lastvalue string `json:"lastvalue"`
} `json:"result"`
}
item.get
type LoginParams ¶
type LoginResponse ¶
type LoginResponse struct {
Result string `json:"result"`
}
type LogoutResponse ¶
type LogoutResponse struct {
Result bool `json:"result"`
}
type Request ¶
type TrendGetParams ¶
Click to show internal directories.
Click to hide internal directories.