Sending custom commands to Kodi via API call

i am trying to send the below to kodi via home assistant

{
  "method": "VideoLibrary.Export",
  "params": {
    "options": {
      "overwrite": true,
      "actorthumbs": false,
      "images": false
    }
  },
  "id": 1,
  "entity_id": "media_player.kodi"
}

it sends but doesn’t work and i get this in the debug console

Run API method media_player.kodi.VideoLibrary.Export({‘params’: {‘options’: {‘overwrite’: True, ‘actorthumbs’: False, ‘images’: False}}, ‘id’: 1}) error: {‘code’: -32602, ‘data’: {‘message’: ‘Too many parameters’, ‘method’: ‘VideoLibrary.Export’}, ‘message’: ‘Invalid params.’}

i guessing the formatting is off?

I can do other things like launch add-ons. But this always falls over

Expanding the schema here: https://kodi.wiki/view/JSON-RPC_API/v9#VideoLibrary.Export

It seems you also need to specify a path to export the library to.

There’s are two options, one is “Single file” which requires a file path, the other is “seperate files” which puts the files next to the media files, so a path name isn’t required for that, which is the one i am trying to use

https://kodi.wiki/view/Import-export_library

Edit:

The original JSON is here, but I can’t get it working in HA :frowning:
curl -X POST -H 'content-type: application/json;' --data '{ "jsonrpc": "2.0", "method": "VideoLibrary.Export", "params": { "options": { "overwrite": true, "actorthumbs": false, "images": false} }, "id": 1 }' http://10.0.1.16:8083/jsonrpc

I explained this here

Took me ages to figure it out why it was failing
I think is the wrong issue thread, but the problem exists. I copied the kodi component to custom components folders and added the modify statement.