POST /open: opens the door, params are id: the Slack user id of the person opening the door (must be in the slack channel) and secret: a "password"/token shared by the ones with access to the door. Returns some JSON user params if authorized, 401 otherwise.
The interaction with the bot on Slack was not changed.
This was tested with a real slack bot however it was not tested with the doorbell itself.
The API is as follows:
GET /ping: returns 200
GET /stats: returns the number of door openings per week day and the timestamp of the first door open:
POST /open: opens the door, params are
id
: the Slack user id of the person opening the door (must be in the slack channel) andsecret
: a "password"/token shared by the ones with access to the door. Returns some JSON user params if authorized, 401 otherwise.The interaction with the bot on Slack was not changed. This was tested with a real slack bot however it was not tested with the doorbell itself.