Skip to content

xApp: Show Adaptive Card

Version badge

Description

An xApp Page can be built by providing an Adaptive Card in JSON format.

To submit data back to the Flow, you need to include an action of type submit within the Adaptive Card.

To view submitted data, use the Interaction panel. You can access submitted data in the data object by clicking INFO > Input, or in the chat by adding a Say Node and specifying Submit payload: {{JSON.stringify(input.data)}} or Submit payload: {{JSON.stringify(ci.data)}}.

As an alternative, for more customization, you can create your own Node by implementing and uploading an Extension.

AdaptiveCard Definition

The Adaptive Card Designer can help you to define an Adaptive Card. Copy the JSON card payload and paste it into the form.

Style Overrides

To override the background and interaction element colors, use CSS color codes.

Waiting Behavior

To wait for a user input, for example, when the user clicks Submit on the Ordering page, activate the Waiting Behavior option. You can store the input result in the Context and use the data in the other Nodes.

xApp Overlay

By default, an xApp page opens in a separate browser tab. If you are using Webchat v3, you can override this behavior to open your xApp pages directly within the Webchat v3 interface. The pages will be presented in the format of screens.

The table lists the parameters for configuring xApp screens in the Webchat v3 interface.

Parameter Type Description
Header Title CognigyScript This parameter shows a title of the screen. The title displayed at the top panel of the Webchat v3 interface. If no title is provided, the top panel will remain empty.
Show Close Icon Toggle This parameter displays the x button in the upper-right corner of the screen. This parameter is enabled by default.
Send Event on Close Icon Click Toggle This parameter records the event when the user closes the screen without submitting. This parameter is disabled by default.
Auto Open Toggle This parameter automatically opens the screen within the Webchat v3 interface. This setting is enabled by default. If you want xApp pages to open in browser tabs instead of within the Webchat v3 interface, activate this setting.
Close Overlay on Submit Toggle This parameter closes the screen after the user clicks the Submit button. This parameter is enabled by default.
Feedback Message on Submit CognigyScript This parameter sends a message to the chat after the user clicks the Submit button.

More Information