blob: 45a8ce701f3295bfd0a38503328fa741ec8886c7 [file] [log] [blame]
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="chat_v1.html">Hangouts Chat API</a> . <a href="chat_v1.spaces.html">spaces</a> . <a href="chat_v1.spaces.messages.html">messages</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070078 <code><a href="chat_v1.spaces.messages.attachments.html">attachments()</a></code>
79</p>
80<p class="firstline">Returns the attachments Resource.</p>
81
82<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070083 <code><a href="#create">create(parent, body=None, threadKey=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070084<p class="firstline">Creates a message.</p>
85<p class="toc_element">
86 <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
87<p class="firstline">Deletes a message.</p>
88<p class="toc_element">
89 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
90<p class="firstline">Returns a message.</p>
91<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070092 <code><a href="#update">update(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070093<p class="firstline">Updates a message.</p>
94<h3>Method Details</h3>
95<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -070096 <code class="details" id="create">create(parent, body=None, threadKey=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070097 <pre>Creates a message.
98
99Args:
Bu Sun Kim65020912020-05-20 12:08:20 -0700100 parent: string, Required. Space resource name, in the form &quot;spaces/*&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700101Example: spaces/AAAAMpdlehY (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700102 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700103 The object takes the form of:
104
105{ # A message in Hangouts Chat.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700106 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/messages/*&quot;.
107 #
108 # Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
Bu Sun Kim65020912020-05-20 12:08:20 -0700109 &quot;annotations&quot;: [ # Output only. Annotations associated with the text in this message.
110 { # Annotations associated with the plain-text body of the message.
111 #
112 # Example plain-text message body:
113 # ```
114 # Hello @FooBot how are you!&quot;
115 # ```
116 #
117 # The corresponding annotations metadata:
118 # ```
119 # &quot;annotations&quot;:[{
120 # &quot;type&quot;:&quot;USER_MENTION&quot;,
121 # &quot;startIndex&quot;:6,
122 # &quot;length&quot;:7,
123 # &quot;userMention&quot;: {
124 # &quot;user&quot;: {
125 # &quot;name&quot;:&quot;users/107946847022116401880&quot;,
126 # &quot;displayName&quot;:&quot;FooBot&quot;,
127 # &quot;avatarUrl&quot;:&quot;https://goo.gl/aeDtrS&quot;,
128 # &quot;type&quot;:&quot;BOT&quot;
129 # },
130 # &quot;type&quot;:&quot;MENTION&quot;
131 # }
132 # }]
133 # ```
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700134 &quot;startIndex&quot;: 42, # Start index (0-based, inclusive) in the plain-text message body this
135 # annotation corresponds to.
136 &quot;type&quot;: &quot;A String&quot;, # The type of this annotation.
137 &quot;length&quot;: 42, # Length of the substring in the plain-text message body this annotation
138 # corresponds to.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700139 &quot;userMention&quot;: { # Annotation metadata for user mentions (@). # The metadata of user mention.
140 &quot;user&quot;: { # A user in Hangouts Chat. # The user mentioned.
141 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700142 &quot;type&quot;: &quot;A String&quot;, # User type.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700143 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700144 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
145 },
146 &quot;type&quot;: &quot;A String&quot;, # The type of user mention.
147 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700148 },
149 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700150 &quot;actionResponse&quot;: { # Parameters that a bot can use to configure how it&#x27;s response is posted. # Input only. Parameters that a bot can use to configure how its response is
151 # posted.
152 &quot;type&quot;: &quot;A String&quot;, # The type of bot response.
153 &quot;url&quot;: &quot;A String&quot;, # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
154 },
155 &quot;sender&quot;: { # A user in Hangouts Chat. # The user who created the message.
156 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
157 &quot;type&quot;: &quot;A String&quot;, # User type.
158 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
159 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
160 },
161 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the message was created in Hangouts Chat
162 # server.
163 &quot;text&quot;: &quot;A String&quot;, # Plain-text body of the message.
Bu Sun Kim65020912020-05-20 12:08:20 -0700164 &quot;previewText&quot;: &quot;A String&quot;, # Text for generating preview chips. This text will not be displayed to the
165 # user, but any links to images, web pages, videos, etc. included here will
166 # generate preview chips.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700167 &quot;attachment&quot;: [ # User uploaded attachment.
168 { # An attachment in Hangouts Chat.
169 &quot;thumbnailUri&quot;: &quot;A String&quot;, # Output only. The thumbnail URL which should be used to preview the
170 # attachment to a human user. Bots should not use this URL to download
171 # attachment content.
172 &quot;driveDataRef&quot;: { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
173 &quot;driveFileId&quot;: &quot;A String&quot;, # The id for the drive file, for use with the Drive API.
174 },
175 &quot;downloadUri&quot;: &quot;A String&quot;, # Output only. The download URL which should be used to allow a human user to
176 # download the attachment. Bots should not use this URL to download
177 # attachment content.
178 &quot;contentType&quot;: &quot;A String&quot;, # The content type (MIME type) of the file.
179 &quot;name&quot;: &quot;A String&quot;, # Resource name of the attachment, in the form
180 # &quot;spaces/*/messages/*/attachments/*&quot;.
181 &quot;source&quot;: &quot;A String&quot;, # The source of the attachment.
182 &quot;attachmentDataRef&quot;: { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to
183 # download the attachment data.
184 &quot;resourceName&quot;: &quot;A String&quot;, # The resource name of the attachment data. This is used with the media API
185 # to download the attachment data.
186 },
187 &quot;contentName&quot;: &quot;A String&quot;, # The original file name for the content, not the full path.
188 },
189 ],
190 &quot;argumentText&quot;: &quot;A String&quot;, # Plain-text body of the message with all bot mentions stripped out.
191 &quot;cards&quot;: [ # Rich, formatted and interactive cards that can be used to display UI
192 # elements such as: formatted texts, buttons, clickable images. Cards are
193 # normally displayed below the plain-text body of the message.
194 { # A card is a UI element that can contain UI widgets such as texts, images.
195 &quot;name&quot;: &quot;A String&quot;, # Name of the card.
196 &quot;cardActions&quot;: [ # The actions of this card.
197 { # A card action is
198 # the action associated with the card. For an invoice card, a
199 # typical action would be: delete invoice, email invoice or open the
200 # invoice in browser.
201 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action for this action item.
202 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
203 # For example, an Apps Script can be invoked to handle the form.
204 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
205 # form submission. This information is echoed back to the bot as part of
206 # the card click event. The same method name can be used for several
207 # elements that trigger a common behavior if desired.
208 &quot;parameters&quot;: [ # List of action parameters.
209 { # List of string parameters to supply when the action method is invoked.
210 # For example, consider three snooze buttons: snooze now, snooze 1 day,
211 # snooze next week. You might use action method = snooze(), passing the
212 # snooze type and snooze time in the list of string parameters.
213 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
214 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
215 },
216 ],
217 },
218 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
219 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
220 },
221 },
222 &quot;actionLabel&quot;: &quot;A String&quot;, # The label used to be displayed in the action menu item.
223 },
224 ],
225 &quot;sections&quot;: [ # Sections are separated by a line divider.
226 { # A section contains a collection of widgets that are rendered
227 # (vertically) in the order that they are specified. Across all platforms,
228 # cards have a narrow fixed width, so
229 # there is currently no need for layout properties (e.g. float).
230 &quot;widgets&quot;: [ # A section must contain at least 1 widget.
231 { # A widget is a UI element that presents texts, images, etc.
232 &quot;textParagraph&quot;: { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
233 &quot;text&quot;: &quot;A String&quot;,
234 },
235 &quot;buttons&quot;: [ # A list of buttons. Buttons is also oneof data and only one of these
236 # fields should be set.
237 { # A button. Can be a text button or an image button.
238 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
239 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
240 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
241 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
242 # For example, an Apps Script can be invoked to handle the form.
243 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
244 # form submission. This information is echoed back to the bot as part of
245 # the card click event. The same method name can be used for several
246 # elements that trigger a common behavior if desired.
247 &quot;parameters&quot;: [ # List of action parameters.
248 { # List of string parameters to supply when the action method is invoked.
249 # For example, consider three snooze buttons: snooze now, snooze 1 day,
250 # snooze next week. You might use action method = snooze(), passing the
251 # snooze type and snooze time in the list of string parameters.
252 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
253 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
254 },
255 ],
256 },
257 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
258 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
259 },
260 },
261 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
262 # Default value will be provided if developers don&#x27;t specify.
263 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
264 # API.
265 },
266 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
267 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
268 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
269 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
270 # For example, an Apps Script can be invoked to handle the form.
271 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
272 # form submission. This information is echoed back to the bot as part of
273 # the card click event. The same method name can be used for several
274 # elements that trigger a common behavior if desired.
275 &quot;parameters&quot;: [ # List of action parameters.
276 { # List of string parameters to supply when the action method is invoked.
277 # For example, consider three snooze buttons: snooze now, snooze 1 day,
278 # snooze next week. You might use action method = snooze(), passing the
279 # snooze type and snooze time in the list of string parameters.
280 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
281 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
282 },
283 ],
284 },
285 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
286 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
287 },
288 },
289 },
290 },
291 ],
292 &quot;keyValue&quot;: { # A UI element contains a key (label) and a value (content). And this # Display a key value item in this widget.
293 # element may also contain some actions such as onclick button.
294 &quot;button&quot;: { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
295 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
296 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
297 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
298 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
299 # For example, an Apps Script can be invoked to handle the form.
300 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
301 # form submission. This information is echoed back to the bot as part of
302 # the card click event. The same method name can be used for several
303 # elements that trigger a common behavior if desired.
304 &quot;parameters&quot;: [ # List of action parameters.
305 { # List of string parameters to supply when the action method is invoked.
306 # For example, consider three snooze buttons: snooze now, snooze 1 day,
307 # snooze next week. You might use action method = snooze(), passing the
308 # snooze type and snooze time in the list of string parameters.
309 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
310 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
311 },
312 ],
313 },
314 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
315 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
316 },
317 },
318 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
319 # Default value will be provided if developers don&#x27;t specify.
320 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
321 # API.
322 },
323 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
324 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
325 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
326 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
327 # For example, an Apps Script can be invoked to handle the form.
328 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
329 # form submission. This information is echoed back to the bot as part of
330 # the card click event. The same method name can be used for several
331 # elements that trigger a common behavior if desired.
332 &quot;parameters&quot;: [ # List of action parameters.
333 { # List of string parameters to supply when the action method is invoked.
334 # For example, consider three snooze buttons: snooze now, snooze 1 day,
335 # snooze next week. You might use action method = snooze(), passing the
336 # snooze type and snooze time in the list of string parameters.
337 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
338 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
339 },
340 ],
341 },
342 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
343 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
344 },
345 },
346 },
347 },
348 &quot;icon&quot;: &quot;A String&quot;, # An enum value that will be replaced by the Chat API with the
349 # corresponding icon image.
350 &quot;bottomLabel&quot;: &quot;A String&quot;, # The text of the bottom label. Formatted text supported.
351 &quot;contentMultiline&quot;: True or False, # If the content should be multiline.
352 &quot;topLabel&quot;: &quot;A String&quot;, # The text of the top label. Formatted text supported.
353 &quot;content&quot;: &quot;A String&quot;, # The text of the content. Formatted text supported and always required.
354 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region
355 # are clickable.
356 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
357 # For example, an Apps Script can be invoked to handle the form.
358 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
359 # form submission. This information is echoed back to the bot as part of
360 # the card click event. The same method name can be used for several
361 # elements that trigger a common behavior if desired.
362 &quot;parameters&quot;: [ # List of action parameters.
363 { # List of string parameters to supply when the action method is invoked.
364 # For example, consider three snooze buttons: snooze now, snooze 1 day,
365 # snooze next week. You might use action method = snooze(), passing the
366 # snooze type and snooze time in the list of string parameters.
367 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
368 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
369 },
370 ],
371 },
372 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
373 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
374 },
375 },
376 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
377 },
378 &quot;image&quot;: { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
379 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
380 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
381 # For example, an Apps Script can be invoked to handle the form.
382 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
383 # form submission. This information is echoed back to the bot as part of
384 # the card click event. The same method name can be used for several
385 # elements that trigger a common behavior if desired.
386 &quot;parameters&quot;: [ # List of action parameters.
387 { # List of string parameters to supply when the action method is invoked.
388 # For example, consider three snooze buttons: snooze now, snooze 1 day,
389 # snooze next week. You might use action method = snooze(), passing the
390 # snooze type and snooze time in the list of string parameters.
391 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
392 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
393 },
394 ],
395 },
396 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
397 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
398 },
399 },
400 &quot;aspectRatio&quot;: 3.14, # The aspect ratio of this image (width/height). This field allows clients
401 # to reserve the right height for the image while waiting for it to load.
402 # It&#x27;s not meant to override the native aspect ratio of the image.
403 # If unset, the server fills it by prefetching the image.
404 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image.
405 },
406 },
407 ],
408 &quot;header&quot;: &quot;A String&quot;, # The header of the section, text formatted supported.
409 },
410 ],
411 &quot;header&quot;: { # The header of the card. A header usually contains a title and an image.
412 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image in the card header.
413 &quot;imageStyle&quot;: &quot;A String&quot;, # The image&#x27;s type (e.g. square border or circular border).
414 &quot;title&quot;: &quot;A String&quot;, # The title must be specified. The header has a fixed height: if both a
415 # title and subtitle is specified, each will take up 1 line. If only the
416 # title is specified, it will take up both lines.
417 &quot;subtitle&quot;: &quot;A String&quot;, # The subtitle of the card header.
418 },
419 },
420 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700421 &quot;space&quot;: { # A room or DM in Hangouts Chat. # The space the message belongs to.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700422 &quot;displayName&quot;: &quot;A String&quot;, # Output only. The display name (only if the space is a room).
423 # Please note that this field might not be populated in direct messages
424 # between humans.
425 &quot;threaded&quot;: True or False, # Whether the messages are threaded in this space.
Bu Sun Kim65020912020-05-20 12:08:20 -0700426 &quot;name&quot;: &quot;A String&quot;, # Resource name of the space, in the form &quot;spaces/*&quot;.
427 #
428 # Example: spaces/AAAAMpdlehYs
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700429 &quot;type&quot;: &quot;A String&quot;, # Output only. The type of a space.
430 # This is deprecated. Use `single_user_bot_dm` instead.
431 &quot;singleUserBotDm&quot;: True or False, # Whether the space is a DM between a bot and a single human.
Bu Sun Kim65020912020-05-20 12:08:20 -0700432 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700433 &quot;thread&quot;: { # A thread in Hangouts Chat. # The thread the message belongs to.
434 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/threads/*&quot;.
435 #
436 # Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
437 },
438 &quot;fallbackText&quot;: &quot;A String&quot;, # A plain-text description of the message&#x27;s cards, used when the actual cards
439 # cannot be displayed (e.g. mobile notifications).
440 }
441
442 threadKey: string, Opaque thread identifier string that can be specified to group messages
443into a single thread. If this is the first message with a given thread
444identifier, a new thread is created. Subsequent messages with the same
445thread identifier will be posted into the same thread. This relieves bots
446and webhooks from having to store the Hangouts Chat thread ID of a thread (created earlier by them) to post
447further updates to it.
448
449Has no effect if thread field,
450corresponding to an existing thread, is set in message.
451 x__xgafv: string, V1 error format.
452 Allowed values
453 1 - v1 error format
454 2 - v2 error format
455
456Returns:
457 An object of the form:
458
459 { # A message in Hangouts Chat.
460 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/messages/*&quot;.
461 #
462 # Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
463 &quot;annotations&quot;: [ # Output only. Annotations associated with the text in this message.
464 { # Annotations associated with the plain-text body of the message.
465 #
466 # Example plain-text message body:
467 # ```
468 # Hello @FooBot how are you!&quot;
469 # ```
470 #
471 # The corresponding annotations metadata:
472 # ```
473 # &quot;annotations&quot;:[{
474 # &quot;type&quot;:&quot;USER_MENTION&quot;,
475 # &quot;startIndex&quot;:6,
476 # &quot;length&quot;:7,
477 # &quot;userMention&quot;: {
478 # &quot;user&quot;: {
479 # &quot;name&quot;:&quot;users/107946847022116401880&quot;,
480 # &quot;displayName&quot;:&quot;FooBot&quot;,
481 # &quot;avatarUrl&quot;:&quot;https://goo.gl/aeDtrS&quot;,
482 # &quot;type&quot;:&quot;BOT&quot;
483 # },
484 # &quot;type&quot;:&quot;MENTION&quot;
485 # }
486 # }]
487 # ```
488 &quot;startIndex&quot;: 42, # Start index (0-based, inclusive) in the plain-text message body this
489 # annotation corresponds to.
490 &quot;type&quot;: &quot;A String&quot;, # The type of this annotation.
491 &quot;length&quot;: 42, # Length of the substring in the plain-text message body this annotation
492 # corresponds to.
493 &quot;userMention&quot;: { # Annotation metadata for user mentions (@). # The metadata of user mention.
494 &quot;user&quot;: { # A user in Hangouts Chat. # The user mentioned.
495 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
496 &quot;type&quot;: &quot;A String&quot;, # User type.
497 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
498 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
499 },
500 &quot;type&quot;: &quot;A String&quot;, # The type of user mention.
501 },
502 },
503 ],
504 &quot;actionResponse&quot;: { # Parameters that a bot can use to configure how it&#x27;s response is posted. # Input only. Parameters that a bot can use to configure how its response is
505 # posted.
506 &quot;type&quot;: &quot;A String&quot;, # The type of bot response.
507 &quot;url&quot;: &quot;A String&quot;, # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
508 },
509 &quot;sender&quot;: { # A user in Hangouts Chat. # The user who created the message.
510 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
511 &quot;type&quot;: &quot;A String&quot;, # User type.
512 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
513 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
514 },
515 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the message was created in Hangouts Chat
516 # server.
517 &quot;text&quot;: &quot;A String&quot;, # Plain-text body of the message.
518 &quot;previewText&quot;: &quot;A String&quot;, # Text for generating preview chips. This text will not be displayed to the
519 # user, but any links to images, web pages, videos, etc. included here will
520 # generate preview chips.
521 &quot;attachment&quot;: [ # User uploaded attachment.
522 { # An attachment in Hangouts Chat.
523 &quot;thumbnailUri&quot;: &quot;A String&quot;, # Output only. The thumbnail URL which should be used to preview the
524 # attachment to a human user. Bots should not use this URL to download
525 # attachment content.
526 &quot;driveDataRef&quot;: { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
527 &quot;driveFileId&quot;: &quot;A String&quot;, # The id for the drive file, for use with the Drive API.
528 },
529 &quot;downloadUri&quot;: &quot;A String&quot;, # Output only. The download URL which should be used to allow a human user to
530 # download the attachment. Bots should not use this URL to download
531 # attachment content.
532 &quot;contentType&quot;: &quot;A String&quot;, # The content type (MIME type) of the file.
533 &quot;name&quot;: &quot;A String&quot;, # Resource name of the attachment, in the form
534 # &quot;spaces/*/messages/*/attachments/*&quot;.
535 &quot;source&quot;: &quot;A String&quot;, # The source of the attachment.
536 &quot;attachmentDataRef&quot;: { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to
537 # download the attachment data.
538 &quot;resourceName&quot;: &quot;A String&quot;, # The resource name of the attachment data. This is used with the media API
539 # to download the attachment data.
540 },
541 &quot;contentName&quot;: &quot;A String&quot;, # The original file name for the content, not the full path.
542 },
543 ],
544 &quot;argumentText&quot;: &quot;A String&quot;, # Plain-text body of the message with all bot mentions stripped out.
545 &quot;cards&quot;: [ # Rich, formatted and interactive cards that can be used to display UI
546 # elements such as: formatted texts, buttons, clickable images. Cards are
547 # normally displayed below the plain-text body of the message.
548 { # A card is a UI element that can contain UI widgets such as texts, images.
549 &quot;name&quot;: &quot;A String&quot;, # Name of the card.
550 &quot;cardActions&quot;: [ # The actions of this card.
551 { # A card action is
552 # the action associated with the card. For an invoice card, a
553 # typical action would be: delete invoice, email invoice or open the
554 # invoice in browser.
555 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action for this action item.
556 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
557 # For example, an Apps Script can be invoked to handle the form.
558 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
559 # form submission. This information is echoed back to the bot as part of
560 # the card click event. The same method name can be used for several
561 # elements that trigger a common behavior if desired.
562 &quot;parameters&quot;: [ # List of action parameters.
563 { # List of string parameters to supply when the action method is invoked.
564 # For example, consider three snooze buttons: snooze now, snooze 1 day,
565 # snooze next week. You might use action method = snooze(), passing the
566 # snooze type and snooze time in the list of string parameters.
567 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
568 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
569 },
570 ],
571 },
572 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
573 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
574 },
575 },
576 &quot;actionLabel&quot;: &quot;A String&quot;, # The label used to be displayed in the action menu item.
577 },
578 ],
579 &quot;sections&quot;: [ # Sections are separated by a line divider.
580 { # A section contains a collection of widgets that are rendered
581 # (vertically) in the order that they are specified. Across all platforms,
582 # cards have a narrow fixed width, so
583 # there is currently no need for layout properties (e.g. float).
584 &quot;widgets&quot;: [ # A section must contain at least 1 widget.
585 { # A widget is a UI element that presents texts, images, etc.
586 &quot;textParagraph&quot;: { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
587 &quot;text&quot;: &quot;A String&quot;,
588 },
589 &quot;buttons&quot;: [ # A list of buttons. Buttons is also oneof data and only one of these
590 # fields should be set.
591 { # A button. Can be a text button or an image button.
592 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
593 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
594 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
595 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
596 # For example, an Apps Script can be invoked to handle the form.
597 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
598 # form submission. This information is echoed back to the bot as part of
599 # the card click event. The same method name can be used for several
600 # elements that trigger a common behavior if desired.
601 &quot;parameters&quot;: [ # List of action parameters.
602 { # List of string parameters to supply when the action method is invoked.
603 # For example, consider three snooze buttons: snooze now, snooze 1 day,
604 # snooze next week. You might use action method = snooze(), passing the
605 # snooze type and snooze time in the list of string parameters.
606 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
607 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
608 },
609 ],
610 },
611 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
612 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
613 },
614 },
615 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
616 # Default value will be provided if developers don&#x27;t specify.
617 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
618 # API.
619 },
620 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
621 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
622 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
623 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
624 # For example, an Apps Script can be invoked to handle the form.
625 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
626 # form submission. This information is echoed back to the bot as part of
627 # the card click event. The same method name can be used for several
628 # elements that trigger a common behavior if desired.
629 &quot;parameters&quot;: [ # List of action parameters.
630 { # List of string parameters to supply when the action method is invoked.
631 # For example, consider three snooze buttons: snooze now, snooze 1 day,
632 # snooze next week. You might use action method = snooze(), passing the
633 # snooze type and snooze time in the list of string parameters.
634 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
635 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
636 },
637 ],
638 },
639 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
640 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
641 },
642 },
643 },
644 },
645 ],
646 &quot;keyValue&quot;: { # A UI element contains a key (label) and a value (content). And this # Display a key value item in this widget.
647 # element may also contain some actions such as onclick button.
648 &quot;button&quot;: { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
649 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
650 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
651 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
652 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
653 # For example, an Apps Script can be invoked to handle the form.
654 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
655 # form submission. This information is echoed back to the bot as part of
656 # the card click event. The same method name can be used for several
657 # elements that trigger a common behavior if desired.
658 &quot;parameters&quot;: [ # List of action parameters.
659 { # List of string parameters to supply when the action method is invoked.
660 # For example, consider three snooze buttons: snooze now, snooze 1 day,
661 # snooze next week. You might use action method = snooze(), passing the
662 # snooze type and snooze time in the list of string parameters.
663 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
664 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
665 },
666 ],
667 },
668 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
669 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
670 },
671 },
672 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
673 # Default value will be provided if developers don&#x27;t specify.
674 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
675 # API.
676 },
677 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
678 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
679 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
680 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
681 # For example, an Apps Script can be invoked to handle the form.
682 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
683 # form submission. This information is echoed back to the bot as part of
684 # the card click event. The same method name can be used for several
685 # elements that trigger a common behavior if desired.
686 &quot;parameters&quot;: [ # List of action parameters.
687 { # List of string parameters to supply when the action method is invoked.
688 # For example, consider three snooze buttons: snooze now, snooze 1 day,
689 # snooze next week. You might use action method = snooze(), passing the
690 # snooze type and snooze time in the list of string parameters.
691 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
692 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
693 },
694 ],
695 },
696 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
697 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
698 },
699 },
700 },
701 },
702 &quot;icon&quot;: &quot;A String&quot;, # An enum value that will be replaced by the Chat API with the
703 # corresponding icon image.
704 &quot;bottomLabel&quot;: &quot;A String&quot;, # The text of the bottom label. Formatted text supported.
705 &quot;contentMultiline&quot;: True or False, # If the content should be multiline.
706 &quot;topLabel&quot;: &quot;A String&quot;, # The text of the top label. Formatted text supported.
707 &quot;content&quot;: &quot;A String&quot;, # The text of the content. Formatted text supported and always required.
708 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region
709 # are clickable.
710 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
711 # For example, an Apps Script can be invoked to handle the form.
712 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
713 # form submission. This information is echoed back to the bot as part of
714 # the card click event. The same method name can be used for several
715 # elements that trigger a common behavior if desired.
716 &quot;parameters&quot;: [ # List of action parameters.
717 { # List of string parameters to supply when the action method is invoked.
718 # For example, consider three snooze buttons: snooze now, snooze 1 day,
719 # snooze next week. You might use action method = snooze(), passing the
720 # snooze type and snooze time in the list of string parameters.
721 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
722 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
723 },
724 ],
725 },
726 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
727 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
728 },
729 },
730 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
731 },
732 &quot;image&quot;: { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
733 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
734 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
735 # For example, an Apps Script can be invoked to handle the form.
736 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
737 # form submission. This information is echoed back to the bot as part of
738 # the card click event. The same method name can be used for several
739 # elements that trigger a common behavior if desired.
740 &quot;parameters&quot;: [ # List of action parameters.
741 { # List of string parameters to supply when the action method is invoked.
742 # For example, consider three snooze buttons: snooze now, snooze 1 day,
743 # snooze next week. You might use action method = snooze(), passing the
744 # snooze type and snooze time in the list of string parameters.
745 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
746 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
747 },
748 ],
749 },
750 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
751 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
752 },
753 },
754 &quot;aspectRatio&quot;: 3.14, # The aspect ratio of this image (width/height). This field allows clients
755 # to reserve the right height for the image while waiting for it to load.
756 # It&#x27;s not meant to override the native aspect ratio of the image.
757 # If unset, the server fills it by prefetching the image.
758 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image.
759 },
760 },
761 ],
762 &quot;header&quot;: &quot;A String&quot;, # The header of the section, text formatted supported.
763 },
764 ],
765 &quot;header&quot;: { # The header of the card. A header usually contains a title and an image.
766 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image in the card header.
767 &quot;imageStyle&quot;: &quot;A String&quot;, # The image&#x27;s type (e.g. square border or circular border).
768 &quot;title&quot;: &quot;A String&quot;, # The title must be specified. The header has a fixed height: if both a
769 # title and subtitle is specified, each will take up 1 line. If only the
770 # title is specified, it will take up both lines.
771 &quot;subtitle&quot;: &quot;A String&quot;, # The subtitle of the card header.
772 },
773 },
774 ],
775 &quot;space&quot;: { # A room or DM in Hangouts Chat. # The space the message belongs to.
776 &quot;displayName&quot;: &quot;A String&quot;, # Output only. The display name (only if the space is a room).
777 # Please note that this field might not be populated in direct messages
778 # between humans.
779 &quot;threaded&quot;: True or False, # Whether the messages are threaded in this space.
780 &quot;name&quot;: &quot;A String&quot;, # Resource name of the space, in the form &quot;spaces/*&quot;.
781 #
782 # Example: spaces/AAAAMpdlehYs
783 &quot;type&quot;: &quot;A String&quot;, # Output only. The type of a space.
784 # This is deprecated. Use `single_user_bot_dm` instead.
785 &quot;singleUserBotDm&quot;: True or False, # Whether the space is a DM between a bot and a single human.
786 },
787 &quot;thread&quot;: { # A thread in Hangouts Chat. # The thread the message belongs to.
788 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/threads/*&quot;.
789 #
790 # Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
791 },
792 &quot;fallbackText&quot;: &quot;A String&quot;, # A plain-text description of the message&#x27;s cards, used when the actual cards
793 # cannot be displayed (e.g. mobile notifications).
794 }</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700795</div>
796
797<div class="method">
798 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
799 <pre>Deletes a message.
800
801Args:
802 name: string, Required. Resource name of the message to be deleted, in the form
Bu Sun Kim65020912020-05-20 12:08:20 -0700803&quot;spaces/*/messages/*&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700804
805Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4 (required)
806 x__xgafv: string, V1 error format.
807 Allowed values
808 1 - v1 error format
809 2 - v2 error format
810
811Returns:
812 An object of the form:
813
814 { # A generic empty message that you can re-use to avoid defining duplicated
815 # empty messages in your APIs. A typical example is to use it as the request
816 # or the response type of an API method. For instance:
817 #
818 # service Foo {
819 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
820 # }
821 #
822 # The JSON representation for `Empty` is empty JSON object `{}`.
823 }</pre>
824</div>
825
826<div class="method">
827 <code class="details" id="get">get(name, x__xgafv=None)</code>
828 <pre>Returns a message.
829
830Args:
831 name: string, Required. Resource name of the message to be retrieved, in the form
Bu Sun Kim65020912020-05-20 12:08:20 -0700832&quot;spaces/*/messages/*&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700833
834Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4 (required)
835 x__xgafv: string, V1 error format.
836 Allowed values
837 1 - v1 error format
838 2 - v2 error format
839
840Returns:
841 An object of the form:
842
843 { # A message in Hangouts Chat.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700844 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/messages/*&quot;.
Bu Sun Kim65020912020-05-20 12:08:20 -0700845 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700846 # Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
847 &quot;annotations&quot;: [ # Output only. Annotations associated with the text in this message.
848 { # Annotations associated with the plain-text body of the message.
849 #
850 # Example plain-text message body:
851 # ```
852 # Hello @FooBot how are you!&quot;
853 # ```
854 #
855 # The corresponding annotations metadata:
856 # ```
857 # &quot;annotations&quot;:[{
858 # &quot;type&quot;:&quot;USER_MENTION&quot;,
859 # &quot;startIndex&quot;:6,
860 # &quot;length&quot;:7,
861 # &quot;userMention&quot;: {
862 # &quot;user&quot;: {
863 # &quot;name&quot;:&quot;users/107946847022116401880&quot;,
864 # &quot;displayName&quot;:&quot;FooBot&quot;,
865 # &quot;avatarUrl&quot;:&quot;https://goo.gl/aeDtrS&quot;,
866 # &quot;type&quot;:&quot;BOT&quot;
867 # },
868 # &quot;type&quot;:&quot;MENTION&quot;
869 # }
870 # }]
871 # ```
872 &quot;startIndex&quot;: 42, # Start index (0-based, inclusive) in the plain-text message body this
873 # annotation corresponds to.
874 &quot;type&quot;: &quot;A String&quot;, # The type of this annotation.
875 &quot;length&quot;: 42, # Length of the substring in the plain-text message body this annotation
876 # corresponds to.
877 &quot;userMention&quot;: { # Annotation metadata for user mentions (@). # The metadata of user mention.
878 &quot;user&quot;: { # A user in Hangouts Chat. # The user mentioned.
879 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
880 &quot;type&quot;: &quot;A String&quot;, # User type.
881 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
882 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
883 },
884 &quot;type&quot;: &quot;A String&quot;, # The type of user mention.
885 },
886 },
887 ],
888 &quot;actionResponse&quot;: { # Parameters that a bot can use to configure how it&#x27;s response is posted. # Input only. Parameters that a bot can use to configure how its response is
889 # posted.
890 &quot;type&quot;: &quot;A String&quot;, # The type of bot response.
891 &quot;url&quot;: &quot;A String&quot;, # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
892 },
893 &quot;sender&quot;: { # A user in Hangouts Chat. # The user who created the message.
894 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
895 &quot;type&quot;: &quot;A String&quot;, # User type.
896 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
897 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
898 },
899 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the message was created in Hangouts Chat
900 # server.
901 &quot;text&quot;: &quot;A String&quot;, # Plain-text body of the message.
902 &quot;previewText&quot;: &quot;A String&quot;, # Text for generating preview chips. This text will not be displayed to the
903 # user, but any links to images, web pages, videos, etc. included here will
904 # generate preview chips.
905 &quot;attachment&quot;: [ # User uploaded attachment.
906 { # An attachment in Hangouts Chat.
907 &quot;thumbnailUri&quot;: &quot;A String&quot;, # Output only. The thumbnail URL which should be used to preview the
908 # attachment to a human user. Bots should not use this URL to download
909 # attachment content.
910 &quot;driveDataRef&quot;: { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
911 &quot;driveFileId&quot;: &quot;A String&quot;, # The id for the drive file, for use with the Drive API.
912 },
913 &quot;downloadUri&quot;: &quot;A String&quot;, # Output only. The download URL which should be used to allow a human user to
914 # download the attachment. Bots should not use this URL to download
915 # attachment content.
916 &quot;contentType&quot;: &quot;A String&quot;, # The content type (MIME type) of the file.
917 &quot;name&quot;: &quot;A String&quot;, # Resource name of the attachment, in the form
918 # &quot;spaces/*/messages/*/attachments/*&quot;.
919 &quot;source&quot;: &quot;A String&quot;, # The source of the attachment.
920 &quot;attachmentDataRef&quot;: { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to
921 # download the attachment data.
922 &quot;resourceName&quot;: &quot;A String&quot;, # The resource name of the attachment data. This is used with the media API
923 # to download the attachment data.
924 },
925 &quot;contentName&quot;: &quot;A String&quot;, # The original file name for the content, not the full path.
926 },
927 ],
928 &quot;argumentText&quot;: &quot;A String&quot;, # Plain-text body of the message with all bot mentions stripped out.
929 &quot;cards&quot;: [ # Rich, formatted and interactive cards that can be used to display UI
930 # elements such as: formatted texts, buttons, clickable images. Cards are
931 # normally displayed below the plain-text body of the message.
932 { # A card is a UI element that can contain UI widgets such as texts, images.
933 &quot;name&quot;: &quot;A String&quot;, # Name of the card.
934 &quot;cardActions&quot;: [ # The actions of this card.
935 { # A card action is
936 # the action associated with the card. For an invoice card, a
937 # typical action would be: delete invoice, email invoice or open the
938 # invoice in browser.
939 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action for this action item.
940 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
941 # For example, an Apps Script can be invoked to handle the form.
942 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
943 # form submission. This information is echoed back to the bot as part of
944 # the card click event. The same method name can be used for several
945 # elements that trigger a common behavior if desired.
946 &quot;parameters&quot;: [ # List of action parameters.
947 { # List of string parameters to supply when the action method is invoked.
948 # For example, consider three snooze buttons: snooze now, snooze 1 day,
949 # snooze next week. You might use action method = snooze(), passing the
950 # snooze type and snooze time in the list of string parameters.
951 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
952 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
953 },
954 ],
955 },
956 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
957 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
958 },
959 },
960 &quot;actionLabel&quot;: &quot;A String&quot;, # The label used to be displayed in the action menu item.
961 },
962 ],
963 &quot;sections&quot;: [ # Sections are separated by a line divider.
964 { # A section contains a collection of widgets that are rendered
965 # (vertically) in the order that they are specified. Across all platforms,
966 # cards have a narrow fixed width, so
967 # there is currently no need for layout properties (e.g. float).
968 &quot;widgets&quot;: [ # A section must contain at least 1 widget.
969 { # A widget is a UI element that presents texts, images, etc.
970 &quot;textParagraph&quot;: { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
971 &quot;text&quot;: &quot;A String&quot;,
972 },
973 &quot;buttons&quot;: [ # A list of buttons. Buttons is also oneof data and only one of these
974 # fields should be set.
975 { # A button. Can be a text button or an image button.
976 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
977 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
978 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
979 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
980 # For example, an Apps Script can be invoked to handle the form.
981 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
982 # form submission. This information is echoed back to the bot as part of
983 # the card click event. The same method name can be used for several
984 # elements that trigger a common behavior if desired.
985 &quot;parameters&quot;: [ # List of action parameters.
986 { # List of string parameters to supply when the action method is invoked.
987 # For example, consider three snooze buttons: snooze now, snooze 1 day,
988 # snooze next week. You might use action method = snooze(), passing the
989 # snooze type and snooze time in the list of string parameters.
990 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
991 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
992 },
993 ],
994 },
995 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
996 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
997 },
998 },
999 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
1000 # Default value will be provided if developers don&#x27;t specify.
1001 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
1002 # API.
1003 },
1004 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
1005 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
1006 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
1007 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1008 # For example, an Apps Script can be invoked to handle the form.
1009 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1010 # form submission. This information is echoed back to the bot as part of
1011 # the card click event. The same method name can be used for several
1012 # elements that trigger a common behavior if desired.
1013 &quot;parameters&quot;: [ # List of action parameters.
1014 { # List of string parameters to supply when the action method is invoked.
1015 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1016 # snooze next week. You might use action method = snooze(), passing the
1017 # snooze type and snooze time in the list of string parameters.
1018 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1019 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1020 },
1021 ],
1022 },
1023 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1024 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1025 },
1026 },
1027 },
1028 },
1029 ],
1030 &quot;keyValue&quot;: { # A UI element contains a key (label) and a value (content). And this # Display a key value item in this widget.
1031 # element may also contain some actions such as onclick button.
1032 &quot;button&quot;: { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
1033 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
1034 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1035 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1036 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1037 # For example, an Apps Script can be invoked to handle the form.
1038 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1039 # form submission. This information is echoed back to the bot as part of
1040 # the card click event. The same method name can be used for several
1041 # elements that trigger a common behavior if desired.
1042 &quot;parameters&quot;: [ # List of action parameters.
1043 { # List of string parameters to supply when the action method is invoked.
1044 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1045 # snooze next week. You might use action method = snooze(), passing the
1046 # snooze type and snooze time in the list of string parameters.
1047 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1048 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1049 },
1050 ],
1051 },
1052 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1053 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1054 },
1055 },
1056 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
1057 # Default value will be provided if developers don&#x27;t specify.
1058 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
1059 # API.
1060 },
1061 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
1062 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
1063 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
1064 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1065 # For example, an Apps Script can be invoked to handle the form.
1066 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1067 # form submission. This information is echoed back to the bot as part of
1068 # the card click event. The same method name can be used for several
1069 # elements that trigger a common behavior if desired.
1070 &quot;parameters&quot;: [ # List of action parameters.
1071 { # List of string parameters to supply when the action method is invoked.
1072 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1073 # snooze next week. You might use action method = snooze(), passing the
1074 # snooze type and snooze time in the list of string parameters.
1075 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1076 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1077 },
1078 ],
1079 },
1080 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1081 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1082 },
1083 },
1084 },
1085 },
1086 &quot;icon&quot;: &quot;A String&quot;, # An enum value that will be replaced by the Chat API with the
1087 # corresponding icon image.
1088 &quot;bottomLabel&quot;: &quot;A String&quot;, # The text of the bottom label. Formatted text supported.
1089 &quot;contentMultiline&quot;: True or False, # If the content should be multiline.
1090 &quot;topLabel&quot;: &quot;A String&quot;, # The text of the top label. Formatted text supported.
1091 &quot;content&quot;: &quot;A String&quot;, # The text of the content. Formatted text supported and always required.
1092 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region
1093 # are clickable.
1094 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1095 # For example, an Apps Script can be invoked to handle the form.
1096 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1097 # form submission. This information is echoed back to the bot as part of
1098 # the card click event. The same method name can be used for several
1099 # elements that trigger a common behavior if desired.
1100 &quot;parameters&quot;: [ # List of action parameters.
1101 { # List of string parameters to supply when the action method is invoked.
1102 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1103 # snooze next week. You might use action method = snooze(), passing the
1104 # snooze type and snooze time in the list of string parameters.
1105 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1106 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1107 },
1108 ],
1109 },
1110 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1111 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1112 },
1113 },
1114 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1115 },
1116 &quot;image&quot;: { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
1117 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1118 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1119 # For example, an Apps Script can be invoked to handle the form.
1120 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1121 # form submission. This information is echoed back to the bot as part of
1122 # the card click event. The same method name can be used for several
1123 # elements that trigger a common behavior if desired.
1124 &quot;parameters&quot;: [ # List of action parameters.
1125 { # List of string parameters to supply when the action method is invoked.
1126 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1127 # snooze next week. You might use action method = snooze(), passing the
1128 # snooze type and snooze time in the list of string parameters.
1129 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1130 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1131 },
1132 ],
1133 },
1134 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1135 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1136 },
1137 },
1138 &quot;aspectRatio&quot;: 3.14, # The aspect ratio of this image (width/height). This field allows clients
1139 # to reserve the right height for the image while waiting for it to load.
1140 # It&#x27;s not meant to override the native aspect ratio of the image.
1141 # If unset, the server fills it by prefetching the image.
1142 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image.
1143 },
1144 },
1145 ],
1146 &quot;header&quot;: &quot;A String&quot;, # The header of the section, text formatted supported.
1147 },
1148 ],
1149 &quot;header&quot;: { # The header of the card. A header usually contains a title and an image.
1150 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image in the card header.
1151 &quot;imageStyle&quot;: &quot;A String&quot;, # The image&#x27;s type (e.g. square border or circular border).
1152 &quot;title&quot;: &quot;A String&quot;, # The title must be specified. The header has a fixed height: if both a
1153 # title and subtitle is specified, each will take up 1 line. If only the
1154 # title is specified, it will take up both lines.
1155 &quot;subtitle&quot;: &quot;A String&quot;, # The subtitle of the card header.
1156 },
1157 },
1158 ],
1159 &quot;space&quot;: { # A room or DM in Hangouts Chat. # The space the message belongs to.
1160 &quot;displayName&quot;: &quot;A String&quot;, # Output only. The display name (only if the space is a room).
1161 # Please note that this field might not be populated in direct messages
1162 # between humans.
1163 &quot;threaded&quot;: True or False, # Whether the messages are threaded in this space.
1164 &quot;name&quot;: &quot;A String&quot;, # Resource name of the space, in the form &quot;spaces/*&quot;.
1165 #
1166 # Example: spaces/AAAAMpdlehYs
1167 &quot;type&quot;: &quot;A String&quot;, # Output only. The type of a space.
1168 # This is deprecated. Use `single_user_bot_dm` instead.
1169 &quot;singleUserBotDm&quot;: True or False, # Whether the space is a DM between a bot and a single human.
1170 },
1171 &quot;thread&quot;: { # A thread in Hangouts Chat. # The thread the message belongs to.
1172 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/threads/*&quot;.
1173 #
1174 # Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
1175 },
1176 &quot;fallbackText&quot;: &quot;A String&quot;, # A plain-text description of the message&#x27;s cards, used when the actual cards
1177 # cannot be displayed (e.g. mobile notifications).
1178 }</pre>
1179</div>
1180
1181<div class="method">
1182 <code class="details" id="update">update(name, body=None, updateMask=None, x__xgafv=None)</code>
1183 <pre>Updates a message.
1184
1185Args:
1186 name: string, Resource name, in the form &quot;spaces/*/messages/*&quot;.
1187
1188Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4 (required)
1189 body: object, The request body.
1190 The object takes the form of:
1191
1192{ # A message in Hangouts Chat.
1193 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/messages/*&quot;.
1194 #
1195 # Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
Bu Sun Kim65020912020-05-20 12:08:20 -07001196 &quot;annotations&quot;: [ # Output only. Annotations associated with the text in this message.
1197 { # Annotations associated with the plain-text body of the message.
1198 #
1199 # Example plain-text message body:
1200 # ```
1201 # Hello @FooBot how are you!&quot;
1202 # ```
1203 #
1204 # The corresponding annotations metadata:
1205 # ```
1206 # &quot;annotations&quot;:[{
1207 # &quot;type&quot;:&quot;USER_MENTION&quot;,
1208 # &quot;startIndex&quot;:6,
1209 # &quot;length&quot;:7,
1210 # &quot;userMention&quot;: {
1211 # &quot;user&quot;: {
1212 # &quot;name&quot;:&quot;users/107946847022116401880&quot;,
1213 # &quot;displayName&quot;:&quot;FooBot&quot;,
1214 # &quot;avatarUrl&quot;:&quot;https://goo.gl/aeDtrS&quot;,
1215 # &quot;type&quot;:&quot;BOT&quot;
1216 # },
1217 # &quot;type&quot;:&quot;MENTION&quot;
1218 # }
1219 # }]
1220 # ```
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001221 &quot;startIndex&quot;: 42, # Start index (0-based, inclusive) in the plain-text message body this
1222 # annotation corresponds to.
1223 &quot;type&quot;: &quot;A String&quot;, # The type of this annotation.
1224 &quot;length&quot;: 42, # Length of the substring in the plain-text message body this annotation
1225 # corresponds to.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001226 &quot;userMention&quot;: { # Annotation metadata for user mentions (@). # The metadata of user mention.
1227 &quot;user&quot;: { # A user in Hangouts Chat. # The user mentioned.
1228 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001229 &quot;type&quot;: &quot;A String&quot;, # User type.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001230 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001231 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
1232 },
1233 &quot;type&quot;: &quot;A String&quot;, # The type of user mention.
1234 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001235 },
1236 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001237 &quot;actionResponse&quot;: { # Parameters that a bot can use to configure how it&#x27;s response is posted. # Input only. Parameters that a bot can use to configure how its response is
1238 # posted.
1239 &quot;type&quot;: &quot;A String&quot;, # The type of bot response.
1240 &quot;url&quot;: &quot;A String&quot;, # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
1241 },
1242 &quot;sender&quot;: { # A user in Hangouts Chat. # The user who created the message.
1243 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
1244 &quot;type&quot;: &quot;A String&quot;, # User type.
1245 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
1246 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
1247 },
1248 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the message was created in Hangouts Chat
1249 # server.
1250 &quot;text&quot;: &quot;A String&quot;, # Plain-text body of the message.
Bu Sun Kim65020912020-05-20 12:08:20 -07001251 &quot;previewText&quot;: &quot;A String&quot;, # Text for generating preview chips. This text will not be displayed to the
1252 # user, but any links to images, web pages, videos, etc. included here will
1253 # generate preview chips.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001254 &quot;attachment&quot;: [ # User uploaded attachment.
1255 { # An attachment in Hangouts Chat.
1256 &quot;thumbnailUri&quot;: &quot;A String&quot;, # Output only. The thumbnail URL which should be used to preview the
1257 # attachment to a human user. Bots should not use this URL to download
1258 # attachment content.
1259 &quot;driveDataRef&quot;: { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
1260 &quot;driveFileId&quot;: &quot;A String&quot;, # The id for the drive file, for use with the Drive API.
1261 },
1262 &quot;downloadUri&quot;: &quot;A String&quot;, # Output only. The download URL which should be used to allow a human user to
1263 # download the attachment. Bots should not use this URL to download
1264 # attachment content.
1265 &quot;contentType&quot;: &quot;A String&quot;, # The content type (MIME type) of the file.
1266 &quot;name&quot;: &quot;A String&quot;, # Resource name of the attachment, in the form
1267 # &quot;spaces/*/messages/*/attachments/*&quot;.
1268 &quot;source&quot;: &quot;A String&quot;, # The source of the attachment.
1269 &quot;attachmentDataRef&quot;: { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to
1270 # download the attachment data.
1271 &quot;resourceName&quot;: &quot;A String&quot;, # The resource name of the attachment data. This is used with the media API
1272 # to download the attachment data.
1273 },
1274 &quot;contentName&quot;: &quot;A String&quot;, # The original file name for the content, not the full path.
1275 },
1276 ],
1277 &quot;argumentText&quot;: &quot;A String&quot;, # Plain-text body of the message with all bot mentions stripped out.
1278 &quot;cards&quot;: [ # Rich, formatted and interactive cards that can be used to display UI
1279 # elements such as: formatted texts, buttons, clickable images. Cards are
1280 # normally displayed below the plain-text body of the message.
1281 { # A card is a UI element that can contain UI widgets such as texts, images.
1282 &quot;name&quot;: &quot;A String&quot;, # Name of the card.
1283 &quot;cardActions&quot;: [ # The actions of this card.
1284 { # A card action is
1285 # the action associated with the card. For an invoice card, a
1286 # typical action would be: delete invoice, email invoice or open the
1287 # invoice in browser.
1288 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action for this action item.
1289 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1290 # For example, an Apps Script can be invoked to handle the form.
1291 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1292 # form submission. This information is echoed back to the bot as part of
1293 # the card click event. The same method name can be used for several
1294 # elements that trigger a common behavior if desired.
1295 &quot;parameters&quot;: [ # List of action parameters.
1296 { # List of string parameters to supply when the action method is invoked.
1297 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1298 # snooze next week. You might use action method = snooze(), passing the
1299 # snooze type and snooze time in the list of string parameters.
1300 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1301 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1302 },
1303 ],
1304 },
1305 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1306 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1307 },
1308 },
1309 &quot;actionLabel&quot;: &quot;A String&quot;, # The label used to be displayed in the action menu item.
1310 },
1311 ],
1312 &quot;sections&quot;: [ # Sections are separated by a line divider.
1313 { # A section contains a collection of widgets that are rendered
1314 # (vertically) in the order that they are specified. Across all platforms,
1315 # cards have a narrow fixed width, so
1316 # there is currently no need for layout properties (e.g. float).
1317 &quot;widgets&quot;: [ # A section must contain at least 1 widget.
1318 { # A widget is a UI element that presents texts, images, etc.
1319 &quot;textParagraph&quot;: { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
1320 &quot;text&quot;: &quot;A String&quot;,
1321 },
1322 &quot;buttons&quot;: [ # A list of buttons. Buttons is also oneof data and only one of these
1323 # fields should be set.
1324 { # A button. Can be a text button or an image button.
1325 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
1326 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1327 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1328 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1329 # For example, an Apps Script can be invoked to handle the form.
1330 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1331 # form submission. This information is echoed back to the bot as part of
1332 # the card click event. The same method name can be used for several
1333 # elements that trigger a common behavior if desired.
1334 &quot;parameters&quot;: [ # List of action parameters.
1335 { # List of string parameters to supply when the action method is invoked.
1336 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1337 # snooze next week. You might use action method = snooze(), passing the
1338 # snooze type and snooze time in the list of string parameters.
1339 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1340 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1341 },
1342 ],
1343 },
1344 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1345 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1346 },
1347 },
1348 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
1349 # Default value will be provided if developers don&#x27;t specify.
1350 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
1351 # API.
1352 },
1353 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
1354 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
1355 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
1356 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1357 # For example, an Apps Script can be invoked to handle the form.
1358 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1359 # form submission. This information is echoed back to the bot as part of
1360 # the card click event. The same method name can be used for several
1361 # elements that trigger a common behavior if desired.
1362 &quot;parameters&quot;: [ # List of action parameters.
1363 { # List of string parameters to supply when the action method is invoked.
1364 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1365 # snooze next week. You might use action method = snooze(), passing the
1366 # snooze type and snooze time in the list of string parameters.
1367 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1368 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1369 },
1370 ],
1371 },
1372 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1373 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1374 },
1375 },
1376 },
1377 },
1378 ],
1379 &quot;keyValue&quot;: { # A UI element contains a key (label) and a value (content). And this # Display a key value item in this widget.
1380 # element may also contain some actions such as onclick button.
1381 &quot;button&quot;: { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
1382 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
1383 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1384 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1385 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1386 # For example, an Apps Script can be invoked to handle the form.
1387 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1388 # form submission. This information is echoed back to the bot as part of
1389 # the card click event. The same method name can be used for several
1390 # elements that trigger a common behavior if desired.
1391 &quot;parameters&quot;: [ # List of action parameters.
1392 { # List of string parameters to supply when the action method is invoked.
1393 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1394 # snooze next week. You might use action method = snooze(), passing the
1395 # snooze type and snooze time in the list of string parameters.
1396 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1397 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1398 },
1399 ],
1400 },
1401 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1402 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1403 },
1404 },
1405 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
1406 # Default value will be provided if developers don&#x27;t specify.
1407 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
1408 # API.
1409 },
1410 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
1411 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
1412 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
1413 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1414 # For example, an Apps Script can be invoked to handle the form.
1415 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1416 # form submission. This information is echoed back to the bot as part of
1417 # the card click event. The same method name can be used for several
1418 # elements that trigger a common behavior if desired.
1419 &quot;parameters&quot;: [ # List of action parameters.
1420 { # List of string parameters to supply when the action method is invoked.
1421 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1422 # snooze next week. You might use action method = snooze(), passing the
1423 # snooze type and snooze time in the list of string parameters.
1424 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1425 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1426 },
1427 ],
1428 },
1429 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1430 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1431 },
1432 },
1433 },
1434 },
1435 &quot;icon&quot;: &quot;A String&quot;, # An enum value that will be replaced by the Chat API with the
1436 # corresponding icon image.
1437 &quot;bottomLabel&quot;: &quot;A String&quot;, # The text of the bottom label. Formatted text supported.
1438 &quot;contentMultiline&quot;: True or False, # If the content should be multiline.
1439 &quot;topLabel&quot;: &quot;A String&quot;, # The text of the top label. Formatted text supported.
1440 &quot;content&quot;: &quot;A String&quot;, # The text of the content. Formatted text supported and always required.
1441 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region
1442 # are clickable.
1443 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1444 # For example, an Apps Script can be invoked to handle the form.
1445 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1446 # form submission. This information is echoed back to the bot as part of
1447 # the card click event. The same method name can be used for several
1448 # elements that trigger a common behavior if desired.
1449 &quot;parameters&quot;: [ # List of action parameters.
1450 { # List of string parameters to supply when the action method is invoked.
1451 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1452 # snooze next week. You might use action method = snooze(), passing the
1453 # snooze type and snooze time in the list of string parameters.
1454 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1455 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1456 },
1457 ],
1458 },
1459 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1460 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1461 },
1462 },
1463 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1464 },
1465 &quot;image&quot;: { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
1466 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1467 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1468 # For example, an Apps Script can be invoked to handle the form.
1469 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1470 # form submission. This information is echoed back to the bot as part of
1471 # the card click event. The same method name can be used for several
1472 # elements that trigger a common behavior if desired.
1473 &quot;parameters&quot;: [ # List of action parameters.
1474 { # List of string parameters to supply when the action method is invoked.
1475 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1476 # snooze next week. You might use action method = snooze(), passing the
1477 # snooze type and snooze time in the list of string parameters.
1478 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1479 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1480 },
1481 ],
1482 },
1483 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1484 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1485 },
1486 },
1487 &quot;aspectRatio&quot;: 3.14, # The aspect ratio of this image (width/height). This field allows clients
1488 # to reserve the right height for the image while waiting for it to load.
1489 # It&#x27;s not meant to override the native aspect ratio of the image.
1490 # If unset, the server fills it by prefetching the image.
1491 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image.
1492 },
1493 },
1494 ],
1495 &quot;header&quot;: &quot;A String&quot;, # The header of the section, text formatted supported.
1496 },
1497 ],
1498 &quot;header&quot;: { # The header of the card. A header usually contains a title and an image.
1499 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image in the card header.
1500 &quot;imageStyle&quot;: &quot;A String&quot;, # The image&#x27;s type (e.g. square border or circular border).
1501 &quot;title&quot;: &quot;A String&quot;, # The title must be specified. The header has a fixed height: if both a
1502 # title and subtitle is specified, each will take up 1 line. If only the
1503 # title is specified, it will take up both lines.
1504 &quot;subtitle&quot;: &quot;A String&quot;, # The subtitle of the card header.
1505 },
1506 },
1507 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001508 &quot;space&quot;: { # A room or DM in Hangouts Chat. # The space the message belongs to.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001509 &quot;displayName&quot;: &quot;A String&quot;, # Output only. The display name (only if the space is a room).
1510 # Please note that this field might not be populated in direct messages
1511 # between humans.
1512 &quot;threaded&quot;: True or False, # Whether the messages are threaded in this space.
Bu Sun Kim65020912020-05-20 12:08:20 -07001513 &quot;name&quot;: &quot;A String&quot;, # Resource name of the space, in the form &quot;spaces/*&quot;.
1514 #
1515 # Example: spaces/AAAAMpdlehYs
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001516 &quot;type&quot;: &quot;A String&quot;, # Output only. The type of a space.
1517 # This is deprecated. Use `single_user_bot_dm` instead.
1518 &quot;singleUserBotDm&quot;: True or False, # Whether the space is a DM between a bot and a single human.
Bu Sun Kim65020912020-05-20 12:08:20 -07001519 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001520 &quot;thread&quot;: { # A thread in Hangouts Chat. # The thread the message belongs to.
1521 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/threads/*&quot;.
1522 #
1523 # Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001524 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001525 &quot;fallbackText&quot;: &quot;A String&quot;, # A plain-text description of the message&#x27;s cards, used when the actual cards
1526 # cannot be displayed (e.g. mobile notifications).
1527 }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001528
Dan O'Mearadd494642020-05-01 07:42:23 -07001529 updateMask: string, Required. The field paths to be updated, comma separated if there are
1530multiple.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001531
Dan O'Mearadd494642020-05-01 07:42:23 -07001532Currently supported field paths:
1533* text
1534* cards
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001535 x__xgafv: string, V1 error format.
1536 Allowed values
1537 1 - v1 error format
1538 2 - v2 error format
1539
1540Returns:
1541 An object of the form:
1542
1543 { # A message in Hangouts Chat.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001544 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/messages/*&quot;.
1545 #
1546 # Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
1547 &quot;annotations&quot;: [ # Output only. Annotations associated with the text in this message.
1548 { # Annotations associated with the plain-text body of the message.
1549 #
1550 # Example plain-text message body:
1551 # ```
1552 # Hello @FooBot how are you!&quot;
1553 # ```
1554 #
1555 # The corresponding annotations metadata:
1556 # ```
1557 # &quot;annotations&quot;:[{
1558 # &quot;type&quot;:&quot;USER_MENTION&quot;,
1559 # &quot;startIndex&quot;:6,
1560 # &quot;length&quot;:7,
1561 # &quot;userMention&quot;: {
1562 # &quot;user&quot;: {
1563 # &quot;name&quot;:&quot;users/107946847022116401880&quot;,
1564 # &quot;displayName&quot;:&quot;FooBot&quot;,
1565 # &quot;avatarUrl&quot;:&quot;https://goo.gl/aeDtrS&quot;,
1566 # &quot;type&quot;:&quot;BOT&quot;
1567 # },
1568 # &quot;type&quot;:&quot;MENTION&quot;
1569 # }
1570 # }]
1571 # ```
1572 &quot;startIndex&quot;: 42, # Start index (0-based, inclusive) in the plain-text message body this
1573 # annotation corresponds to.
1574 &quot;type&quot;: &quot;A String&quot;, # The type of this annotation.
1575 &quot;length&quot;: 42, # Length of the substring in the plain-text message body this annotation
1576 # corresponds to.
1577 &quot;userMention&quot;: { # Annotation metadata for user mentions (@). # The metadata of user mention.
1578 &quot;user&quot;: { # A user in Hangouts Chat. # The user mentioned.
1579 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
1580 &quot;type&quot;: &quot;A String&quot;, # User type.
1581 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
1582 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
Dan O'Mearadd494642020-05-01 07:42:23 -07001583 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001584 &quot;type&quot;: &quot;A String&quot;, # The type of user mention.
Dan O'Mearadd494642020-05-01 07:42:23 -07001585 },
1586 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001587 ],
1588 &quot;actionResponse&quot;: { # Parameters that a bot can use to configure how it&#x27;s response is posted. # Input only. Parameters that a bot can use to configure how its response is
1589 # posted.
1590 &quot;type&quot;: &quot;A String&quot;, # The type of bot response.
1591 &quot;url&quot;: &quot;A String&quot;, # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001592 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001593 &quot;sender&quot;: { # A user in Hangouts Chat. # The user who created the message.
1594 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the format &quot;users/*&quot;.
1595 &quot;type&quot;: &quot;A String&quot;, # User type.
1596 &quot;displayName&quot;: &quot;A String&quot;, # The user&#x27;s display name.
1597 &quot;domainId&quot;: &quot;A String&quot;, # Obfuscated domain information.
1598 },
1599 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the message was created in Hangouts Chat
1600 # server.
1601 &quot;text&quot;: &quot;A String&quot;, # Plain-text body of the message.
1602 &quot;previewText&quot;: &quot;A String&quot;, # Text for generating preview chips. This text will not be displayed to the
1603 # user, but any links to images, web pages, videos, etc. included here will
1604 # generate preview chips.
1605 &quot;attachment&quot;: [ # User uploaded attachment.
1606 { # An attachment in Hangouts Chat.
1607 &quot;thumbnailUri&quot;: &quot;A String&quot;, # Output only. The thumbnail URL which should be used to preview the
1608 # attachment to a human user. Bots should not use this URL to download
1609 # attachment content.
1610 &quot;driveDataRef&quot;: { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
1611 &quot;driveFileId&quot;: &quot;A String&quot;, # The id for the drive file, for use with the Drive API.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001612 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001613 &quot;downloadUri&quot;: &quot;A String&quot;, # Output only. The download URL which should be used to allow a human user to
1614 # download the attachment. Bots should not use this URL to download
1615 # attachment content.
1616 &quot;contentType&quot;: &quot;A String&quot;, # The content type (MIME type) of the file.
1617 &quot;name&quot;: &quot;A String&quot;, # Resource name of the attachment, in the form
1618 # &quot;spaces/*/messages/*/attachments/*&quot;.
1619 &quot;source&quot;: &quot;A String&quot;, # The source of the attachment.
1620 &quot;attachmentDataRef&quot;: { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to
1621 # download the attachment data.
1622 &quot;resourceName&quot;: &quot;A String&quot;, # The resource name of the attachment data. This is used with the media API
1623 # to download the attachment data.
1624 },
1625 &quot;contentName&quot;: &quot;A String&quot;, # The original file name for the content, not the full path.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001626 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001627 ],
1628 &quot;argumentText&quot;: &quot;A String&quot;, # Plain-text body of the message with all bot mentions stripped out.
1629 &quot;cards&quot;: [ # Rich, formatted and interactive cards that can be used to display UI
1630 # elements such as: formatted texts, buttons, clickable images. Cards are
1631 # normally displayed below the plain-text body of the message.
1632 { # A card is a UI element that can contain UI widgets such as texts, images.
1633 &quot;name&quot;: &quot;A String&quot;, # Name of the card.
1634 &quot;cardActions&quot;: [ # The actions of this card.
1635 { # A card action is
1636 # the action associated with the card. For an invoice card, a
1637 # typical action would be: delete invoice, email invoice or open the
1638 # invoice in browser.
1639 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action for this action item.
1640 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1641 # For example, an Apps Script can be invoked to handle the form.
1642 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1643 # form submission. This information is echoed back to the bot as part of
1644 # the card click event. The same method name can be used for several
1645 # elements that trigger a common behavior if desired.
1646 &quot;parameters&quot;: [ # List of action parameters.
1647 { # List of string parameters to supply when the action method is invoked.
1648 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1649 # snooze next week. You might use action method = snooze(), passing the
1650 # snooze type and snooze time in the list of string parameters.
1651 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1652 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1653 },
1654 ],
1655 },
1656 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1657 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1658 },
1659 },
1660 &quot;actionLabel&quot;: &quot;A String&quot;, # The label used to be displayed in the action menu item.
1661 },
1662 ],
1663 &quot;sections&quot;: [ # Sections are separated by a line divider.
1664 { # A section contains a collection of widgets that are rendered
1665 # (vertically) in the order that they are specified. Across all platforms,
1666 # cards have a narrow fixed width, so
1667 # there is currently no need for layout properties (e.g. float).
1668 &quot;widgets&quot;: [ # A section must contain at least 1 widget.
1669 { # A widget is a UI element that presents texts, images, etc.
1670 &quot;textParagraph&quot;: { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
1671 &quot;text&quot;: &quot;A String&quot;,
1672 },
1673 &quot;buttons&quot;: [ # A list of buttons. Buttons is also oneof data and only one of these
1674 # fields should be set.
1675 { # A button. Can be a text button or an image button.
1676 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
1677 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1678 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1679 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1680 # For example, an Apps Script can be invoked to handle the form.
1681 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1682 # form submission. This information is echoed back to the bot as part of
1683 # the card click event. The same method name can be used for several
1684 # elements that trigger a common behavior if desired.
1685 &quot;parameters&quot;: [ # List of action parameters.
1686 { # List of string parameters to supply when the action method is invoked.
1687 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1688 # snooze next week. You might use action method = snooze(), passing the
1689 # snooze type and snooze time in the list of string parameters.
1690 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1691 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1692 },
1693 ],
1694 },
1695 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1696 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1697 },
1698 },
1699 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
1700 # Default value will be provided if developers don&#x27;t specify.
1701 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
1702 # API.
1703 },
1704 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
1705 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
1706 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
1707 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1708 # For example, an Apps Script can be invoked to handle the form.
1709 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1710 # form submission. This information is echoed back to the bot as part of
1711 # the card click event. The same method name can be used for several
1712 # elements that trigger a common behavior if desired.
1713 &quot;parameters&quot;: [ # List of action parameters.
1714 { # List of string parameters to supply when the action method is invoked.
1715 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1716 # snooze next week. You might use action method = snooze(), passing the
1717 # snooze type and snooze time in the list of string parameters.
1718 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1719 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1720 },
1721 ],
1722 },
1723 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1724 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1725 },
1726 },
1727 },
1728 },
1729 ],
1730 &quot;keyValue&quot;: { # A UI element contains a key (label) and a value (content). And this # Display a key value item in this widget.
1731 # element may also contain some actions such as onclick button.
1732 &quot;button&quot;: { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
1733 &quot;imageButton&quot;: { # An image button with an onclick action. # A button with image and onclick action.
1734 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1735 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1736 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1737 # For example, an Apps Script can be invoked to handle the form.
1738 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1739 # form submission. This information is echoed back to the bot as part of
1740 # the card click event. The same method name can be used for several
1741 # elements that trigger a common behavior if desired.
1742 &quot;parameters&quot;: [ # List of action parameters.
1743 { # List of string parameters to supply when the action method is invoked.
1744 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1745 # snooze next week. You might use action method = snooze(), passing the
1746 # snooze type and snooze time in the list of string parameters.
1747 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1748 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1749 },
1750 ],
1751 },
1752 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1753 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1754 },
1755 },
1756 &quot;name&quot;: &quot;A String&quot;, # The name of this image_button which will be used for accessibility.
1757 # Default value will be provided if developers don&#x27;t specify.
1758 &quot;icon&quot;: &quot;A String&quot;, # The icon specified by an enum that indices to an icon provided by Chat
1759 # API.
1760 },
1761 &quot;textButton&quot;: { # A button with text and onclick action. # A button with text and onclick action.
1762 &quot;text&quot;: &quot;A String&quot;, # The text of the button.
1763 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action of the button.
1764 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1765 # For example, an Apps Script can be invoked to handle the form.
1766 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1767 # form submission. This information is echoed back to the bot as part of
1768 # the card click event. The same method name can be used for several
1769 # elements that trigger a common behavior if desired.
1770 &quot;parameters&quot;: [ # List of action parameters.
1771 { # List of string parameters to supply when the action method is invoked.
1772 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1773 # snooze next week. You might use action method = snooze(), passing the
1774 # snooze type and snooze time in the list of string parameters.
1775 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1776 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1777 },
1778 ],
1779 },
1780 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1781 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1782 },
1783 },
1784 },
1785 },
1786 &quot;icon&quot;: &quot;A String&quot;, # An enum value that will be replaced by the Chat API with the
1787 # corresponding icon image.
1788 &quot;bottomLabel&quot;: &quot;A String&quot;, # The text of the bottom label. Formatted text supported.
1789 &quot;contentMultiline&quot;: True or False, # If the content should be multiline.
1790 &quot;topLabel&quot;: &quot;A String&quot;, # The text of the top label. Formatted text supported.
1791 &quot;content&quot;: &quot;A String&quot;, # The text of the content. Formatted text supported and always required.
1792 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region
1793 # are clickable.
1794 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1795 # For example, an Apps Script can be invoked to handle the form.
1796 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1797 # form submission. This information is echoed back to the bot as part of
1798 # the card click event. The same method name can be used for several
1799 # elements that trigger a common behavior if desired.
1800 &quot;parameters&quot;: [ # List of action parameters.
1801 { # List of string parameters to supply when the action method is invoked.
1802 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1803 # snooze next week. You might use action method = snooze(), passing the
1804 # snooze type and snooze time in the list of string parameters.
1805 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1806 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1807 },
1808 ],
1809 },
1810 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1811 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1812 },
1813 },
1814 &quot;iconUrl&quot;: &quot;A String&quot;, # The icon specified by a URL.
1815 },
1816 &quot;image&quot;: { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
1817 &quot;onClick&quot;: { # An onclick action (e.g. open a link). # The onclick action.
1818 &quot;action&quot;: { # A form action describes the behavior when the form is submitted. # A form action will be trigger by this onclick if specified.
1819 # For example, an Apps Script can be invoked to handle the form.
1820 &quot;actionMethodName&quot;: &quot;A String&quot;, # The method name is used to identify which part of the form triggered the
1821 # form submission. This information is echoed back to the bot as part of
1822 # the card click event. The same method name can be used for several
1823 # elements that trigger a common behavior if desired.
1824 &quot;parameters&quot;: [ # List of action parameters.
1825 { # List of string parameters to supply when the action method is invoked.
1826 # For example, consider three snooze buttons: snooze now, snooze 1 day,
1827 # snooze next week. You might use action method = snooze(), passing the
1828 # snooze type and snooze time in the list of string parameters.
1829 &quot;value&quot;: &quot;A String&quot;, # The value of the parameter.
1830 &quot;key&quot;: &quot;A String&quot;, # The name of the parameter for the action script.
1831 },
1832 ],
1833 },
1834 &quot;openLink&quot;: { # A link that opens a new window. # This onclick triggers an open link action if specified.
1835 &quot;url&quot;: &quot;A String&quot;, # The URL to open.
1836 },
1837 },
1838 &quot;aspectRatio&quot;: 3.14, # The aspect ratio of this image (width/height). This field allows clients
1839 # to reserve the right height for the image while waiting for it to load.
1840 # It&#x27;s not meant to override the native aspect ratio of the image.
1841 # If unset, the server fills it by prefetching the image.
1842 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image.
1843 },
1844 },
1845 ],
1846 &quot;header&quot;: &quot;A String&quot;, # The header of the section, text formatted supported.
1847 },
1848 ],
1849 &quot;header&quot;: { # The header of the card. A header usually contains a title and an image.
1850 &quot;imageUrl&quot;: &quot;A String&quot;, # The URL of the image in the card header.
1851 &quot;imageStyle&quot;: &quot;A String&quot;, # The image&#x27;s type (e.g. square border or circular border).
1852 &quot;title&quot;: &quot;A String&quot;, # The title must be specified. The header has a fixed height: if both a
1853 # title and subtitle is specified, each will take up 1 line. If only the
1854 # title is specified, it will take up both lines.
1855 &quot;subtitle&quot;: &quot;A String&quot;, # The subtitle of the card header.
1856 },
1857 },
1858 ],
1859 &quot;space&quot;: { # A room or DM in Hangouts Chat. # The space the message belongs to.
1860 &quot;displayName&quot;: &quot;A String&quot;, # Output only. The display name (only if the space is a room).
1861 # Please note that this field might not be populated in direct messages
1862 # between humans.
1863 &quot;threaded&quot;: True or False, # Whether the messages are threaded in this space.
1864 &quot;name&quot;: &quot;A String&quot;, # Resource name of the space, in the form &quot;spaces/*&quot;.
1865 #
1866 # Example: spaces/AAAAMpdlehYs
1867 &quot;type&quot;: &quot;A String&quot;, # Output only. The type of a space.
1868 # This is deprecated. Use `single_user_bot_dm` instead.
1869 &quot;singleUserBotDm&quot;: True or False, # Whether the space is a DM between a bot and a single human.
Bu Sun Kim65020912020-05-20 12:08:20 -07001870 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001871 &quot;thread&quot;: { # A thread in Hangouts Chat. # The thread the message belongs to.
1872 &quot;name&quot;: &quot;A String&quot;, # Resource name, in the form &quot;spaces/*/threads/*&quot;.
1873 #
1874 # Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
1875 },
1876 &quot;fallbackText&quot;: &quot;A String&quot;, # A plain-text description of the message&#x27;s cards, used when the actual cards
1877 # cannot be displayed (e.g. mobile notifications).
1878 }</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001879</div>
1880
1881</body></html>