Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AutomationSummary ¶ added in v0.0.2
AutomationSummary represents summary info about an automation for event responses
type DeleteEventRuleResponse ¶
type DeleteEventRuleResponse struct {
Message string `json:"message"`
}
DeleteEventRuleResponse represents response after deleting an event rule
type EventItem ¶
type EventItem struct {
EventID int64 `json:"id"`
EventType string `json:"event_type"`
EventLevel string `json:"event_level,omitempty"`
Title string `json:"title,omitempty"`
TimeFired time.Time `json:"time_fired"`
Automation *AutomationSummary `json:"automation,omitempty"`
Geofence *GeofenceSummary `json:"geofence,omitempty"`
Location *LocationData `json:"location,omitempty"`
}
EventItem represents a single event in API response
type EventRuleRequest ¶ added in v0.0.2
type EventRuleRequest struct {
RuleKey *string `json:"rule_key" validate:"required"`
Definition json.RawMessage `json:"definition"`
IsActive *bool `json:"is_active"`
RepeatAble *bool `json:"repeat_able"`
CooldownSec *int `json:"cooldown_sec"`
Description *string `json:"description"`
}
EventRuleRequest represents event rule fields within an automation request
type GeofenceSummary ¶ added in v0.0.2
type GeofenceSummary struct {
ID string `json:"id"`
Name *string `json:"name,omitempty"`
TypeZone *string `json:"type_zone,omitempty"`
}
GeofenceSummary represents summary info about a geofence for event responses
type LocationData ¶ added in v0.0.2
type LocationData struct {
Latitude float64 `json:"latitude"`
Longitude float64 `json:"longitude"`
}
LocationData represents geographic coordinates
Click to show internal directories.
Click to hide internal directories.