To implement the approval flow with the bot, whichever collection name you put in MONGO_COUNTER variable(mentioned above) should be present inside the db set by MONGO_DB_NAME. For example- suppose you have MONGO_COUNTER=counters and MONGO_DB_NAME=hubot set in your environment. Then you should have a database called "hubot" inside your mongodb. This "hubot" should contain a collection named "counters" having this structure: { _id: "ticketIdGenerator",seq: 100} To create a collection like this, go to your mongo shell and execute below steps: - use hubot
- db.createCollection("counters")
- db.counters.insert({_id: "ticketIdGenerator",seq: 100})
Info | The MONGO_TICKETIDGEN should contain the Id of the collection referred by MONGO_COUNTER. Therefore, for the above example, MONGO_TICKETIDGEN=ticketIdGeneratorMicrosoft Teams BOTBUILDER_APP_ID (App Id of your bot) BOTBUILDER_APP_PASSWORD (secret password for your bot) BOTBUILDER_ENDPOINT (Sets a custom HTTP endpoint for your bot to receive messages on (default is /api/messages). For Example: /master , /github , /jira , /jenkins , /sendtobot) CURRENT_CHANNEL (MS Teams current channel incoming webhook url. Reference: https://docs.microsoft.com/en-us/outlook/actionable-messages/send-via-connectors) ADMIN_CHANNEL (MS Teams admin channel incoming webhook url for approval workflow. Reference: https://docs.microsoft.com/en-us/outlook/actionable-messages/send-via-connectors) |