There is some documentation here (official readme.io link), but it’s definitely unclear.
To summarize you need to make a POST request to https://api.rach.io/1/public/notification/webhook
Within said request you need to be sure to have several headers:
“Authorization: Bearer {your API key}”
“Content-Type: application/json” (that’s what you will be sending with your POST request
Now the contents of your post request should have a JSON string that looks something like this:
{“device”:{“id”:“2a5e7d3c-c140-4e2e-91a1-a212a518adc5”}, “externalId” : “external company ID”, “url”:“https://www.mydomain.com/another_webhook",“eventTypes”:[{“id”:“1”},{“id”:"2”}]}
device.id you can lookup via static requests, first to your person/info, where you’ll get your id
than to person/{id} where you’ll get all of your devices along with their ids, that’s id you want to use in webhook request
To know which even types are available for your account, you’ll also want to make a reuqest to event type endpoint (example here), you’ll need only your API key for that and those type id(s) will be passed along to the service during webhook registration.
externalId is just a memo for your own use. This way you may be able to route data in your own code.
url is the url of your webhook. You could use IP in lieu of a domain, but urls tend to work better with remote proxies. Data doesn’t have to go to port 443 (https), it can be on any valid port, just append it via http(s)://(url/ip):port/ You can also include username:password for basic auth in front of url.
That said, unfortunately rachio doesn’t push weather data to webhooks. You’ll be able to get a notification when weather has caused your schedule to skip for example, but not really any granular weather data. To know all of the data available via a webhook, you can check here:
Webhook types and sample JSON (readme.io)