-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy paththread_control.go
35 lines (31 loc) · 1.15 KB
/
thread_control.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
package messenger
// ThreadControl URLs
var (
TakeThreadControlPath = "me/take_thread_control"
PassThreadControlPath = "me/pass_thread_control"
)
// PassThreadControl represents a Pass thread handover control request content
// https://developers.facebook.com/docs/messenger-platform/handover-protocol/pass-thread-control
type PassThreadControl struct {
Recipient struct {
ID string `json:"id"`
} `json:"recipient"`
TargetAppID int64 `json:"target_app_id"`
Metadata string `json:"metadata,omitempty"`
}
// TakeThreadControl represents a Take thread handover control request content
// https://developers.facebook.com/docs/messenger-platform/handover-protocol/take-thread-control
type TakeThreadControl struct {
Recipient struct {
ID string `json:"id"`
} `json:"recipient"`
Metadata string `json:"metadata,omitempty"`
}
// RequestThreadControl represents a Request thread handover control request content
// https://developers.facebook.com/docs/messenger-platform/handover-protocol/request-thread-control
type RequestThreadControl struct {
Recipient struct {
ID string `json:"id"`
} `json:"recipient"`
Metadata string `json:"metadata,omitempty"`
}