Documentation ¶
Index ¶
Constants ¶
View Source
const (
APIPrefix = "https://open.memobird.cn/home"
)
Default API endpoints, according to http://open.memobird.cn/upload/webapi.pdf
View Source
const MemobirdTimeZone = "Asia/Shanghai"
Variables ¶
View Source
var TZShanghai *time.Location
Functions ¶
Types ¶
type App ¶
type App struct { *AppConfig // contains filtered or unexported fields }
App is an memobird application.
func (*App) BindDevice ¶
func (a *App) BindDevice(deviceID string) (*BindResult, error)
BindDevice binds given device for further use.
type AppConfig ¶
type AppConfig struct { AccessKey string Timeout time.Duration // CustomizedAPIPrefix is an optional configuration where an alternative APIPrefix should be used. CustomizedAPIPrefix string }
AppConfig contains all configurations of an App.
type BindResult ¶
BindResult contains the result of a bind request.
Click to show internal directories.
Click to hide internal directories.