I would like to create a script to disable the NextPVR Kodi addon via the JSON-RPC API. Based on the example in the Kodi integration docs and the API docs, I’ve put together this script but I get the error below on running the script.
Script:
service: kodi.call_method
data:
method: Addons.SetAddonEnabled
addonid: pvr.nextpvr
params:
enabled: false
target:
entity_id: media_player.familyroom_kodi
HA Log Error:
Run API method media_player.familyroom_kodi.Addons.SetAddonEnabled({‘addonid’: ‘pvr.nextpvr’, ‘params’: {‘enabled’: False}}) error: {‘code’: -32602, ‘data’: {‘method’: ‘Addons.SetAddonEnabled’, ‘stack’: {‘message’: ‘Missing parameter’, ‘name’: ‘enabled’, ‘type’: [‘string’, ‘boolean’]}}, ‘message’: ‘Invalid params.’}
Here’s the relevant API documentation
Any help to troubleshoot would be appreciated.