Expand description

Google Chat Types

type helper for construct Google Chat message There two type of Google Chat message

  • Text Message
  • Card Message

they are all represented as a json string.

Text Message represented like

{
    "text":"some text"
}  

Card Message represented like

{
 "cards": [
    {
      "sections": [
        {
          "widgets": [
            {
              "image": { "imageUrl": "https://..." }
            },
            {
              "buttons": [
                {
                  "textButton": {
                    "text": "OPEN IN GOOGLE MAPS",
                    "onClick": {
                      "openLink": {
                        "url": "https://..."
                      }
                    }
                  }
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}

the relationship between element of cards should likes look

Structs

Builder for Button.

the Card response. construct this by call default() method of this type

Builder for Card.

The Card message type

Builder for Cards.

Builder for Header.

Builder for Image.

Builder for OnClick.

Builder for Section.

The Text message type

Builder for Text.

Builder for Widget.

Enums

Error type for CardsBuilder