Class Dialog

对话框

如需了解详情,请参阅 Google Chat 文档中的打开交互式对话框

Dialog 对象的构建器。

仅适用于 Google Chat 应用。不适用于 Google Workspace 插件。

const card = CardService.newCardBuilder()
    .setHeader(CardService.newCardHeader().setTitle('Card title')).build();

// Sets the card of the dialog.
const dialog = CardService.newDialog()
    .setBody(card);

方法

方法返回类型简介
setBody(card)Dialog设置 Dialog 的卡片。

详细文档

setBody(card)

设置 Dialog 的卡片。

const card = CardService.newCardBuilder()
    .setHeader(CardService.newCardHeader().setTitle('Card title')).build();

// Sets the card of the dialog.
const dialog = CardService.newDialog()
    .setBody(card);

参数

名称类型说明
cardCard要使用的 Card

弃踢回攻

Dialog - 此对象,用于链接。