Regenerated types so that sub-types are not embedded.
This allows callers to create complex payloads; for example, to create a Device type for a Unifi Switch with PortOverrides, the caller needs to create these sub-types, which is not possible when it's purely embedded.
This commit is contained in:
committed by
Paul Tyng
parent
35eda4f67b
commit
bee58f48d4
@@ -23,18 +23,20 @@ type ScheduleTask struct {
|
||||
NoDelete bool `json:"attr_no_delete,omitempty"`
|
||||
NoEdit bool `json:"attr_no_edit,omitempty"`
|
||||
|
||||
Action string `json:"action,omitempty"` // stream|upgrade
|
||||
AdditionalSoundsEnabled bool `json:"additional_sounds_enabled"`
|
||||
BroadcastgroupID string `json:"broadcastgroup_id"`
|
||||
CronExpr string `json:"cron_expr,omitempty"`
|
||||
ExecuteOnlyOnce bool `json:"execute_only_once"`
|
||||
MediafileID string `json:"mediafile_id"`
|
||||
Name string `json:"name,omitempty"`
|
||||
SampleFilename string `json:"sample_filename,omitempty"`
|
||||
StreamType string `json:"stream_type,omitempty"` // media|sample
|
||||
UpgradeTargets []struct {
|
||||
MAC string `json:"mac,omitempty"` // ^([0-9A-Fa-f]{2}:){5}([0-9A-Fa-f]{2})$
|
||||
} `json:"upgrade_targets,omitempty"`
|
||||
Action string `json:"action,omitempty"` // stream|upgrade
|
||||
AdditionalSoundsEnabled bool `json:"additional_sounds_enabled"`
|
||||
BroadcastgroupID string `json:"broadcastgroup_id"`
|
||||
CronExpr string `json:"cron_expr,omitempty"`
|
||||
ExecuteOnlyOnce bool `json:"execute_only_once"`
|
||||
MediafileID string `json:"mediafile_id"`
|
||||
Name string `json:"name,omitempty"`
|
||||
SampleFilename string `json:"sample_filename,omitempty"`
|
||||
StreamType string `json:"stream_type,omitempty"` // media|sample
|
||||
UpgradeTargets []ScheduleTask_UpgradeTargets `json:"upgrade_targets,omitempty"`
|
||||
}
|
||||
|
||||
type ScheduleTask_UpgradeTargets struct {
|
||||
MAC string `json:"mac,omitempty"` // ^([0-9A-Fa-f]{2}:){5}([0-9A-Fa-f]{2})$
|
||||
}
|
||||
|
||||
func (c *Client) listScheduleTask(ctx context.Context, site string) ([]ScheduleTask, error) {
|
||||
|
||||
Reference in New Issue
Block a user