-
Notifications
You must be signed in to change notification settings - Fork 1
/
types.go
47 lines (38 loc) · 1.02 KB
/
types.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
package circle
import (
"fmt"
"time"
)
const CircleTime = "20060102T150405Z"
type Session struct {
Jwt string
}
type Accessory struct {
Name string `json:"name"`
AccessoryId string `json:"accessoryId"`
NodeId string `json:"nodeId"`
session *Session
}
type GetActivitiesByAccessoryIdInput struct {
StartActivityId string `json:"startActivityId"`
Operator string `json:"operator"`
ScanDirectionNewer bool `json:"scanDirectionNewer"`
Limit int32 `json:"limit"`
Filter string `json:"filter"`
ExtraFields []string `json:"extraFields"`
}
type GetActivitiesByAccessoryIdOutput struct {
Activities []*Activity `json:"activities"`
}
type Activity struct {
ActivityId string `json:"activityId"`
ActivityTime time.Time `json:"-"`
hydrated bool
accessory *Accessory
}
func (a Activity) String() string {
return fmt.Sprintf("%s (%v)", a.ActivityId, a.ActivityTime)
}
type GetLiveImageInput struct {
AccessoryId string `json:"accessoryId"`
}