AI Zone Admin Forum Add your forum
Permissions / Login

I have been working on a bot for home automation. Things like turn the light on in the kitchen. However I have started expanding this bot for other things. Since Facebook now allows bots on messenger I made up a quick adapter and decided to let the bot do more things like a virtual assistant.

The problem I have come up on is the question of permissions. For example, I want people to be able to make appointments (which will be added to my calendar), but they should not be able to turn off the light at home unless they are authorized.

I have tried a few different ways to accomplish this however none of my solutions have been very clean. The best so far has is when a “restricted” command has been called, the bot asked for a password and $authorised is set to true. I also played around with using userfacts instead.

Can anyone give me a good design on how to implement this. Bonus points for something extendable.


  [ # 1 ]

Also the facebook messenger bot adapter is a simple PHP script that passes messages from facebook to chatscript and returns the results. Happy to send a copy to anyone interested.


  login or register to react