http

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2023 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Command

type Command struct {
	Name                string `yaml:"name"` // e.g. `open` or `close`
	Endpoint            string `yaml:"endpoint"`
	HttpMethod          string `yaml:"http_method"`
	Body                string `yaml:"body"`
	RequiredStartState  string `yaml:"required_start_state"`  // if set, garage door will not operate if current state does not equal this
	RequiredFinishState string `yaml:"required_finish_state"` // if set, garage door will monitor the door state compared to this value to determine success
	Timeout             int    `yaml:"timeout"`               // time to wait for garage door to operate if monitored
}

type HttpGdo

type HttpGdo interface {
	SetGarageDoor(string) error
	ProcessShutdown()
}

func Initialize

func Initialize(config map[string]interface{}) (HttpGdo, error)

func NewHttpGdo

func NewHttpGdo(config map[string]interface{}) (HttpGdo, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL