You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there!
So I'm trying to set up web hooks, and I managed to get things to look like they SHOULD work, but they don't when needed. Here's what I have:
I make my local, test environment accessible via ngrok (which provides a public https link redirected to my localhost). I configure webhooks with this URL, and it works correctly.
My webhook is reachable in my production environment. If I make a POST using curl or Postman or similar, to the production's webhook URL, it works.
but if set SwitchBot's webhook to the production's webhook URL, then it doesn't work. It seems the server never receives the POST from SwitchBot.
Things which MAY influence this:
my production webhook is in a https page with an invalid certificate - Still it DOES work to send it a POST (for example from here: reqbin.com)
my production domain name starts with a digit (ie https://47test.com) - not sure why this would be an issue, but you never know
Any ideas? what could stop SwitchBot from correctly calling my server's webhook URL?
Thank you :)
Logs
I there a way to find SwitchBot's log about webhook calls it makes? I haven't been able to find it
Configuration
Not sure what you may need, configuration works on the dev server...
Environment
Dev server: PyCharm, windows (behing ngrok)
Prod server: Linux, gunicorn, nginx, local, ssh reverse tunnel to make it accessible from outside.
Additional Context
No response
The text was updated successfully, but these errors were encountered:
My thought is that your production server NEED a valid ssl certificate. Switchbot has no options (as far as i know) to support self signed certificates, nor to enable or disable SSL certificate checking - as Twilio allow for example).
As you're working with a python project, you can host it online for testing, with real certificate on alwaysdata (free under 100Mb, good for testing).
Didn't you find anything useful on nginx requests logs ?
Thank you! Indeed seems to be working after removing SSL!
I still can't get the webooks from he keypad though... any idea way? Also, any other event than "add/remove" code? Actually I'd like an event anytime anyone presses a key on the keypad...
I've the same problem for the keypad #361 as others has #367 . There's a bug in the API for the keypad, and even after an asking on the switchbot client support, nothing change (the support doesn't help on the API).
Anyway, the API has no webhook notifications for the key entered on the keypad, only if a code is created or deleted... A good proposal has been made here #192 but unfortunably Switchbot developpers are not really presents here....
Current Situation
Hi there!
So I'm trying to set up web hooks, and I managed to get things to look like they SHOULD work, but they don't when needed. Here's what I have:
I make my local, test environment accessible via ngrok (which provides a public https link redirected to my localhost). I configure webhooks with this URL, and it works correctly.
My webhook is reachable in my production environment. If I make a POST using curl or Postman or similar, to the production's webhook URL, it works.
but if set SwitchBot's webhook to the production's webhook URL, then it doesn't work. It seems the server never receives the POST from SwitchBot.
Things which MAY influence this:
Any ideas? what could stop SwitchBot from correctly calling my server's webhook URL?
Thank you :)
Logs
Configuration
Not sure what you may need, configuration works on the dev server...
Environment
Dev server: PyCharm, windows (behing ngrok)
Prod server: Linux, gunicorn, nginx, local, ssh reverse tunnel to make it accessible from outside.
Additional Context
No response
The text was updated successfully, but these errors were encountered: