Configure global commands

For your application to support global commands, you must reserve an entity to hold the recognized command values you want your application to support. Three predefined events—Escalate, MainMenu, and Goodbye—are available, which you can map to specific values of your global command entity. To support additional commands, you must add both a custom event and the command entity value meant to trigger the event.

Once you have enabled global commands, you can add handlers for any events those commands are meant to trigger, in the Start node of your dialog design, or in the Enter node of a component, for component-level handling.

If you want some commands to be handled locally, at a specific question and answer node, configure command overrides. Commands that are only meant to be handled locally at a question and answer node don’t require a companion event. In a question and answer node, such commands are handled through system actions, just like intents and entity values.

Enable global commands

  1. Add a list entity—for example, COMMAND.
  2. Add literals for your entity—for example: Literal “goodbye” for value goodbye; “agent” and “operator” for agent; “main menu” for main_menu.
  3. In Mix.nlu, add at least “goodbye” as a sample under the NO_INTENT intent, and annotate it with the COMMAND entity.
    This is a workaround to prevent “goodbye” from being recognized as a value for a global entity that Mix.dialog does not yet support.
  4. In Mix.dialog, open the Project Settings panel, expand All channels, and click Global commands.
  5. Expand the Entity list and choose the entity you defined at step 1.

    This entity becomes a reserved entity. You cannot assign its value to a variable or use it in dynamic messages.
  6. Enable a command (for example, Goodbye), and choose the entity value (goodbye) that represents this command.
  7. If the project has channels that support DTMF interaction, choose a DTMF key for this command, if desired.
  8. Proceed in the same fashion for the other commands you want to enable.

Add a global command mapping

  1. Click the Add icon next to the Entity selector.

    A new row appears.
  2. Choose the event for the command you want to enable.

    Tip: Use the search field to narrow down the list if needed. If your project does not yet have the desired event, you can create it on the fly.
  3. Choose the corresponding entity value, and a DTMF key if your project supports DTMF interaction.
    Your new global command is enabled by default.

Remove a global command mapping

Click the More icon for the global command mapping you want to delete and choose Delete.