Hello,
i have the following code, which works perfectly in a /etc/init.d/ script:
curl -u USER:PASSWORD -X PUT -H 'Content-Type: application/json' -d '{"id":"1234567","type":"page","title":"mytitle","space":{"key":"example"},"body":{"storage":{"value":"<p>Someone just restarted Service on '$hostname': '$NOW'</p>","representation":"storage"}},"version":{"number":'$VERSION'}}' "https://mydomain.com/rest/api/content/1234567" After the script gets executed the confluence page updates the page correctly:
someone just restarted Service on XYZ: 2018-11-29_09:22:50
but if i run the script again it gets overwritten. I dont want to update the old content i want to post it as new line for example:
someone just restarted Service on XYZ: 2018-11-29_09:22:50
someone just restarted Service on XYZ: 2018-11-29_09:24:33
just to gather all restarts
i tried to work with '\n' but i dont seem to work
https://docs.atlassian.com/ConfluenceServer/rest/6.12.2/#content-update
Regards