-
Notifications
You must be signed in to change notification settings - Fork 2
/
subbot-instagram.yaml
133 lines (120 loc) · 3.64 KB
/
subbot-instagram.yaml
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
openapi: 3.0.0
info:
title: Subbot for Instagram
version: '1.0'
components:
schemas:
Instagram_Text_Event:
title: Text Event
description: >
A message of type [Text](https://developers.facebook.com/docs/messenger-platform/reference/webhook-events/messages#messaging)
type: object
required: [message]
properties:
message:
type: object
required: [text]
properties:
text:
type: string
description: The text message to send
Instagram_Postback_Event:
title: Postback Event
description: >
A trimmed version of the [postback webhook](https://developers.facebook.com/docs/messenger-platform/reference/webhook-events/messaging_postbacks).
type: object
required: [postback]
properties:
postback:
type: object
required: [payload]
properties:
payload:
description: payload parameter that was defined with the button.
type: string
Instagram_Event:
title: Instagram Event
description: A message sent by a user to a brand
oneOf:
- $ref: '#/components/schemas/Instagram_Text_Event'
- $ref: '#/components/schemas/Instagram_Postback_Event'
Instagram_Text_Message:
title: Text Message
description: A text message
type: object
required: [text]
properties:
text:
description: the text of the message to send.
type: string
Instagram_WebUrl_Button:
type: object
required: [type, url, title]
properties:
type:
type: string
enum: [web_url]
url:
type: string
format: uri
title:
type: string
Instagram_Postback_Button:
type: object
required: [type, title, payload]
properties:
type:
type: string
enum: [postback]
title:
type: string
payload:
type: string
Instagram_Button:
oneOf:
- $ref: '#/components/schemas/Instagram_WebUrl_Button'
- $ref: '#/components/schemas/Instagram_Postback_Button'
Instagram_Carousel_Message:
title: Carousel Message
type: object
properties:
attachment:
type: object
properties:
type:
type: string
enum: [template]
payload:
type: object
required: [template_type, elements]
properties:
template_type:
type: string
enum: [generic]
elements:
type: array
items:
type: object
required: [title]
properties:
title:
type: string
description: the title to display
maxLength: 80
subtitle:
type: string
description: the subtitle to display
maxLength: 80
image_url:
type: string
format: uri
buttons:
type: array
items:
$ref: '#/components/schemas/Instagram_Button'
Instagram_Message:
title: Instagram Message
description: A message sent by a brand to a user.
oneOf:
- $ref: '#/components/schemas/Instagram_Text_Message'
- $ref: '#/components/schemas/Instagram_Carousel_Message'