Using an automation, is it possible to change my iPhone focus state?

When I’m watching a movie, I want my iPhone focus mode to do not disturb. I got the movie part done but I’m not able to change focus mode.

Thank you for your help.

i do this

data:
  message: command_ringer_mode
  data:
    command: vibrate
    ttl: 0
    priority: high
action: notify.mobile_app_rhmobil

look here Notification Commands | Home Assistant Companion Docs

That’s only supported on Android. You can tell because the Ringer Mode section where this command is referenced has the Android logo only.

Since Apple is more locked down, there might not be a way to set do not disturb mode on the phone. Hopefully someone will show up and prove me wrong.