Stay organized with collections
Save and categorize content based on your preferences.
UniversalActionResponse
The response object that may be returned from a method that creates universal action.
// A universal action that opens a link.constopenLinkUniversalAction=CardService.newUniversalActionResponseBuilder().setOpenLink(CardService.newOpenLink().setUrl('https://www.google.com')).build();constcardBuilder1=CardService.newCardBuilder();constcardBuilder2=CardService.newCardBuilder();// Finish building the cards ...// A universal action that shows two static cards.constcardsUniversalAction=CardService.newUniversalActionResponseBuilder().displayAddOnCards([cardBuilder1.build(),cardBuilder2.build()]).build();
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-12-02 UTC."],[[["`UniversalActionResponse` objects are returned from methods creating universal actions, like opening links or displaying cards."],["These objects can define actions like opening a web link using `setOpenLink()` or showing cards using `displayAddOnCards()`."],["For debugging, the `printJson()` method outputs the object's JSON representation as a string."]]],[]]