I am trying to use setup an IFTTT applet for Google Assistant using the “Say a phrase with a text ingredient” and of course getting an error on openHAB saying "Received invalid command ‘off ’ for item "BedroomLights’ because it is sending the ingredient as “off” instead of “OFF” that openHAB needs. So how do I make openHAB accept lower-case off/on or even the other way, make IFTTT send it as UPPER-CASE.
The better approach would be to make IFTTT send it uppercase if possible, but if not, you could create a String item and a rule, and send the command to the String item:
items/my.items
String MySwitchString
Switch MySwitch
rules/my.rules
rule UpperCaseSwitchCommand
when
Item MySwitchString received command
then
MySwitch.sendCommand(receivedCommand.toString.toUpperCase)
end