Send Trigger via Shortcut from iPhone without wifi

I want to trigger a flow in node-red just by pressing a shortcut on my iphone.
But the problem is that it is supposed to work even without wifi.
My hope is that I can somehow manage it with the Telegram Bot.
But here i need your help.

My current status looks like this:
-I set up a bot in Telegram.
-I put this in a group and declared it as admin.
-Now I can send messages using the url using the bot token and the chat id.

( )

Now all messages are displayed in the group, which I have triggered via the URL.
But the problem is that it didn't arrive at the Telegram node in node-red.
If I write to the group with my own mobile number where the bot is, I get a message via the Telegram node.

Is there a possibility to solve the problem?
Or does someone have a completely different approach to solve the problem?

Thanks for your help.

Which telegram bot node are you using?

Using a bot node, you don't need the URL, that is taken care of for you.

Set up correctly, any msg in a telegram group directed to a connected bot or directly to the bot itself will appear in node-red. You can also use telegram commands (start with a /) if you wish and the bot can respond with a custom keyboard if needed so that the user can enter specific information.

I use the shortchuts app from ios.
Here you have the option of opening a specific URL simply by pressing the shortcut button.
Here I insert the URL, which sends a message to the Telegram bot.
As I described above.
When executing the URL, a message will appear in the bot chat window.
As if the bot had written me a message.
And at that point I would like to be able to read this from Node-red.
If I answer directly in this chat, I get this via the Telegram receiver node.

But this is not what I want.
I want to run the shortcut and get a notification right away in Node-Red.

Thanks for your help
Kind regards klopo

Automatic message to a telegram bot : shortcuts (

Doesn't look like you can do it from the Shortcuts app.

The shortcut app is no problem. It is working.
The message arrives at Telegram Bot

The problem is that I don't receive this message about the Node-Red node.

Sorry, you missed the important point. You can send from Shortcut to an actual Telegram conversation. But the bot cannot interact with that message.

Thank you for your help and information.
Do you have another suggestion to reach my goal?
There are many ways to send a push message from Node-Red to smartphone.
( Pushover, Simplepush, Pushbullet )
But I can't find anything useful to send a push message from the smartphone to Node-red.
I'm surprised this problem hasn't been addressed yet. Am I the only one with this wish ? :smiley:

Analyze why this does not work:
If a bot can respond to itself: infinite loop.

The easiest way: use a vpn to the location where node-red is running.

Other solution:

If using homekit, add a "fake" switch, this can be used to listen/execute for shortcut actions.

To make this work, you can add the node-red-contrib-homekit-bridged node and create a new switch, add it to homekit. You can listen to the status and trigger your flow.

1 Like

Yes that's with the loop is true. Thanks for the advice.

I set up a VPN connection for myself, but only for special tasks.
My wife / children should also have access to this function. And if I have to tell them every time they have to activate the VPN connection, I know where that ends.
In addition, the distribution of rights does not make things any easier for everyone.

I also thought about the possibility of doing this via a fake switch. I use Homebridge and am very happy with it.
Unfortunately, I don't have a Homepod/Apple TV that can act as a home hub.
So I only have access to these functions when I'm on wifi.
And currently there is no emulator for the home hub.

Probably the easiest would be to get a Homepod Mini. That would solve a lot of problems :smiley:

Another thing I found is IFTTT in combination with Webhook.
This topic is still completely new to me.
The first attempts have all failed.
Unfortunately, I can only find a few tutorials.
Most of them also refer to the sending of Node-Red --> Smartphone
Like this:

Rather than a VPN which is a concept that is massively over-used and misunderstood, I recommend using an intermediary service. My current favourite, though a little more complex to set up the first time, is Cloudflare Zero Trust. The reason being that it is incredibly flexible and has 50 user id's available in the free tier. Which means that you don't need to faff with Node-RED authentication.

There are plenty of other services of similar nature though.

That doesn't solve your issue, you would still need to create a connection to Node-RED. Might as well stick with Shortcut if you only use Apple mobiles. Also, the free tier for IFTTT has a 15 minute delay on most things (not sure about web hooks).

I finally made it. With IFTTT and Webhook.
Here is a short summary.
Install IFTTT on iPhone.
Create an applet:
IF: Shortcut automation started
THEN: Webhook Make a Web request.
Set the webhook to:
Content Type:
{"Trigger":"On"} is my static ipv4 address of my internet connection.
The standard port for node-red is 1880. This must be enabled in the router.

http in node:
Method: POST
URL: /trigger

http out node:
Leave empty

Connect http in node and http out node
Pick up message at http in node.

After deploying node-red I had to restart the node-red service. Only then did a message arrive in the debug node.

Unfortunately you have to use a static IP.
Maybe you can also enter a server for a DDNS service here?
Unfortunately I have no experience in this area
Maybe someone here can answer this question?

Here is the tutorial I used as a guide.

Thanks for the nice support.
Always nice to have learned something new :slight_smile:

Except that you have now opened a route from the Internet to your node-red server with no security on it. This is quite dangerous.

With Telegram, that security is taken care of for you. When you go your route, you need to deal with it yourself.

This is why I recommended an intermediary service that provides this security for you.

This is not quite true. You can register a domain via someone like Cloudflare. They support a standard protocol that lets you use another service to post updates to your dynamic IP to their DNS so that the name is always correct.

Yes, but you really need to go a bit further and quickly sort your cyber issue before it becomes a problem.

OK. Thank you very much for the hint.

Sometimes you should think carefully before you do something.

I was just a little shocked when I simply entered my static IP address with the port on my cell phone without wifi and arrived at my Node-Red login mask.
But what else should I expect.....:dizzy_face:

Ok I'll take a closer look at the Cloudflare service.