Hello folks, I'm trying to get started with Rundeck API. I really prefer to parse JSON output and I've read that almost every endpoint can output JSON/XML.
I've added "Accept" and "Content-type" to "application/json" but the output is always XML:
MY REST CALL:
GET /api/1/system/info HTTP/1.1Host: myhost.mycompanyAuthorization: Basic YmVybmFyZG8udmFsZTpsYjJsYjJsYjI=Content-Type: application/jsonX-Rundeck-Auth-Token: fNMPlj8pHcVJmYpTritvwCX0K4OxfQRxAccept: application/jsonCache-Control: no-cache
OUTPUT:
<result success='true' apiversion='15'>
<success>
<message>System Stats for Rundeck 2.6.2 on node rundeck</message>
</success>
<system>
<timestamp epoch='1458734317289' unit='ms'>
<datetime>2016-03-23T11:58:37Z</datetime>
</timestamp>
<rundeck>
<version>2.6.2</version>
<build>2.6.2-1</build>
<node>rundeck</node>
<base>/rundeck</base>
<apiversion>15</apiversion>
<serverUUID />
</rundeck>
....
...
...
</result>
Am I missing something?