Kodi Community Forum
Parsing error when using VideoLibrary.RemoveTVShow method - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Kodi Application (https://forum.kodi.tv/forumdisplay.php?fid=93)
+---- Forum: JSON-RPC (https://forum.kodi.tv/forumdisplay.php?fid=174)
+---- Thread: Parsing error when using VideoLibrary.RemoveTVShow method (/showthread.php?tid=309968)



Parsing error when using VideoLibrary.RemoveTVShow method - djbloc - 2017-03-19

Hi

I'm trying to use the VideoLibrary.RemoveTVShow method on Kodi 17 (API Wiki) but I'm getting parse error in response.

Code:
curl -H "Content-Type: application/json" -X POST -d "{'params': {'tvshowid': 1, 'id': 2}, 'jsonrpc': '2.0', 'method': 'VideoLibrary.RemoveTVShow'}" http://192.168.1.10:8080/jsonrpc

Code:
{"error":{"code":-32700,"message":"Parse error."},"id":null,"jsonrpc":"2.0"}

What am I doing wrong?


RE: Parsing error when using VideoLibrary.RemoveTVShow method - ncarthy - 2017-03-19

The "id" property is in the wrong place.

Code:
"{'params': {'tvshowid': 1}, 'id': 2, 'jsonrpc': '2.0', 'method': 'VideoLibrary.RemoveTVShow'}"



RE: Parsing error when using VideoLibrary.RemoveTVShow method - djbloc - 2017-03-19

(2017-03-19, 17:05)ncarthy Wrote: The "id" property is in the wrong place.

Thanks for the suggestion. Although this doesn't seem to have fix the error. I still get the same response.


RE: Parsing error when using VideoLibrary.RemoveTVShow method - ncarthy - 2017-03-19

Can you post the full curl command again? Maybe there is another formatting error somewhere.

Have you also checked that a tv show exists with id=1?