Text yes to run a routine or piston


#1

1) Give a description of the problem
Is there a way to text myself a question and then reply with a yes that would execute either a routine or piston?
Ex. Text - do you want me.to run den off routine?
If I answer yes, the run the routine


Opening the Door when you arrive home with Intractive Push Notification
#2

You can use webCoRE > Tasker notification, which can have up to three clickable buttons in the notification tray… and have your response sent to webCoRE via URL link or using arguments.


#3

I saw a post while back, someone created a piston that,
he receives an SMS message asking if lights or media unit should go off or not (just in case if he fell a sleep)
i looked but couldn’t find at the moment…
but to answer your question YES it is possible and someone wrote a piston for it… you just need to search (mostly example pistons)

and here is another one i just saw, not exactly what you are asking but very close:


#4

I have never seen a case where webCoRE can receive & act upon an SMS, but I would love to be proven wrong. So far, I have only seen it using a 3rd party app, or using some other method (besides SMS) on the return trip.


#5

If I remember correctly SMS sends the URL of a piston - whit a question attached - that needs to be executed. You click on the link your piston is triggered… And I know what @WCmore is talking about, it won’t be a YES text. It will be cliking on the link that executes a piston acts like it is a YES.

And i am about to implement something similar actually…

For instance:
sms sends me a report with lights that are left ON
and it asks, Do you want me to turn them OFF (link here)

if you click on the link
your piston that turns off all the lights that were ON, will be executed (variable)

@WCmore my explanation wasn’t for you (he tought me most of the stuff I know today) :))))) it was for people who would read this later on:)))


#6

Oh, right…That is what I meant when I said,
“have your response sent to webCoRE via URL link”.

I admit, that method is simple to implement, and perhaps the best option for iPhone users.


#7

This one?


#8

Wouldn’t you need to log into the ide each time?


#9

No not that one…
I have some time today, I will work on my house about this piston and post it here.
But once again, it won’t be texting back YES…
it will be sms is asking if I want to click on the LINK that ends up being YES


#10

The IDE is not needed whatsoever. The link found highlighted below can run a piston from any app that can display a link. (SMS, email, etc)

temp

Simply touching the link, will execute the piston. (so do not share this URL!)

Ideally, the piston it points towards will have no triggers at all, and once saved, you should see this up top:


#11

Don’t forget that you can shorten that super long URL by pasting it once on a page like bitly.com, and then using the shortened URL in your text messages.


#12

ok here it is @Bboy486,

Two pistons…
Piston #1
checks the left open lights…
Saves them to a variable
that variable to global variable
Provides a link and sends the SMS message contaning YES link

Piston #2
Executes and turns off all remaining lights.

NOTES :slightly_smiling_face:
1 - I am not a coder so, I am sure someone can come up with a better way of writing this. Even maybe with a single piston. I’d love to learn more so please share if any neater or better way of doing this.
2 - Maybe saving to a variable and saving that to a global variable was a waste of time:))) I just coudn’t figure out how directly save to a global variable LOL
3 - Let me know if you need any explanation on any lines. (or creating a global variable)
one thing for sure, I believe, as long as you use two pistons global variable is the way to go.
4 - you can even add more stuff like, if you don’t respond to SMS in X minutes, it sends it again until you say YES or NO (I did not add that part yet)
5 - Just tested and works well:)))
6 - Tiny url was a great reminder I had forgotton about it thank you @WCmore
7 - I guess you can have more than 30-40 light bulbs in a single piston??? I have a similar piston that controls open/close sensors and I have around 30 of them in it.
8 - I have NEVER CANCEL (task policy) at line# 24 but some how the snapshot doesn’t show??


#13

The issue is yes it works on the external url but when I copy it and add it to the piston I get an error.

I’m not sure why it is only working on the click to open/excited but not the same link in the text I’m sending myself.


#14

What error exactly?

If the link is going to a piston that has a trigger, it may do absolutely nothing.
(notice Ike’s “oe7p” piston has no triggers at all)


#15

it would be better if you share the green snapshot of both pistons… (beware, the URL in the text areaq will show the real url you are using - you don’t want that while sharing publlicly)


#16

This is the text I get


This is the piston that will run – works in the external url in webcore but not on the text.


#17

When clicked in the SMS {“result”:“ERROR”,“timestamp”:xxxxxxx}

When clicked in external url {“result”:“OK”,“timestamp”:xxxxxxx}


#18

When doing a bit of testing, I was able to get this exact error only when there was a typo in the last section of the URL. (after “/execute/”)

Can you confirm that your URL in the piston ends with:

/execute/:32digitshere:


#19

Yes it is the same as the External link. I pasted both in my text to compare. No difference.


#20

For anyone following this thread for some reason if you use Android/Pulse this will not work. It wants to open the link within the app and it causes an error. If you long press and open in browser it will not complete.

I ended up using a Google voice number and GVoice app.