Google Chat tools
The 11 Google Chat operations your product runs on your customer's account through Connect. All of them use the same endpoint, POST /api/tools/{tool}/execute.
- List spacesGETLists the spaces, group chats and direct messages the user is a member of, with name, displayName and spaceType. The part of the name after spaces/ is the spaceId of the other tools, and group chats and direct messages only show up after their first message.
- Get direct messageGETReturns the direct message space between the user and another person; the part of its name after spaces/ is the spaceId for Send message. Responds 404 when the two have no direct message yet, which Create space starts.
- Create spacePOSTCreates a space with the user in it and invites other people. SPACE needs displayName and takes up to 49 people; GROUP_CHAT takes at least two people and no name; DIRECT_MESSAGE takes exactly one person and returns the existing direct message when there is one.
- List messagesGETLists the messages of a space, oldest first by default, with name, sender, createTime, text and thread. Senders come as users/ followed by an id, without the display name; send nextPageToken as pageToken for the next page.
- Search messagesPOSTSearches messages by keywords in every space and direct message of the user, latest first. Each result has the message, whose name carries the space and message ids; messages from Chat apps, private messages and muted spaces are left out.
- Send messagePOSTSends a text message from the user to a space or direct message. To reply in a thread, send thread with the thread name from List messages and messageReplyOption; without messageReplyOption the message starts a new thread.
- Update messagePATCHChanges the text of a message, with updateMask set to text.
- Delete messageDELETEDeletes a message. A message with replies in a thread is only deleted with force set to true, which deletes the replies too.
- Create reactionPOSTAdds an emoji reaction from the user to a message.
- List membersGETLists the members of a space with role and state. Members come as users/ followed by an id, without the display name; send nextPageToken as pageToken for the next page.
- Create memberPOSTAdds a person to a space, or invites them when their settings ask for acceptance. Needs a user allowed to add members to the space.
See Connect applied to your product.
Try it for 15 days with no card, or walk our team through your use case.
