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.
pip install 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:
from dashbot import rasa
Then, use our library to publish events as part of your consumer code. As suggested below, call the dashbot rasa code with your api key in place of API_KEY_HERE. The example code below is for consuming rabbitmq messages via pika.
def _callback(ch, method, properties, body): event = json.loads(body) db = rasa.rasa(<strong>API_KEY_HERE</strong>) db.publish(event)
Please read the installation steps for the dashbot package and the PII redaction package on this page before you continue. If you would like to use the rules-based PII redaction capabilities offered by the open source package, please call the method in our dashbot package with the redact parameter, as demonstrated in the example code below, which uses rabbitmq as the message broker and the pika rabbitmq client library.
def _callback(ch, method, properties, body): event = json.loads(body) db = rasa.rasa(<strong>API_KEY_HERE</strong>, redact=True) db.publish(event)