Rasa

Connect a call to a Rasa assistant

1{
2 "verb": "rasa",
3 "url": "http://my-assitant.acme.com/webhooks/rest/webhook?token=foobarbazzle",
4 "prompt": "Hello there! What can I do for you today?",
5 "eventHook": "/rasa/event",
6 "actionHook": "/rasa/action"
7}

Parameters

url
stringRequired

URL to connect to the Rasa assistant using the RestInput channel.

actionHook
string

A webhook that is called when the Rasa verb completes.

eventHook
string

A webhook that is called when the Rasa assistant returns either a user message or a bot message.

prompt
string

An initial greeting to play to the user.

recognizer
object

If provided, the speech recognition settings to use (defaults to application settings).

recognizer.hints
array

Array of words or phrases to assist speech detection.

recognizer.language
string

Language code to use for speech detection.
Defaults to the application-level setting or 'en-US' if not set.

recognizer.profanityFilter
boolean

If true, filter profanity from speech transcription.
Default: false.

recognizer.vendor
string

Speech vendor to use (currently only Google is supported).

tts
object

If provided, audio prompts will be played using these text-to-speech choices rather than the application defaults.

tts.gender
string

(Google only) MALE, FEMALE, or NEUTRAL.

tts.language
stringRequired

Language code to use.

tts.vendor
string

Speech vendor to use: Google, AWS (alias: Polly), or default (for application default).

tts.voice
string

Voice to use. Note that the voice list differs depending on whether you are using AWS or Google.
Defaults to the application setting, if provided.

actionHook properties

The actionHook webhook will contain the following additional parameters:

  • rasaResult: the completion reason:
    • caller hungup - the caller hungup
    • redirect - a new application was returned from an event webhook and is now being executed
    • timeout - the user did not respond to a prompt
    • webhookError - an error was received attempting to call an event webhook

eventHook properties

The eventHook webhook will contain two parameters: event and message. The event parameter will be either userMessage or botMessage depending on whether the message comes from the user or the rasa assistant, and message will contain the message itself. Your event webhook may return a new application in a json payload, in which case the call will be redirected to that application.

Built with