Forums

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

xml definition for Page Properties macro

Miroslav Csonka
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!
June 20, 2019

Hey,

 

I'm trying to create a page with an HTTP api and I would like this page to include a few macros. But I can't find any documentation on how to do so with XML.

 

I've found documentation for the UI

 

Something like this (which is for Jira issue key)

<ac:structured-macro ac:name='jira'>
<ac:parameter ac:name='key'>#{issue_key}</ac:parameter>
</ac:structured-macro>

 

But for page properties.

 

I know how to create tables, but I reckon they need to be wrapped in something.

1 answer

1 accepted

1 vote
Answer accepted
Bill Bailey
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 22, 2019

The easiest thing to do is to create a page with some example macros with the settings you want, then you can view storage to see how the XHTML is formatted.

There is also a source editor (which is what I use_) to see the storage format. A useful tool for fixing pages.

Miroslav Csonka
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!
June 24, 2019

Thanks, Bill!

 

For anyone reading this, this is the API I've used:

GET /wiki/rest/api/content/:id?expand=body.storage

 

And under key `body.storage.value` you'll find an XML describing the page.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events