From 4f8b755a2abaeae4fe69b6681627c3bfab4a1dc3 Mon Sep 17 00:00:00 2001 From: Nick Steel Date: Mon, 8 Oct 2018 17:24:59 +0100 Subject: [PATCH] docs: update curl HTTP POST example Must set 'Content-Type: application/json' header due to #1668 --- docs/api/http.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/api/http.rst b/docs/api/http.rst index f2a50b27..56b72dc1 100644 --- a/docs/api/http.rst +++ b/docs/api/http.rst @@ -25,7 +25,7 @@ to listen to events, you should probably use the WebSocket API instead. Example usage from the command line:: - $ curl -d '{"jsonrpc": "2.0", "id": 1, "method": "core.playback.get_state"}' http://localhost:6680/mopidy/rpc + $ curl -d '{"jsonrpc": "2.0", "id": 1, "method": "core.playback.get_state"}' http://localhost:6680/mopidy/rpc -H 'Content-Type: application/json' {"jsonrpc": "2.0", "id": 1, "result": "stopped"} For details on the request and response format, see :ref:`json-rpc`.