Widget Settings: Sample Use Cases and Flows

This article shares some possible use cases your app or site could support, as well as a sample flow that could support each use case. This can be a helpful jumping-off point.

Retrieve and update widget settings

To retrieve and update the widget settings:

  1. Call Get Widget Settings to retrieve the current settings.
  2. Update the settings retrieved. For example, update the intro message.
  3. Call Set Widget Settings, specifying the updated settings, to save the updated settings.

Display a message if the AI assistant is offline.

To display a message if the AI assistant is offline:

  1. Call Get Widget Settings.
  2. Check the value of assistantOnline in the response.
  3. If it's false, display a message on the site.
Did this help?