Rasa Integration via an Event Broker

Create a bot API key

Each bot needs its own API key for tracking. 

Create a bot to get an API key. Make sure to choose Rasa as the platform.

Install Dashbot via Pip

pip install dashbot

Include Dashbot

Use the API key created above.

Rasa Event Brokers api produces a message onto a message broker, which is then used to consume the event. In the message broker consumer code, import our python library and publish the events:

from dashbot import rasa

Consume events with Dashbot

def _callback(ch, method, properties, body):
    event = json.loads(body)
    db = rasa.rasa(API_KEY_HERE)
    db.publish(event)

Additional Configurations

Adding PII Redaction

After you follow the instructions here, in order to enable the PII redaction package, you will need to enable use of the PII redaction package by setting an argument to the function call as below:

def _callback(ch, method, properties, body):
    event = json.loads(body)
    db = rasa.rasa(API_KEY_HERE, redact=True)
    db.publish(event)
Close Menu