This is a bit off topic, but hopefully there are others trying to accomplish this, and want to get involved.
i have been working on creating a zapier recipe for Spark.
if you arent familiar, zapier is like IFTTT but they allow you to write triggers and tasks. i also think they have much broader support of “channels” because of it…seriously, the list of supported API enabled services is amazing. https://zapier.com/status/
this would allow me to control my spark through almost any API. i could unlock my kegerator when i successfully commit to github. i could make a sandwich when i complete a google task…its endless.
so far ive got in working in a basic (albeit incomplete) form, and i wanted to share my progress, in case anyone else is trying something similar
First off, Authentication setup is pretty straightforward. I am asking for access_key and device_id when setting up a trigger or action.
Ive made the Device ID not required, since i want to be able to specify it later on as a selection (support for multiple cores in one recipe)
For authentication, I select API Key (Query String), and create an Auth Mapping.
Then I created a new Trigger for retrieving all the cores:
It has NO trigger fields (since no human or recipe will be directly interfacing with the trigger, it will just be used to populate dropdown lists)
Then for Data Source, it was pretty straightforward.
So then I created a new trigger for use by a recipe. This trigger is intended to check a variable generated by my Spark Core.
Here is the trigger screen to check the variable. The dynamic dropdown perfectly shows the list of available Spark Cores in my account!
At the bottom of the trigger page, I created a dynamic dropdown, which is populated by the “coreslist” trigger we just created. Now, if I add more Spark Cores to my account, they show up automatically!
So the last thing I do is create a URL trigger to pull the variable (in this case “position”). I tried to make this non-hardcoded, but had terrible luck.
So its getting there…but still not fully working.
But here is the result so far.
I create a recipe to check the Spark variable position, and then send an email.
The dynamic drop down is working nicely.
And the results seem to be working too! (correction, the results are not working…these results came from having a sample result JSON already populated)
All looks good…
Then I hit “Test Spark Trigger”
Doh!
If anyone has any experience with this, or just wants to recreate this for fun and see how it goes (Zapier is free)
Please share your experience.
Thanks!