Is there an issue with IFTTT? This is basically how the examples are written. I can turn the LED on with an IFTTT “Do” but no event is triggered by the publish?
You can in fact do that. I've been doing it for months, although it's not a recommend practice. It'd be better to set a flag in the function, and then handle that in the loop where it check for the flag.
I’m guessing it’s an error in the configuration of the IFTTT settings. I just made a new recipe with one of my existing publishes (also called from within a function), and it works just fine.
@camow7, could you show us how you’ve set up IFTTT?
Okay, I tried the exact code above, and it’s working perfectly over here. I send the “On” command, the LED toggles on, and after a few seconds IFTTT triggers a function call on a different Core.
Since your code is okay, it’s most likely a problem with the IFTTT setup.
Ok so it was an issue on the IFTTT side. It turns out that if you publish something with only 1 argument:
Spark.publish("CurrentTime");
But then have text in the “is(Event Contents)” on IFTTT the event will not fire.
I didn’t realise your “is(Event Contents)” had to match your second argument exactly. I thought it stored the value of the second argument or ignored it if one wasn’t sent. I just cleared the “is(Event Contents)” field on my IFTTT recipe.