iOS Actionable Notification - No Actions

Thanks Mark, sorted!

Hi Mark,
Sorry to be a paid but could you also tell me where I’m going wrong here? I want to send a message with the travel time, I have this in my automation.yaml file;

   action:
     - service: script.sonos_say
       data:
         sonos_entity: media_player.bedroom_2
         volume: 0.5
         message: "Richard has left work, and will arrive Home in about, {{states('sensor.Richard_To_Home')}} minutes"

And these in my configuration.yaml file;

  - platform: google_travel_time
    name: Richard To Home
    api_key: xxxx.xxxx.xxxx.xxxx.xxxx.xxxx
    origin: device_tracker.google_maps_richardpretiousgmailcom
    destination: zone.Home

zone:
  - name: Work
    latitude: 888.888888
    longitude: 222.2222222
    radius: 100
    icon: mdi:office
  - name: Home
    latitude: 999.9999999
    longitude: 111.111111
    radius: 100
    icon: mdi:home-variant

I am getting this error;
Invalid config for [automation]: [zone] is an invalid option for [automation]. Check: automation->trigger->0->zone. (See /config/configuration.yaml, line 211). Please check the docs at https://home-assistant.io/components/automation/

Scrap that last one, I’ve worked it out - I think.

I’ve tried to get this to work off an on over the past few months, and never seem to get the alert on my phone. Any sugestions as to what I’m doing wrong

ios:
  push:
    categories:
      - name: Garage Alert
        identifier: 'garage_alert'
        actions:
          - identifier: 'CANCEL_GARAGE_ALERT'
            title: 'Cancel Alert'
          - identifier: 'CLOSE_GARAGE'
            title: 'Close Garage'

Automations

- alias: Actionable Garage Door Alert
  trigger:
  - platform: state
    entity_id: cover.garage_door_opener
    to: 'open'
    for:
      minutes: 3
  condition:
  - condition: numeric_state
    entity_id: sensor.ha_runtime_in_minutes
    above: 1
  action:
  - service: notify.ios_pauls_phone
    data:
      message: "Garage Door is Open"
      data:
        push:
          category: "garage_alert" 

- alias: iOS Actionable Notification for Garage Door
  trigger:
    platform: event
    event_type: ios.notification_action_fired
    event_data:
      actionName: CLOSE_GARAGE
  condition:
  - condition: numeric_state
    entity_id: sensor.ha_runtime_in_minutes
    above: 1
  action:
    service: cover.close_cover
    entity_id: cover.garage_door_opener

I opened the garage and never got an alert. I did go into the app and refreshed the sounds and notifications after setting this up.

Do you get the notification when you test the actionable alert notification from within home assistant?

Same thing here. I have actionable notifications for the Alarm clock (Creating an iOS Alarm Clock w/ Snooze and Awake Actionable Notifications). The notifications shows up, but when I click on them the action does not work. It calls a script that, using it through front end, works perfectly.

Here is the code

ios:
  push:
    categories:
      - name: alarm_clock
        identifier: 'alarmclock'
        actions:
          - identifier: 'AWAKE'
            title: 'Awake'
            destructive: yes
          - identifier: 'SNOOZE'
            title: 'Snooze'
            destructive: no

And the automations

- id: a_alarm_clock_awake_action
  alias: alarm clock awake action
  initial_state: true
  hide_entity: true  
  trigger:
    platform: event
    event_type: ios.notification_action_fired    
    event_data:
      actionName: AWAKE
  action: 
    - service: script.s_alarm_clock_awake
      entity_id: script.s_alarm_clock_awake
  
- id: a_alarm_clock_snooze_action
  alias: alarm clock snooze action
  initial_state: true
  hide_entity: true
  trigger:
    platform: event
    event_type: ios.notification_action_fired    
    event_data:
      actionName: SNOOZE
  action:
    - service: script.turn_on
      entity_id: script.s_alarm_clock_snooze

I did end up getting this to work. 100% user error. My notify service had a typo.

I do have a very similar one that does not work though. it’s based on a device tracker. Alert never triggered.

ios:
  push:
    categories:
      - name: Shopping Alert
        identifier: 'shopping_alert'
        actions:
          - identifier: 'CANCEL_SHOPPING_ALERT'
            title: 'No'
          - identifier: 'OPEN_GARAGE_WHEN_I_GET_HOME'
            title: 'Yes'
- alias: Actionable Open Garage Door When Tracy gets Home
  trigger:
  - platform: state
    entity_id:
      - device_tracker.tracy_all
    to: 'Costco'
    for:
      minutes: 5
  - platform: state
    entity_id:
      - device_tracker.tracy_all
    to: 'Sams'
    for:
      minutes: 5
  condition:
  - condition: numeric_state
    entity_id: sensor.ha_runtime_in_minutes
    above: 1
  action:
  - service: notify.ios_pauls_iphone
    data:
      message: "Looks like you're Shopping.  Do you want the garage to open when you get home?"
      data:
        push:
          category: "shopping_alert" 


- alias: iOS Actionable Notification to open Garage when Tracy Gets Home
  trigger:
  - platform: event
    event_type: ios.notification_action_fired
    event_data:
      actionName: OPEN_GARAGE_WHEN_I_GET_HOME
  condition:
  - condition: numeric_state
    entity_id: sensor.ha_runtime_in_minutes
    above: 1
  action:
  - service: input_boolean.turn_on
    entity_id: input_boolean.open_garage_for_tracy

Hi Max - am I missing something? Where would you put the action for the button, here? As in what you want HA to actually do when a button is pressed on the iOS device? Thanks
Really struggling with this.

I’m not sure, it was a long time ago and I don’t use iOS actionable notifications anymore.

But I believe the next iOS app update will change the notifications completely so maybe wait until that’s out.

Thanks Max - eventually got it sorted. :slight_smile:
Out of interest, what do you use now?

Good to hear.

I don’t have a use for actionable notifications right now actually. Maybe in the future.

Hi guys,
#im trying get this to work but no buttons appear on my display. :frowning: Im trying since 1 week, but now, i need some help. Maybe anybody can help please??

my configuration.yaml

ios:
  push:
    categoeries:
    - name: Vakuum
      identifier: 'vakuum'
      actions:
      - identifier: 'RUN_VAKUUM'
        title: 'Start Cleaning'
        activationMode: background
        authenticationRequired: no
      - identifier: 'DO_NOTHING'
        title: 'Do Nothing'
        activationMode: background
        authenticationRequired: no

and my two automations in the automation.yaml:

- id: '1566881863885'
  alias: Kalle Push
  trigger:
  - entity_id: device_tracker.birger_iphone
    platform: state
    to: not_home
  action:
    service: notify.ios_birger_iphone
    data:
      title: Kalle
      message: Cleaning?
      data:
        push:
          badge: 0
          category: 'vakuum'
- id: '15668818637645'
  alias: iOS Event Trigger Kalle
  trigger:
  - event_data:
      actionName: RUN_VAKUUM
    event_type: ios.notification_action_fired
    platform: event
  condition: []
  action:
  - data:
      entity_id: vacuum.kalle
    service: vacuum.start
  initial_state: true

That would be so nice.

Nobody here who can help me? :frowning:

It looks like the indentions are off?

I’ll post mine, I haven’t used it in awhile but it did work when I was using it.

I’m not by my computer right now but I promise not to forget!

You wrote ‘categoeries’ instead of ‘categories’, third line on your configuration.yaml.

That was the error! Thank you so much

1 Like

I am having a similiar issues. I have three actionable categories but one of them does not provide me any options. I’m sure it’s super simple, but I cannot seem to find it

ios:
  push:
    categories:
      - name: Garage Alert
        identifier: 'garage_alert'
        actions:
          - identifier: 'CANCEL_GARAGE_ALERT'
            title: 'Cancel Alert'
          - identifier: 'CLOSE_GARAGE'
            title: 'Close Garage'
      - name: Shopping Alert
        identifier: 'shopping_alert'
        actions:
          - identifier: 'CANCEL_SHOPPING_ALERT'
            title: 'No'
          - identifier: 'OPEN_GARAGE_WHEN_I_GET_HOME'
            title: 'Yes'
      - name: Guest Alert
        identifier: 'guest_alert'
        actions:
          - identifier: 'GUESTS_GONE'
            title: 'No'
          - identifier: 'GUESTS_HOME'
            title: 'Yes'

This is the automation for the one that is failing

- alias: Actionable Guests at home when security is armed
  trigger:
  - platform: state
    entity_id:
      - binary_sensor.motion_sensor_living_room_motion
    from: 'off'
    to: 'on'
  condition:
  - condition: state
    entity_id: input_select.security_system
    state: 'Armed (Away)'
  action:
  - service: notify.ios_tracys_iphone
    data:
      message: "Are there Guests in the House?"
      data:
        push:
          category: "guest_alert"
  - service: notify.ios_pauls_iphone
    data:
      message: "Are there Guests in the House?"
      data:
        push:
          category: "guest_alert"

I never get the Yes or No, options. I do get the iOS Alert, just not actionable.

Anyone see anything obvious.

Which app are you using? 1.5.1 or 2.0?

1.5.1 but strangely enough another actionable notification does work.

since these seem correct, it could be the trigger automation? You didnt post that, so maybe have a look at that?

- alias: 'IOS - All In one'
  id: 'IOS - All In one'
  trigger:
    platform: event
    event_type: ios.notification_action_fired

etc etc