Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

'Error loading the extension!' with a page which has HTML macro created using confluence REST API

Pradeep Ragav
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 8, 2022

Screenshot from 2022-08-08 20-02-24.png

Trying to create an HTML page using Confluence REST API 

curl -X POST \
https://whatfix.atlassian.net/wiki/rest/api/content \
-H 'Content-Type: application/json' \
-H 'cache-control: no-cache' \
-d '{
"type": "page",
"title": "My Test Page 15",
"version":{{"number":"1" }},
"body": {
"storage": {
"value": "<ac:structured-macro ac:name=\"html\" ac:schema-version=\"1\" ac:macro-id=\"74c5d460-d9c1-4259-9489-5ca2cea8314c\"><ac:plain-text-body><![CDATA[<div><ul><li><a href=\"#Domain1\">Domain1</a></li><li><a href=\"#Domain2\">Domain2</a></li><li><a href=\"#Domain3\">Domain3</a></li><li><a href=\"#Domain4\">Domain4</a></li><li><a href=\"#Domain5\">Domain5</a></li></ul></div><br/><div><table> <colgroup><col/><col/></colgroup><tr><th>Domain</th><th>System Count</th></tr><tr><td>Domain1</td><td>653</td></tr><tr><td>Domain2</td><td>2</td></tr><tr><td>Domain3</td><td>527</td></tr><tr><td>Domain4</td><td>2</td></tr><tr><td>Domain5</td><td>2</td></tr></table></div><br/>]]></ac:plain-text-body></ac:structured-macro>",
"representation": "storage"
}
}
}'

The error from dev console is 
Screenshot from 2022-08-08 20-09-12.png

I could insert an html manually by using HTML Macro but not through the REST API.

Thanks in advance

1 answer

0 votes
Tyler Thrailkill
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
April 28, 2023

I'm seeing the same thing. Did you ever find a solution?

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events