Rate this page:

Events

Add the following line to your scenario code to use the events:

require(Modules.AI);

Constants

DialogflowError

Copy URL

Triggered when a Dialogflow instance causes error.

Parameters

  • cause:

    string

    The cause of the event

  • Link to the Dialogflow instance

DialogflowPlaybackFinished

Copy URL

Triggered when a playback of a single phrase is finished successfully or in case of playback error.

Parameters

DialogflowPlaybackMarkerReached

Copy URL

Triggered when 'DialogflowInstance.addMarker' is reached.

Parameters

DialogflowPlaybackStarted

Copy URL

Triggered when a playback of a single phrase is started.

Parameters

  • Link to the Dialogflow instance

  • duration:

    number

    Playback duration

DialogflowQueryResult

Copy URL

Triggered when a Dialogflow instance returns a query result.

Parameters

DialogflowRecognitionResult

Copy URL

Triggered when a Dialogflow instance returns a recognition result.

Parameters

  • Link to the Dialogflow instance

  • isFinal:

    boolean

    The default of 0.0 is a sentinel value indicating confidence was not set. If it is false, the StreamingRecognitionResult represents an interim result that may change. If it is true, the recognizer does not return any further hypotheses about this piece of the audio.

DialogflowResponse

Copy URL

Triggered when a Dialogflow instance returns an intent response.

Parameters

DialogflowStopped

Copy URL

Triggered when a Dialogflow instance is stopped.

Parameters

  • cause:

    string

    The cause of the event

  • Link to the Dialogflow instance

VoicemailDetected

Deprecated
Copy URL

Use AMD module instead

Triggered when an answering machine or voicemail is detected.

Parameters

  • call:

    Call

    Call that triggers the event

  • confidence:

    number

    Recognition confidence. Values range from 0 (completely uncertain) to 100 (completely certain). The value is not guaranteed to be accurate, consider it while handling the event.

VoicemailNotDetected

Deprecated
Copy URL

Use AMD module instead

Triggered when an answering machine or voicemail is not detected.

Parameters

  • call:

    Call

    Call that triggers the event