Notifications to my iPhone

Currently working on the demo openHAB and wanting to get an alert to my phone when a light has been switched on.

rule "Bedroom Light"
when
Item Light_MH_Lights_Bedroom changed from OFF to ON

then   
    sendBroadcastNotification("Bedroom Light has been turned on ")   
end

it is currently coming with an error for the rule:
“Couldn’t resolve reference to JvmIdentifiableElement ‘sendBroadcastNotification’.”

Thanks James

You need to get an account setup on my.openhab.org and the OpenHAB app installed on your iPhone. Once that’s done, you can use sendNotification or sendBroadcastNotification commands.

https://my.openhab.org/docs/notifications

There are other ways that avoid using my.openhab.org but they are much more complex.

Are you seeing the error “Couldn’t resolve reference to JvmIdentifiableElement ‘sendBroadcastNotification’.” in the logs or in the OpenHAB Designer when editing the rules? I see the same error in the designer but the rule works fine. Here is my rule the sends a test notification to my iPhone:

/* RULE TO TURN ON LIVING ROOM LIGHT */
rule "turn LivingRoom on"
when
	Time cron "0 00 19 ? * *"
then
	if(LivingRoom.state==0) {
		var HSBType light = new HSBType("51,20,100")
			LivingRoom.sendCommand(light)
                        sendBroadcastNotification("Living Room Light is OFF")
		} 
end

Hello @geoffm33 @tannebil

Thank-You for the replys,

I have decided to use IFTT, great service. I recommend if not already using.

Thanks James

I do also use the “sendbroadcastnotification” in my rules and I also get this error in the openHAB Designer. My rule also does work fine.

So we simply should ignore this error message?

Which IFTT app did you use?