PATCH Request with apoc.load.jsonParams

Hi Everyone

I was wondering if it is possible to execute a POST request to an API using apoc.load.jsonParams?
It wold come in handy to update a lot of tuples in another database.

I tried the following without success:

CALL apoc.load.jsonParams($URL+"/api/v1/customers/557",
{accept:"application/json; charset=UTF-8",`Content-Type`:"application/json; charset=UTF-8",
'{"description": "test2"}',

The error I am getting is: 405 - Method Not Allowed. Therefore I assume apoc still sends the request as a GET instead of PATCH.

Here's the request I am trying to send as curl;

curl -X PATCH "" 
-H "accept: application/json; charset=UTF-8" 
-H "authorization: Basic YWRtaW46MjFDZW50dXJ5" 
-H "Content-Type: application/json; charset=UTF-8" 
-d "{ \"description\": \"test\"}"

Kind Regards from Switzerland

Yes please you have to put the method into the headers, like here:

call apoc.load.jsonParams("", 
1 Like