I am generating/updating a confluence page using rest api. Below (groovy) is the json which is passed as request body. Note that the value content is basically a string which is read from a file containing markdown content. The problem is that the page is not rendering according to markdown standards (rendering is off).
Is there any recommendation to read file content (which are markdown content) in a certain way that rendering does not go bad ?
JsonBuilder builder = new JsonBuilder();
builder {
version {
number versionNumber
}
title 'Tools Information'
type 'page'
space {
key 'engineering'
}
body {
storage {
representation 'wiki'
value content
}
}
}