using API to close an issue?

Added by Wim Bertels 5 months ago

Trying out:

curl -v -H "Content-Type: application/json" -X PUT --data-binary "@close.json" -H "X-Redmine-API-Key: secret" https://myredmineserver/issues/1927.json

where the status of issue 1927 is 1, new.
This gives no errors on the client,
on the server in the logs is shown: (dutch version)
Started PUT "/issues/1927.json" for IP at 2020-03-20 15:30:50 +0100
Processing by IssuesController#update as JSON
  Parameters: {"issue"=>{"status"=>{"id"=>5, "name"=>"Gesloten"}}, "id"=>"1927"}
  Current user: myredmineuser (id=3)
  Rendered text template (0.0ms)
Completed 200 OK in 110ms (Views: 0.4ms | ActiveRecord: 81.8ms)

The close.json file contains:


But this has no effect (although myredmineuser has admin rights)?

Any thoughts, suggestions?