Connecting to MongoDB

Hi, I am trying to store my conversations in MongoDB but I don’t exactly know how to proceed. I downloaded mongo as a service and the cli. I started mongo with the link provided in the option “connect” in the cluster.

I added the code provided in https://rasa.com/docs/rasa/api/tracker-stores/#mongotrackerstore to my endpoints.yml file.

tracker_store:
    type: mongod
    url: <url to your mongo instance, e.g. mongodb://localhost:27017>
    db: <name of the db within your mongo instance, e.g. rasa>
    username: <username used for authentication>
    password: <password used for authentication>
    auth_source: <database name associated with the user’s credentials>

However my conversations won’t get stored in the cluster. How can I achieve this?

to connect it directly to the cluster I changed the URL

tracker_store:
    type: mongod
    url: mongodb+srv://cluster-<name of the cluster>.vc5jv.mongodb.net
    db: <name of the db within your mongo instance, e.g. rasa>
    username: <username used for authentication>
    password: <password used for authentication>

Hi @zbot. Is the connection still not working for you?

Same problem… :confused: