-
Notifications
You must be signed in to change notification settings - Fork 0
/
intent.go
51 lines (44 loc) · 1.5 KB
/
intent.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
48
49
50
51
package fsmalexa
// Intent Object
// https://developer.amazon.com/docs/custom-skills/request-types-reference.html#intent-object
type Intent struct {
Name string `json:"name,omitempty"`
ConfirmationStatus string `json:"confirmationStatus,omitempty"`
Slots map[string]Slot `json:"slots,omitempty"`
}
// Slot Object
// https://developer.amazon.com/docs/custom-skills/request-types-reference.html#slot-object
type Slot struct {
Name string `json:"name,omitempty"`
Value string `json:"value,omitempty"`
ConfirmationStatus string `json:"confirmationStatus,omitempty"`
Resolutions Resolutions `json:"resolutions,omitempty"`
}
// Resolutions Object
// https://developer.amazon.com/docs/custom-skills/request-types-reference.html#resolutions-object
type Resolutions struct {
ResolutionsPerAuthority []Authority `json:"resolutionsPerAuthority,omitempty"`
}
// Authority Object
// See the Resolutions Object
type Authority struct {
Authority string `json:"authority,omitempty"`
Status Status `json:"status,omitempty"`
Values []SlotValue `json:"values,omitempty"`
}
// Status Object
// See Resolutions
type Status struct {
Code string `json:"code,omitempty"`
}
// SlotValue Object
// See Resolutions
type SlotValue struct {
Value ResolvedValue `json:"value,omitempty"`
}
// ResolvedValue Object
// See Resolutions
type ResolvedValue struct {
ID string `json:"id,omitempty"`
Name string `json:"name,omitempty"`
}