Siri shortcuts on 2.0

Hello. Setting up 2.0 and got some difficulties with siri shortcuts.

Is this right way to do that? Should we write service data manually?

service data is: {"entity_id":"switch.your_entity"}

2 Likes

I understand that. I am asking id I should write every service data manually copying from home assistant and using quotes writing it in siri shortcut app. Earlier we could just choose from list of entities.

Write it in manually

Yes that’s the only way it works.

Are there going to be changes anywhere soon? for example in hassapp it is 3 clicks to make a shortcut, and I spend stupidly more time to find entity_id and write it manually, because there is no way to copy it from services from ios app

I have pretty much shortcuts to make, so should I wait or go with writing manually entity_id’s
As I remember Robbie said that there will not be any json on 13 ios shortcuts.

I do not use siri often, but sometimes it is conveniently

Rather than writing the JSON manually it is easier to use the “Dictionary” action like this (make sure it goes above the Call Service action):

If you are planning to make a bunch of these, you can long press on an existing shortcut and then select “Duplicate” to make it quicker.

I will be writing the documentation page for Shortcuts soon with more examples and downloadable shortcuts.

4 Likes

Nice Sean. I didn’t know you could do that.
edit: so I can’t find dictionary… what do I add that from? It’s not Home Assistant…
I think I see but I still have to type it in right? So may as well just enter the json…

Correct, it’s not part of Home Assistant actions but a generic Shortcuts action. When you press the blue plus button to add a new action, Dictionary is located inside the “Scripting” category, or you can simply use the search bar to find and add it.

Another tip for the Shortcuts app: if you press the “info” button next to the action name you can save it as a favorite to find it more easily.

You still have to type the entity_id, yes. The main benefit of this approach is that you don’t have to type the curly braces, colons, and quotes etc which can be tricky if you’re not familiar with JSON syntax. And even if you are familiar with JSON it’s a bit annoying to constantly change back and forth between keyboards to type those special characters in.

I’ll give dictionary method a go next time I make a shortcut. Though to be honest, I usually find it easiest to type out what I need on my MacBook, copy it, and paste directly into Shorctuts. So much faster than typing on the phone, and for templates, I can do it in HAs template page to make sure I get it right.

Gotcha. I have disabled that bloody smart keyboard because of this anyway. Thanks for the tip/confirmation.

The next version of Home Assistant should make copying the entity ID a bit easier on mobile devices - there will be a copy button next to each entity on the States page. You can see a preview here.

That’s pretty cool. Very useful improvement.

Very cool indeed. I’m not a fan of the feedback I get from Siri - “Home Assistant says: called script.turn_on”. Does anybody have experience catching this feedback and providing a more elegant alternative?

1 Like

I too would like to know how to suppress the “Home Assistant says…” output from Siri. Does anyone know how to do that?

While it’s not Siri, I added the shortcut to the widget on the lock screen. I just swipe and hit the buttsson. No feedback.

I will use this until Siri can be silenced :slight_smile:

1 Like

Another option is to set up homekit integration. This method requires more work but you don’t need to set up a shortcut and you can control entities with Siri.

It also takes security into account for example when unlocking a door or opening a cover it requires you to unlock your iPhone.