Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save audiefile/158a6c87671220276bce5c4dc0492068 to your computer and use it in GitHub Desktop.
Save audiefile/158a6c87671220276bce5c4dc0492068 to your computer and use it in GitHub Desktop.
Draft Documentation for Triggering “Eating Soon Mode” via Pebble Watch Uses IFTTT and pebble watch app ThisButton by The Hub Media
• Setup IFTTT account
• Connect to Maker channel and note secret key
• Create if recipe
o if Maker 'Receive a web request'
• The Event Name doesn't matter, just make note of it. I suggest avoiding spaces as I've seen them cause problems in the past.
o then Maker 'Make a web request'
• URL: https://mynightscout.com/api/v1/treatments.json
• Method: POST
• Content type: application/json
• Body: { "enteredBy": "Maker", "eventType": "Temporary Target", "reason": "Eating Soon", "targetTop": 80, "targetBottom": 80, "duration": 60}
• Note these are the default settings and can be customized.
• Note the enteredBy field is not required and can be changed to a value more meaningful to you or omitted entirely.
• Note if your nigthscout instance requires authorization for careport evnets (TREATMENTS_AUTH=on) and "secret":
"abc123" to the end of the post Body, where abc123 is your hashed api secret. (Thanks @JasonCalabrese)
• Test it works on the Maker Channel by looking under How To Trigger Events. If correctly setup, you should see a new temp target event on you Nightscout site after IFTTT says it successfully triggered.
• On your phone in the pebble app search for the ThisButton app in the pebble app store.
• Configure app
o Note the description for the difference between Name and Event Name
• To make things super easy add a shortcut on your pebble for the ThisButton app
o If you don’t have shortcuts already, press and hold either the up or down button and follow the prompts.
o If you have both shortcuts programmed and want to change one, go to menu > settings> quick launch and follow prompts.
Copy link

ghost commented Jul 17, 2020

Hi there, thanks so much for your reply! I will try to figure out how to have it running. I'm just stuck at triggering my existing recipe... Will investigate deeper. if you can get in touch using my email, it would be fantastic. nanolifelab at g mail dot com as this interface is confusing for me. Thanks a lot Rachel!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment