Unable to find service kodi/call_method

Hi,

I would like to use kodi inside an automation but I am only getting the message:
Service not found for call_service at pos 1: Unable to find service kodi/call_method

I have the following tried the follwing entry inside my automation.yaml:

- id: '1568720577413'
  alias: Kodi Quit
  trigger: []
  condition:
  - condition: state
    entity_id: media_player.kodi_livingroom_local
    state: playing
  action:
  - data:
      entity_id: media_player.kodi_livingroom_local
      method: Application.Quit
    service: kodi.call_method

Any hints?

Which version of home assistant are you using? The change from ‘media_player.kodi_call_method’ to ‘kodi.call_method’ was only recently in the 0.98 release. The error message looks like you are using an older version.

I actually also did try media_player.kodi_call_method as well. I am on version 0.98.5

Is the service kodi.call_method listed in the services list in developer tools?

I am not sure what happens if you quit kodi while this method is called. Presumably the service disappears when kodi quits (unless you have another kodi media-player in HA.)

Good point. There are no kodi methods at all in the services list. Shouldn’t they be there by default? Do you know how to add those?
Thanks

They appear if there is a kodi media player configured.

1 Like