Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OpenWeatherMap ¶
type OpenWeatherMap struct { AppID string `toml:"app_id"` CityID []string `toml:"city_id"` Lang string `toml:"lang"` Fetch []string `toml:"fetch"` BaseURL string `toml:"base_url"` ResponseTimeout internal.Duration `toml:"response_timeout"` Units string `toml:"units"` // contains filtered or unexported fields }
func (*OpenWeatherMap) Description ¶
func (n *OpenWeatherMap) Description() string
func (*OpenWeatherMap) Gather ¶
func (n *OpenWeatherMap) Gather(acc telegraf.Accumulator) error
func (*OpenWeatherMap) Init ¶
func (n *OpenWeatherMap) Init() error
func (*OpenWeatherMap) SampleConfig ¶
func (n *OpenWeatherMap) SampleConfig() string
type WeatherEntry ¶
type WeatherEntry struct { Dt int64 `json:"dt"` Clouds struct { All int64 `json:"all"` } `json:"clouds"` Main struct { Humidity int64 `json:"humidity"` Pressure float64 `json:"pressure"` Temp float64 `json:"temp"` } `json:"main"` Rain struct { Rain1 float64 `json:"1h"` Rain3 float64 `json:"3h"` } `json:"rain"` Sys struct { Country string `json:"country"` Sunrise int64 `json:"sunrise"` Sunset int64 `json:"sunset"` } `json:"sys"` Wind struct { Deg float64 `json:"deg"` Speed float64 `json:"speed"` } `json:"wind"` ID int64 `json:"id"` Name string `json:"name"` Coord struct { Lat float64 `json:"lat"` Lon float64 `json:"lon"` } `json:"coord"` Visibility int64 `json:"visibility"` Weather []struct { ID int64 `json:"id"` Main string `json:"main"` Description string `json:"description"` Icon string `json:"icon"` } `json:"weather"` }
Click to show internal directories.
Click to hide internal directories.