The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

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

Get page object within macro

Björn Sauter
January 17, 2020

Hey,

 

I just started developing confluence plugins. One thing I am trying for practice purposes, is displaying all labels of the page the macro is running on in a table. In order to get the labels of a page I need the page object of the page. This is where I am stuck at the moment.

I figured out how to display content on a page with a macro, however I am not able to retrieve any information about the page, the macro is running on. 

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
Answer accepted
Sven Schatter _Lively Apps_
Atlassian Partner
January 17, 2020

Hi Björn,

the page is part of the ConversionContext:

public String execute(Map<String, String> parameters, String body, ConversionContext context) {
ContentEntityObject page = context.getEntity();
}

However, for app development related questions you should probably check out the Developer Community instead. ;)

Best regards,
Sven

Björn Sauter
January 20, 2020

Hi Sven,

 

thanks for the answer. I'll post my question in the Developer Community next time. I'm still new to the Atlassian world :).

 

Greetings, Björn

TAGS
AUG Leaders

Atlassian Community Events