docs: update docs/dyn (#1096)
This PR was generated using Autosynth. :rainbow:
Synth log will be available here:
https://source.cloud.google.com/results/invocations/6f0f288a-a1e8-4b2d-a85f-00b1c6150185/targets
- [ ] To automatically regenerate this PR, check this box.
Source-Link: https://github.com/googleapis/synthtool/commit/39b7149da4026765385403632db3c6f63db96b2c
Source-Link: https://github.com/googleapis/synthtool/commit/9a7d9fbb7045c34c9d3d22c1ff766eeae51f04c9
Source-Link: https://github.com/googleapis/synthtool/commit/dc9903a8c30c3662b6098f0e4a97f221d67268b2
Source-Link: https://github.com/googleapis/synthtool/commit/7fcc405a579d5d53a726ff3da1b7c8c08f0f2d58
Source-Link: https://github.com/googleapis/synthtool/commit/d5fc0bcf9ea9789c5b0e3154a9e3b29e5cea6116
Source-Link: https://github.com/googleapis/synthtool/commit/e89175cf074dccc4babb4eca66ae913696e47a71
Source-Link: https://github.com/googleapis/synthtool/commit/7d652819519dfa24da9e14548232e4aaba71a11c
Source-Link: https://github.com/googleapis/synthtool/commit/7db8a6c5ffb12a6e4c2f799c18f00f7f3d60e279
Source-Link: https://github.com/googleapis/synthtool/commit/1f1148d3c7a7a52f0c98077f976bd9b3c948ee2b
Source-Link: https://github.com/googleapis/synthtool/commit/2c8aecedd55b0480fb4e123b6e07fa5b12953862
Source-Link: https://github.com/googleapis/synthtool/commit/3d3e94c4e02370f307a9a200b0c743c3d8d19f29
Source-Link: https://github.com/googleapis/synthtool/commit/c7824ea48ff6d4d42dfae0849aec8a85acd90bd9
Source-Link: https://github.com/googleapis/synthtool/commit/ba9918cd22874245b55734f57470c719b577e591
Source-Link: https://github.com/googleapis/synthtool/commit/b19b401571e77192f8dd38eab5fb2300a0de9324
Source-Link: https://github.com/googleapis/synthtool/commit/6542bd723403513626f61642fc02ddca528409aa
diff --git a/docs/dyn/chat_v1.spaces.messages.html b/docs/dyn/chat_v1.spaces.messages.html
index 230a9fd..6491084 100644
--- a/docs/dyn/chat_v1.spaces.messages.html
+++ b/docs/dyn/chat_v1.spaces.messages.html
@@ -110,128 +110,21 @@
The object takes the form of:
{ # A message in Hangouts Chat.
- "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
- "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
- },
+ "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"name": "A String", # Resource name, in the form "spaces/*/messages/*". Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
- "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
- "sender": { # A user in Hangouts Chat. # The user who created the message.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
- "commandId": "A String", # The id of the slash command invoked.
- },
"space": { # A room or DM in Hangouts Chat. # The space the message belongs to.
- "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"displayName": "A String", # Output only. The display name (only if the space is a room). Please note that this field might not be populated in direct messages between humans.
- "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
+ "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"name": "A String", # Resource name of the space, in the form "spaces/*". Example: spaces/AAAAMpdlehYs
"threaded": True or False, # Whether the messages are threaded in this space.
+ "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
},
- "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
- "type": "A String", # The type of bot response.
- "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
- },
- "text": "A String", # Plain-text body of the message.
"cards": [ # Rich, formatted and interactive cards that can be used to display UI elements such as: formatted texts, buttons, clickable images. Cards are normally displayed below the plain-text body of the message.
{ # A card is a UI element that can contain UI widgets such as texts, images.
- "cardActions": [ # The actions of this card.
- { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "actionLabel": "A String", # The label used to be displayed in the action menu item.
- },
- ],
- "header": { # The header of the card. A header usually contains a title and an image.
- "imageUrl": "A String", # The URL of the image in the card header.
- "subtitle": "A String", # The subtitle of the card header.
- "imageStyle": "A String", # The image's type (e.g. square border or circular border).
- "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
- },
"sections": [ # Sections are separated by a line divider.
{ # A section contains a collection of widgets that are rendered (vertically) in the order that they are specified. Across all platforms, cards have a narrow fixed width, so there is currently no need for layout properties (e.g. float).
- "header": "A String", # The header of the section, text formatted supported.
"widgets": [ # A section must contain at least 1 widget.
{ # A widget is a UI element that presents texts, images, etc.
- "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
- "text": "A String",
- },
- "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
- "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
- "topLabel": "A String", # The text of the top label. Formatted text supported.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "content": "A String", # The text of the content. Formatted text supported and always required.
- "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
- "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
- "textButton": { # A button with text and onclick action. # A button with text and onclick action.
- "text": "A String", # The text of the button.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- },
- "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
- "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
- },
- },
- "contentMultiline": True or False, # If the content should be multiline.
- "iconUrl": "A String", # The icon specified by a URL.
- },
"buttons": [ # A list of buttons. Buttons is also oneof data and only one of these fields should be set.
{ # A button. Can be a text button or an image button.
"textButton": { # A button with text and onclick action. # A button with text and onclick action.
@@ -253,7 +146,6 @@
},
"imageButton": { # An image button with an onclick action. # A button with image and onclick action.
"icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
"url": "A String", # The URL to open.
@@ -268,10 +160,71 @@
"actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
},
},
+ "iconUrl": "A String", # The icon specified by a URL.
"name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
},
},
],
+ "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
+ "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
+ "topLabel": "A String", # The text of the top label. Formatted text supported.
+ "contentMultiline": True or False, # If the content should be multiline.
+ "content": "A String", # The text of the content. Formatted text supported and always required.
+ "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
+ "textButton": { # A button with text and onclick action. # A button with text and onclick action.
+ "text": "A String", # The text of the button.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
+ "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "iconUrl": "A String", # The icon specified by a URL.
+ "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
+ },
+ },
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
+ "iconUrl": "A String", # The icon specified by a URL.
+ },
"image": { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
@@ -290,62 +243,109 @@
"imageUrl": "A String", # The URL of the image.
"aspectRatio": 3.14, # The aspect ratio of this image (width/height). This field allows clients to reserve the right height for the image while waiting for it to load. It's not meant to override the native aspect ratio of the image. If unset, the server fills it by prefetching the image.
},
+ "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
+ "text": "A String",
+ },
},
],
+ "header": "A String", # The header of the section, text formatted supported.
},
],
+ "header": { # The header of the card. A header usually contains a title and an image.
+ "imageUrl": "A String", # The URL of the image in the card header.
+ "imageStyle": "A String", # The image's type (e.g. square border or circular border).
+ "subtitle": "A String", # The subtitle of the card header.
+ "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
+ },
"name": "A String", # Name of the card.
+ "cardActions": [ # The actions of this card.
+ { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
+ "actionLabel": "A String", # The label used to be displayed in the action menu item.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ ],
},
],
+ "sender": { # A user in Hangouts Chat. # The user who created the message.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ "text": "A String", # Plain-text body of the message.
"fallbackText": "A String", # A plain-text description of the message's cards, used when the actual cards cannot be displayed (e.g. mobile notifications).
- "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
- "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"annotations": [ # Output only. Annotations associated with the text in this message.
{ # Annotations associated with the plain-text body of the message. Example plain-text message body: ``` Hello @FooBot how are you!" ``` The corresponding annotations metadata: ``` "annotations":[{ "type":"USER_MENTION", "startIndex":6, "length":7, "userMention": { "user": { "name":"users/107946847022116401880", "displayName":"FooBot", "avatarUrl":"https://goo.gl/aeDtrS", "type":"BOT" }, "type":"MENTION" } }] ```
- "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
- "user": { # A user in Hangouts Chat. # The user mentioned.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "type": "A String", # The type of user mention.
- },
"length": 42, # Length of the substring in the plain-text message body this annotation corresponds to.
- "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
"slashCommand": { # Annotation metadata for slash commands (/). # The metadata for a slash command.
- "commandName": "A String", # The name of the invoked slash command.
"triggersDialog": True or False, # Indicating whether the slash command is for a dialog.
"commandId": "A String", # The command id of the invoked slash command.
- "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
+ "commandName": "A String", # The name of the invoked slash command.
"type": "A String", # The type of slash command.
+ "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ },
+ "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
+ "type": "A String", # The type of user mention.
+ "user": { # A user in Hangouts Chat. # The user mentioned.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
},
"type": "A String", # The type of this annotation.
+ "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
},
],
+ "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
+ "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
+ },
"attachment": [ # User uploaded attachment.
{ # An attachment in Hangouts Chat.
- "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
- "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
- },
+ "source": "A String", # The source of the attachment.
+ "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
+ "contentType": "A String", # The content type (MIME type) of the file.
+ "contentName": "A String", # The original file name for the content, not the full path.
"attachmentDataRef": { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to download the attachment data.
"resourceName": "A String", # The resource name of the attachment data. This is used with the media API to download the attachment data.
},
- "contentName": "A String", # The original file name for the content, not the full path.
- "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
- "contentType": "A String", # The content type (MIME type) of the file.
"downloadUri": "A String", # Output only. The download URL which should be used to allow a human user to download the attachment. Bots should not use this URL to download attachment content.
- "source": "A String", # The source of the attachment.
+ "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
+ "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
+ },
"name": "A String", # Resource name of the attachment, in the form "spaces/*/messages/*/attachments/*".
},
],
+ "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
+ "commandId": "A String", # The id of the slash command invoked.
+ },
+ "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
+ "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
+ "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
+ "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
+ "type": "A String", # The type of bot response.
+ },
}
threadKey: string, Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves bots and webhooks from having to store the Hangouts Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.
@@ -358,128 +358,21 @@
An object of the form:
{ # A message in Hangouts Chat.
- "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
- "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
- },
+ "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"name": "A String", # Resource name, in the form "spaces/*/messages/*". Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
- "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
- "sender": { # A user in Hangouts Chat. # The user who created the message.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
- "commandId": "A String", # The id of the slash command invoked.
- },
"space": { # A room or DM in Hangouts Chat. # The space the message belongs to.
- "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"displayName": "A String", # Output only. The display name (only if the space is a room). Please note that this field might not be populated in direct messages between humans.
- "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
+ "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"name": "A String", # Resource name of the space, in the form "spaces/*". Example: spaces/AAAAMpdlehYs
"threaded": True or False, # Whether the messages are threaded in this space.
+ "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
},
- "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
- "type": "A String", # The type of bot response.
- "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
- },
- "text": "A String", # Plain-text body of the message.
"cards": [ # Rich, formatted and interactive cards that can be used to display UI elements such as: formatted texts, buttons, clickable images. Cards are normally displayed below the plain-text body of the message.
{ # A card is a UI element that can contain UI widgets such as texts, images.
- "cardActions": [ # The actions of this card.
- { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "actionLabel": "A String", # The label used to be displayed in the action menu item.
- },
- ],
- "header": { # The header of the card. A header usually contains a title and an image.
- "imageUrl": "A String", # The URL of the image in the card header.
- "subtitle": "A String", # The subtitle of the card header.
- "imageStyle": "A String", # The image's type (e.g. square border or circular border).
- "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
- },
"sections": [ # Sections are separated by a line divider.
{ # A section contains a collection of widgets that are rendered (vertically) in the order that they are specified. Across all platforms, cards have a narrow fixed width, so there is currently no need for layout properties (e.g. float).
- "header": "A String", # The header of the section, text formatted supported.
"widgets": [ # A section must contain at least 1 widget.
{ # A widget is a UI element that presents texts, images, etc.
- "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
- "text": "A String",
- },
- "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
- "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
- "topLabel": "A String", # The text of the top label. Formatted text supported.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "content": "A String", # The text of the content. Formatted text supported and always required.
- "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
- "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
- "textButton": { # A button with text and onclick action. # A button with text and onclick action.
- "text": "A String", # The text of the button.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- },
- "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
- "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
- },
- },
- "contentMultiline": True or False, # If the content should be multiline.
- "iconUrl": "A String", # The icon specified by a URL.
- },
"buttons": [ # A list of buttons. Buttons is also oneof data and only one of these fields should be set.
{ # A button. Can be a text button or an image button.
"textButton": { # A button with text and onclick action. # A button with text and onclick action.
@@ -501,7 +394,6 @@
},
"imageButton": { # An image button with an onclick action. # A button with image and onclick action.
"icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
"url": "A String", # The URL to open.
@@ -516,10 +408,71 @@
"actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
},
},
+ "iconUrl": "A String", # The icon specified by a URL.
"name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
},
},
],
+ "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
+ "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
+ "topLabel": "A String", # The text of the top label. Formatted text supported.
+ "contentMultiline": True or False, # If the content should be multiline.
+ "content": "A String", # The text of the content. Formatted text supported and always required.
+ "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
+ "textButton": { # A button with text and onclick action. # A button with text and onclick action.
+ "text": "A String", # The text of the button.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
+ "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "iconUrl": "A String", # The icon specified by a URL.
+ "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
+ },
+ },
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
+ "iconUrl": "A String", # The icon specified by a URL.
+ },
"image": { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
@@ -538,62 +491,109 @@
"imageUrl": "A String", # The URL of the image.
"aspectRatio": 3.14, # The aspect ratio of this image (width/height). This field allows clients to reserve the right height for the image while waiting for it to load. It's not meant to override the native aspect ratio of the image. If unset, the server fills it by prefetching the image.
},
+ "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
+ "text": "A String",
+ },
},
],
+ "header": "A String", # The header of the section, text formatted supported.
},
],
+ "header": { # The header of the card. A header usually contains a title and an image.
+ "imageUrl": "A String", # The URL of the image in the card header.
+ "imageStyle": "A String", # The image's type (e.g. square border or circular border).
+ "subtitle": "A String", # The subtitle of the card header.
+ "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
+ },
"name": "A String", # Name of the card.
+ "cardActions": [ # The actions of this card.
+ { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
+ "actionLabel": "A String", # The label used to be displayed in the action menu item.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ ],
},
],
+ "sender": { # A user in Hangouts Chat. # The user who created the message.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ "text": "A String", # Plain-text body of the message.
"fallbackText": "A String", # A plain-text description of the message's cards, used when the actual cards cannot be displayed (e.g. mobile notifications).
- "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
- "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"annotations": [ # Output only. Annotations associated with the text in this message.
{ # Annotations associated with the plain-text body of the message. Example plain-text message body: ``` Hello @FooBot how are you!" ``` The corresponding annotations metadata: ``` "annotations":[{ "type":"USER_MENTION", "startIndex":6, "length":7, "userMention": { "user": { "name":"users/107946847022116401880", "displayName":"FooBot", "avatarUrl":"https://goo.gl/aeDtrS", "type":"BOT" }, "type":"MENTION" } }] ```
- "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
- "user": { # A user in Hangouts Chat. # The user mentioned.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "type": "A String", # The type of user mention.
- },
"length": 42, # Length of the substring in the plain-text message body this annotation corresponds to.
- "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
"slashCommand": { # Annotation metadata for slash commands (/). # The metadata for a slash command.
- "commandName": "A String", # The name of the invoked slash command.
"triggersDialog": True or False, # Indicating whether the slash command is for a dialog.
"commandId": "A String", # The command id of the invoked slash command.
- "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
+ "commandName": "A String", # The name of the invoked slash command.
"type": "A String", # The type of slash command.
+ "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ },
+ "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
+ "type": "A String", # The type of user mention.
+ "user": { # A user in Hangouts Chat. # The user mentioned.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
},
"type": "A String", # The type of this annotation.
+ "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
},
],
+ "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
+ "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
+ },
"attachment": [ # User uploaded attachment.
{ # An attachment in Hangouts Chat.
- "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
- "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
- },
+ "source": "A String", # The source of the attachment.
+ "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
+ "contentType": "A String", # The content type (MIME type) of the file.
+ "contentName": "A String", # The original file name for the content, not the full path.
"attachmentDataRef": { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to download the attachment data.
"resourceName": "A String", # The resource name of the attachment data. This is used with the media API to download the attachment data.
},
- "contentName": "A String", # The original file name for the content, not the full path.
- "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
- "contentType": "A String", # The content type (MIME type) of the file.
"downloadUri": "A String", # Output only. The download URL which should be used to allow a human user to download the attachment. Bots should not use this URL to download attachment content.
- "source": "A String", # The source of the attachment.
+ "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
+ "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
+ },
"name": "A String", # Resource name of the attachment, in the form "spaces/*/messages/*/attachments/*".
},
],
+ "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
+ "commandId": "A String", # The id of the slash command invoked.
+ },
+ "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
+ "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
+ "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
+ "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
+ "type": "A String", # The type of bot response.
+ },
}</pre>
</div>
@@ -630,128 +630,21 @@
An object of the form:
{ # A message in Hangouts Chat.
- "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
- "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
- },
+ "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"name": "A String", # Resource name, in the form "spaces/*/messages/*". Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
- "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
- "sender": { # A user in Hangouts Chat. # The user who created the message.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
- "commandId": "A String", # The id of the slash command invoked.
- },
"space": { # A room or DM in Hangouts Chat. # The space the message belongs to.
- "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"displayName": "A String", # Output only. The display name (only if the space is a room). Please note that this field might not be populated in direct messages between humans.
- "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
+ "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"name": "A String", # Resource name of the space, in the form "spaces/*". Example: spaces/AAAAMpdlehYs
"threaded": True or False, # Whether the messages are threaded in this space.
+ "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
},
- "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
- "type": "A String", # The type of bot response.
- "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
- },
- "text": "A String", # Plain-text body of the message.
"cards": [ # Rich, formatted and interactive cards that can be used to display UI elements such as: formatted texts, buttons, clickable images. Cards are normally displayed below the plain-text body of the message.
{ # A card is a UI element that can contain UI widgets such as texts, images.
- "cardActions": [ # The actions of this card.
- { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "actionLabel": "A String", # The label used to be displayed in the action menu item.
- },
- ],
- "header": { # The header of the card. A header usually contains a title and an image.
- "imageUrl": "A String", # The URL of the image in the card header.
- "subtitle": "A String", # The subtitle of the card header.
- "imageStyle": "A String", # The image's type (e.g. square border or circular border).
- "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
- },
"sections": [ # Sections are separated by a line divider.
{ # A section contains a collection of widgets that are rendered (vertically) in the order that they are specified. Across all platforms, cards have a narrow fixed width, so there is currently no need for layout properties (e.g. float).
- "header": "A String", # The header of the section, text formatted supported.
"widgets": [ # A section must contain at least 1 widget.
{ # A widget is a UI element that presents texts, images, etc.
- "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
- "text": "A String",
- },
- "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
- "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
- "topLabel": "A String", # The text of the top label. Formatted text supported.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "content": "A String", # The text of the content. Formatted text supported and always required.
- "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
- "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
- "textButton": { # A button with text and onclick action. # A button with text and onclick action.
- "text": "A String", # The text of the button.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- },
- "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
- "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
- },
- },
- "contentMultiline": True or False, # If the content should be multiline.
- "iconUrl": "A String", # The icon specified by a URL.
- },
"buttons": [ # A list of buttons. Buttons is also oneof data and only one of these fields should be set.
{ # A button. Can be a text button or an image button.
"textButton": { # A button with text and onclick action. # A button with text and onclick action.
@@ -773,7 +666,6 @@
},
"imageButton": { # An image button with an onclick action. # A button with image and onclick action.
"icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
"url": "A String", # The URL to open.
@@ -788,10 +680,71 @@
"actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
},
},
+ "iconUrl": "A String", # The icon specified by a URL.
"name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
},
},
],
+ "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
+ "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
+ "topLabel": "A String", # The text of the top label. Formatted text supported.
+ "contentMultiline": True or False, # If the content should be multiline.
+ "content": "A String", # The text of the content. Formatted text supported and always required.
+ "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
+ "textButton": { # A button with text and onclick action. # A button with text and onclick action.
+ "text": "A String", # The text of the button.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
+ "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "iconUrl": "A String", # The icon specified by a URL.
+ "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
+ },
+ },
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
+ "iconUrl": "A String", # The icon specified by a URL.
+ },
"image": { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
@@ -810,62 +763,109 @@
"imageUrl": "A String", # The URL of the image.
"aspectRatio": 3.14, # The aspect ratio of this image (width/height). This field allows clients to reserve the right height for the image while waiting for it to load. It's not meant to override the native aspect ratio of the image. If unset, the server fills it by prefetching the image.
},
+ "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
+ "text": "A String",
+ },
},
],
+ "header": "A String", # The header of the section, text formatted supported.
},
],
+ "header": { # The header of the card. A header usually contains a title and an image.
+ "imageUrl": "A String", # The URL of the image in the card header.
+ "imageStyle": "A String", # The image's type (e.g. square border or circular border).
+ "subtitle": "A String", # The subtitle of the card header.
+ "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
+ },
"name": "A String", # Name of the card.
+ "cardActions": [ # The actions of this card.
+ { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
+ "actionLabel": "A String", # The label used to be displayed in the action menu item.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ ],
},
],
+ "sender": { # A user in Hangouts Chat. # The user who created the message.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ "text": "A String", # Plain-text body of the message.
"fallbackText": "A String", # A plain-text description of the message's cards, used when the actual cards cannot be displayed (e.g. mobile notifications).
- "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
- "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"annotations": [ # Output only. Annotations associated with the text in this message.
{ # Annotations associated with the plain-text body of the message. Example plain-text message body: ``` Hello @FooBot how are you!" ``` The corresponding annotations metadata: ``` "annotations":[{ "type":"USER_MENTION", "startIndex":6, "length":7, "userMention": { "user": { "name":"users/107946847022116401880", "displayName":"FooBot", "avatarUrl":"https://goo.gl/aeDtrS", "type":"BOT" }, "type":"MENTION" } }] ```
- "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
- "user": { # A user in Hangouts Chat. # The user mentioned.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "type": "A String", # The type of user mention.
- },
"length": 42, # Length of the substring in the plain-text message body this annotation corresponds to.
- "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
"slashCommand": { # Annotation metadata for slash commands (/). # The metadata for a slash command.
- "commandName": "A String", # The name of the invoked slash command.
"triggersDialog": True or False, # Indicating whether the slash command is for a dialog.
"commandId": "A String", # The command id of the invoked slash command.
- "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
+ "commandName": "A String", # The name of the invoked slash command.
"type": "A String", # The type of slash command.
+ "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ },
+ "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
+ "type": "A String", # The type of user mention.
+ "user": { # A user in Hangouts Chat. # The user mentioned.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
},
"type": "A String", # The type of this annotation.
+ "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
},
],
+ "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
+ "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
+ },
"attachment": [ # User uploaded attachment.
{ # An attachment in Hangouts Chat.
- "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
- "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
- },
+ "source": "A String", # The source of the attachment.
+ "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
+ "contentType": "A String", # The content type (MIME type) of the file.
+ "contentName": "A String", # The original file name for the content, not the full path.
"attachmentDataRef": { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to download the attachment data.
"resourceName": "A String", # The resource name of the attachment data. This is used with the media API to download the attachment data.
},
- "contentName": "A String", # The original file name for the content, not the full path.
- "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
- "contentType": "A String", # The content type (MIME type) of the file.
"downloadUri": "A String", # Output only. The download URL which should be used to allow a human user to download the attachment. Bots should not use this URL to download attachment content.
- "source": "A String", # The source of the attachment.
+ "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
+ "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
+ },
"name": "A String", # Resource name of the attachment, in the form "spaces/*/messages/*/attachments/*".
},
],
+ "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
+ "commandId": "A String", # The id of the slash command invoked.
+ },
+ "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
+ "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
+ "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
+ "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
+ "type": "A String", # The type of bot response.
+ },
}</pre>
</div>
@@ -879,128 +879,21 @@
The object takes the form of:
{ # A message in Hangouts Chat.
- "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
- "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
- },
+ "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"name": "A String", # Resource name, in the form "spaces/*/messages/*". Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
- "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
- "sender": { # A user in Hangouts Chat. # The user who created the message.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
- "commandId": "A String", # The id of the slash command invoked.
- },
"space": { # A room or DM in Hangouts Chat. # The space the message belongs to.
- "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"displayName": "A String", # Output only. The display name (only if the space is a room). Please note that this field might not be populated in direct messages between humans.
- "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
+ "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"name": "A String", # Resource name of the space, in the form "spaces/*". Example: spaces/AAAAMpdlehYs
"threaded": True or False, # Whether the messages are threaded in this space.
+ "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
},
- "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
- "type": "A String", # The type of bot response.
- "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
- },
- "text": "A String", # Plain-text body of the message.
"cards": [ # Rich, formatted and interactive cards that can be used to display UI elements such as: formatted texts, buttons, clickable images. Cards are normally displayed below the plain-text body of the message.
{ # A card is a UI element that can contain UI widgets such as texts, images.
- "cardActions": [ # The actions of this card.
- { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "actionLabel": "A String", # The label used to be displayed in the action menu item.
- },
- ],
- "header": { # The header of the card. A header usually contains a title and an image.
- "imageUrl": "A String", # The URL of the image in the card header.
- "subtitle": "A String", # The subtitle of the card header.
- "imageStyle": "A String", # The image's type (e.g. square border or circular border).
- "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
- },
"sections": [ # Sections are separated by a line divider.
{ # A section contains a collection of widgets that are rendered (vertically) in the order that they are specified. Across all platforms, cards have a narrow fixed width, so there is currently no need for layout properties (e.g. float).
- "header": "A String", # The header of the section, text formatted supported.
"widgets": [ # A section must contain at least 1 widget.
{ # A widget is a UI element that presents texts, images, etc.
- "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
- "text": "A String",
- },
- "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
- "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
- "topLabel": "A String", # The text of the top label. Formatted text supported.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "content": "A String", # The text of the content. Formatted text supported and always required.
- "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
- "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
- "textButton": { # A button with text and onclick action. # A button with text and onclick action.
- "text": "A String", # The text of the button.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- },
- "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
- "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
- },
- },
- "contentMultiline": True or False, # If the content should be multiline.
- "iconUrl": "A String", # The icon specified by a URL.
- },
"buttons": [ # A list of buttons. Buttons is also oneof data and only one of these fields should be set.
{ # A button. Can be a text button or an image button.
"textButton": { # A button with text and onclick action. # A button with text and onclick action.
@@ -1022,7 +915,6 @@
},
"imageButton": { # An image button with an onclick action. # A button with image and onclick action.
"icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
"url": "A String", # The URL to open.
@@ -1037,10 +929,71 @@
"actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
},
},
+ "iconUrl": "A String", # The icon specified by a URL.
"name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
},
},
],
+ "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
+ "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
+ "topLabel": "A String", # The text of the top label. Formatted text supported.
+ "contentMultiline": True or False, # If the content should be multiline.
+ "content": "A String", # The text of the content. Formatted text supported and always required.
+ "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
+ "textButton": { # A button with text and onclick action. # A button with text and onclick action.
+ "text": "A String", # The text of the button.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
+ "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "iconUrl": "A String", # The icon specified by a URL.
+ "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
+ },
+ },
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
+ "iconUrl": "A String", # The icon specified by a URL.
+ },
"image": { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
@@ -1059,62 +1012,109 @@
"imageUrl": "A String", # The URL of the image.
"aspectRatio": 3.14, # The aspect ratio of this image (width/height). This field allows clients to reserve the right height for the image while waiting for it to load. It's not meant to override the native aspect ratio of the image. If unset, the server fills it by prefetching the image.
},
+ "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
+ "text": "A String",
+ },
},
],
+ "header": "A String", # The header of the section, text formatted supported.
},
],
+ "header": { # The header of the card. A header usually contains a title and an image.
+ "imageUrl": "A String", # The URL of the image in the card header.
+ "imageStyle": "A String", # The image's type (e.g. square border or circular border).
+ "subtitle": "A String", # The subtitle of the card header.
+ "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
+ },
"name": "A String", # Name of the card.
+ "cardActions": [ # The actions of this card.
+ { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
+ "actionLabel": "A String", # The label used to be displayed in the action menu item.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ ],
},
],
+ "sender": { # A user in Hangouts Chat. # The user who created the message.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ "text": "A String", # Plain-text body of the message.
"fallbackText": "A String", # A plain-text description of the message's cards, used when the actual cards cannot be displayed (e.g. mobile notifications).
- "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
- "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"annotations": [ # Output only. Annotations associated with the text in this message.
{ # Annotations associated with the plain-text body of the message. Example plain-text message body: ``` Hello @FooBot how are you!" ``` The corresponding annotations metadata: ``` "annotations":[{ "type":"USER_MENTION", "startIndex":6, "length":7, "userMention": { "user": { "name":"users/107946847022116401880", "displayName":"FooBot", "avatarUrl":"https://goo.gl/aeDtrS", "type":"BOT" }, "type":"MENTION" } }] ```
- "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
- "user": { # A user in Hangouts Chat. # The user mentioned.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "type": "A String", # The type of user mention.
- },
"length": 42, # Length of the substring in the plain-text message body this annotation corresponds to.
- "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
"slashCommand": { # Annotation metadata for slash commands (/). # The metadata for a slash command.
- "commandName": "A String", # The name of the invoked slash command.
"triggersDialog": True or False, # Indicating whether the slash command is for a dialog.
"commandId": "A String", # The command id of the invoked slash command.
- "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
+ "commandName": "A String", # The name of the invoked slash command.
"type": "A String", # The type of slash command.
+ "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ },
+ "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
+ "type": "A String", # The type of user mention.
+ "user": { # A user in Hangouts Chat. # The user mentioned.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
},
"type": "A String", # The type of this annotation.
+ "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
},
],
+ "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
+ "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
+ },
"attachment": [ # User uploaded attachment.
{ # An attachment in Hangouts Chat.
- "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
- "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
- },
+ "source": "A String", # The source of the attachment.
+ "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
+ "contentType": "A String", # The content type (MIME type) of the file.
+ "contentName": "A String", # The original file name for the content, not the full path.
"attachmentDataRef": { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to download the attachment data.
"resourceName": "A String", # The resource name of the attachment data. This is used with the media API to download the attachment data.
},
- "contentName": "A String", # The original file name for the content, not the full path.
- "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
- "contentType": "A String", # The content type (MIME type) of the file.
"downloadUri": "A String", # Output only. The download URL which should be used to allow a human user to download the attachment. Bots should not use this URL to download attachment content.
- "source": "A String", # The source of the attachment.
+ "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
+ "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
+ },
"name": "A String", # Resource name of the attachment, in the form "spaces/*/messages/*/attachments/*".
},
],
+ "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
+ "commandId": "A String", # The id of the slash command invoked.
+ },
+ "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
+ "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
+ "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
+ "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
+ "type": "A String", # The type of bot response.
+ },
}
updateMask: string, Required. The field paths to be updated, comma separated if there are multiple. Currently supported field paths: * text * cards
@@ -1127,128 +1127,21 @@
An object of the form:
{ # A message in Hangouts Chat.
- "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
- "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
- },
+ "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"name": "A String", # Resource name, in the form "spaces/*/messages/*". Example: spaces/AAAAMpdlehY/messages/UMxbHmzDlr4.UMxbHmzDlr4
- "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
- "sender": { # A user in Hangouts Chat. # The user who created the message.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
- "commandId": "A String", # The id of the slash command invoked.
- },
"space": { # A room or DM in Hangouts Chat. # The space the message belongs to.
- "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"displayName": "A String", # Output only. The display name (only if the space is a room). Please note that this field might not be populated in direct messages between humans.
- "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
+ "type": "A String", # Output only. The type of a space. This is deprecated. Use `single_user_bot_dm` instead.
"name": "A String", # Resource name of the space, in the form "spaces/*". Example: spaces/AAAAMpdlehYs
"threaded": True or False, # Whether the messages are threaded in this space.
+ "singleUserBotDm": True or False, # Whether the space is a DM between a bot and a single human.
},
- "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
- "type": "A String", # The type of bot response.
- "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
- },
- "text": "A String", # Plain-text body of the message.
"cards": [ # Rich, formatted and interactive cards that can be used to display UI elements such as: formatted texts, buttons, clickable images. Cards are normally displayed below the plain-text body of the message.
{ # A card is a UI element that can contain UI widgets such as texts, images.
- "cardActions": [ # The actions of this card.
- { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "actionLabel": "A String", # The label used to be displayed in the action menu item.
- },
- ],
- "header": { # The header of the card. A header usually contains a title and an image.
- "imageUrl": "A String", # The URL of the image in the card header.
- "subtitle": "A String", # The subtitle of the card header.
- "imageStyle": "A String", # The image's type (e.g. square border or circular border).
- "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
- },
"sections": [ # Sections are separated by a line divider.
{ # A section contains a collection of widgets that are rendered (vertically) in the order that they are specified. Across all platforms, cards have a narrow fixed width, so there is currently no need for layout properties (e.g. float).
- "header": "A String", # The header of the section, text formatted supported.
"widgets": [ # A section must contain at least 1 widget.
{ # A widget is a UI element that presents texts, images, etc.
- "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
- "text": "A String",
- },
- "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
- "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
- "topLabel": "A String", # The text of the top label. Formatted text supported.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "content": "A String", # The text of the content. Formatted text supported and always required.
- "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
- "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
- "textButton": { # A button with text and onclick action. # A button with text and onclick action.
- "text": "A String", # The text of the button.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- },
- "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
- "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
- "onClick": { # An onclick action (e.g. open a link). # The onclick action.
- "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
- "url": "A String", # The URL to open.
- },
- "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
- "parameters": [ # List of action parameters.
- { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
- "value": "A String", # The value of the parameter.
- "key": "A String", # The name of the parameter for the action script.
- },
- ],
- "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
- },
- },
- "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
- },
- },
- "contentMultiline": True or False, # If the content should be multiline.
- "iconUrl": "A String", # The icon specified by a URL.
- },
"buttons": [ # A list of buttons. Buttons is also oneof data and only one of these fields should be set.
{ # A button. Can be a text button or an image button.
"textButton": { # A button with text and onclick action. # A button with text and onclick action.
@@ -1270,7 +1163,6 @@
},
"imageButton": { # An image button with an onclick action. # A button with image and onclick action.
"icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
- "iconUrl": "A String", # The icon specified by a URL.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
"url": "A String", # The URL to open.
@@ -1285,10 +1177,71 @@
"actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
},
},
+ "iconUrl": "A String", # The icon specified by a URL.
"name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
},
},
],
+ "keyValue": { # A UI element contains a key (label) and a value (content). And this element may also contain some actions such as onclick button. # Display a key value item in this widget.
+ "icon": "A String", # An enum value that will be replaced by the Chat API with the corresponding icon image.
+ "topLabel": "A String", # The text of the top label. Formatted text supported.
+ "contentMultiline": True or False, # If the content should be multiline.
+ "content": "A String", # The text of the content. Formatted text supported and always required.
+ "button": { # A button. Can be a text button or an image button. # A button that can be clicked to trigger an action.
+ "textButton": { # A button with text and onclick action. # A button with text and onclick action.
+ "text": "A String", # The text of the button.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action of the button.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ "imageButton": { # An image button with an onclick action. # A button with image and onclick action.
+ "icon": "A String", # The icon specified by an enum that indices to an icon provided by Chat API.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "iconUrl": "A String", # The icon specified by a URL.
+ "name": "A String", # The name of this image_button which will be used for accessibility. Default value will be provided if developers don't specify.
+ },
+ },
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action. Only the top label, bottom label and content region are clickable.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ "bottomLabel": "A String", # The text of the bottom label. Formatted text supported.
+ "iconUrl": "A String", # The icon specified by a URL.
+ },
"image": { # An image that is specified by a URL and can have an onclick action. # Display an image in this widget.
"onClick": { # An onclick action (e.g. open a link). # The onclick action.
"openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
@@ -1307,62 +1260,109 @@
"imageUrl": "A String", # The URL of the image.
"aspectRatio": 3.14, # The aspect ratio of this image (width/height). This field allows clients to reserve the right height for the image while waiting for it to load. It's not meant to override the native aspect ratio of the image. If unset, the server fills it by prefetching the image.
},
+ "textParagraph": { # A paragraph of text. Formatted text supported. # Display a text paragraph in this widget.
+ "text": "A String",
+ },
},
],
+ "header": "A String", # The header of the section, text formatted supported.
},
],
+ "header": { # The header of the card. A header usually contains a title and an image.
+ "imageUrl": "A String", # The URL of the image in the card header.
+ "imageStyle": "A String", # The image's type (e.g. square border or circular border).
+ "subtitle": "A String", # The subtitle of the card header.
+ "title": "A String", # The title must be specified. The header has a fixed height: if both a title and subtitle is specified, each will take up 1 line. If only the title is specified, it will take up both lines.
+ },
"name": "A String", # Name of the card.
+ "cardActions": [ # The actions of this card.
+ { # A card action is the action associated with the card. For an invoice card, a typical action would be: delete invoice, email invoice or open the invoice in browser.
+ "actionLabel": "A String", # The label used to be displayed in the action menu item.
+ "onClick": { # An onclick action (e.g. open a link). # The onclick action for this action item.
+ "openLink": { # A link that opens a new window. # This onclick triggers an open link action if specified.
+ "url": "A String", # The URL to open.
+ },
+ "action": { # A form action describes the behavior when the form is submitted. For example, an Apps Script can be invoked to handle the form. # A form action will be triggered by this onclick if specified.
+ "parameters": [ # List of action parameters.
+ { # List of string parameters to supply when the action method is invoked. For example, consider three snooze buttons: snooze now, snooze 1 day, snooze next week. You might use action method = snooze(), passing the snooze type and snooze time in the list of string parameters.
+ "value": "A String", # The value of the parameter.
+ "key": "A String", # The name of the parameter for the action script.
+ },
+ ],
+ "actionMethodName": "A String", # The method name is used to identify which part of the form triggered the form submission. This information is echoed back to the bot as part of the card click event. The same method name can be used for several elements that trigger a common behavior if desired.
+ },
+ },
+ },
+ ],
},
],
+ "sender": { # A user in Hangouts Chat. # The user who created the message.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ "text": "A String", # Plain-text body of the message.
"fallbackText": "A String", # A plain-text description of the message's cards, used when the actual cards cannot be displayed (e.g. mobile notifications).
- "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
- "createTime": "A String", # Output only. The time at which the message was created in Hangouts Chat server.
"annotations": [ # Output only. Annotations associated with the text in this message.
{ # Annotations associated with the plain-text body of the message. Example plain-text message body: ``` Hello @FooBot how are you!" ``` The corresponding annotations metadata: ``` "annotations":[{ "type":"USER_MENTION", "startIndex":6, "length":7, "userMention": { "user": { "name":"users/107946847022116401880", "displayName":"FooBot", "avatarUrl":"https://goo.gl/aeDtrS", "type":"BOT" }, "type":"MENTION" } }] ```
- "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
- "user": { # A user in Hangouts Chat. # The user mentioned.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
- "type": "A String", # The type of user mention.
- },
"length": 42, # Length of the substring in the plain-text message body this annotation corresponds to.
- "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
"slashCommand": { # Annotation metadata for slash commands (/). # The metadata for a slash command.
- "commandName": "A String", # The name of the invoked slash command.
"triggersDialog": True or False, # Indicating whether the slash command is for a dialog.
"commandId": "A String", # The command id of the invoked slash command.
- "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
- "domainId": "A String", # Obfuscated domain information.
- "type": "A String", # User type.
- "displayName": "A String", # The user's display name.
- "name": "A String", # Resource name, in the format "users/*".
- "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
- },
+ "commandName": "A String", # The name of the invoked slash command.
"type": "A String", # The type of slash command.
+ "bot": { # A user in Hangouts Chat. # The bot whose command was invoked.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
+ },
+ "userMention": { # Annotation metadata for user mentions (@). # The metadata of user mention.
+ "type": "A String", # The type of user mention.
+ "user": { # A user in Hangouts Chat. # The user mentioned.
+ "displayName": "A String", # The user's display name.
+ "isAnonymous": True or False, # True when the user is deleted or the user's proifle is not visible.
+ "name": "A String", # Resource name, in the format "users/*".
+ "type": "A String", # User type.
+ "domainId": "A String", # Obfuscated domain information.
+ },
},
"type": "A String", # The type of this annotation.
+ "startIndex": 42, # Start index (0-based, inclusive) in the plain-text message body this annotation corresponds to.
},
],
+ "thread": { # A thread in Hangouts Chat. # The thread the message belongs to.
+ "name": "A String", # Resource name, in the form "spaces/*/threads/*". Example: spaces/AAAAMpdlehY/threads/UMxbHmzDlr4
+ },
"attachment": [ # User uploaded attachment.
{ # An attachment in Hangouts Chat.
- "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
- "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
- },
+ "source": "A String", # The source of the attachment.
+ "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
+ "contentType": "A String", # The content type (MIME type) of the file.
+ "contentName": "A String", # The original file name for the content, not the full path.
"attachmentDataRef": { # A reference to the data of an attachment. # A reference to the attachment data. This is used with the media API to download the attachment data.
"resourceName": "A String", # The resource name of the attachment data. This is used with the media API to download the attachment data.
},
- "contentName": "A String", # The original file name for the content, not the full path.
- "thumbnailUri": "A String", # Output only. The thumbnail URL which should be used to preview the attachment to a human user. Bots should not use this URL to download attachment content.
- "contentType": "A String", # The content type (MIME type) of the file.
"downloadUri": "A String", # Output only. The download URL which should be used to allow a human user to download the attachment. Bots should not use this URL to download attachment content.
- "source": "A String", # The source of the attachment.
+ "driveDataRef": { # A reference to the data of a drive attachment. # A reference to the drive attachment. This is used with the Drive API.
+ "driveFileId": "A String", # The id for the drive file, for use with the Drive API.
+ },
"name": "A String", # Resource name of the attachment, in the form "spaces/*/messages/*/attachments/*".
},
],
+ "slashCommand": { # A Slash Command in Hangouts Chat. # Slash command information, if applicable.
+ "commandId": "A String", # The id of the slash command invoked.
+ },
+ "previewText": "A String", # Text for generating preview chips. This text will not be displayed to the user, but any links to images, web pages, videos, etc. included here will generate preview chips.
+ "argumentText": "A String", # Plain-text body of the message with all bot mentions stripped out.
+ "actionResponse": { # Parameters that a bot can use to configure how it's response is posted. # Input only. Parameters that a bot can use to configure how its response is posted.
+ "url": "A String", # URL for users to auth or config. (Only for REQUEST_CONFIG response types.)
+ "type": "A String", # The type of bot response.
+ },
}</pre>
</div>