Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Device ¶
type Device struct { fulfillment.Device `bson:",inline"` PublicKeyBase64 string `bson:"publickey"` }
Device is device from database
type DevicePermissions ¶
DevicePermissions defines what user can and cannot
type DeviceRequest ¶
type DeviceRequest struct { Params map[string]interface{} `json:"params,omitempty"` Command string `json:"command"` }
DeviceRequest is type of request incoming to the device
type DeviceResponse ¶
type DeviceResponse struct { State map[string]interface{} `json:"state"` Status string `json:"status"` Error string `json:"error,omitempty"` }
DeviceResponse is type of response coming out of the device
type ResponseError ¶
type ResponseError struct { Name string `json:"error"` Description string `json:"error_description,omitempty"` StatusCode int `json:"-"` }
ResponseError is used to return it for example from some HTTP route
type User ¶
type User struct { ID string `json:"id" form:"-"` FirstName string `json:"firstName" form:"firstName" binding:"required"` LastName string `json:"lastName" form:"lastName" binding:"required"` Email string `json:"email" houseflow:"email" form:"email" binding:"required,email"` Password string `json:"password" form:"password" binding:"required,min=8,max=20"` PasswordHash []byte `json:"-" form:"-"` }
User struct, used to either creating user, or this one in DB
Click to show internal directories.
Click to hide internal directories.