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: 
  • Community
  • Q&A
  • Jira
  • Questions
  • how can I create a page based on any specific template on confluence automatically using script runner ?

how can I create a page based on any specific template on confluence automatically using script runner ?

Nagmani Nagmani
Contributor
February 6, 2012

I can create blank pages on confluence automatically but I want to add one extra feature and that is creation of pages based on specific template (that we are creating in confluence while creating the space). Do we have any such parameters in REMOTE PAGE CLASS.

def page = new RemotePage (
content:" ",
creator: "admin",
title:issue.getCustomFieldValue(cf),
space: "MicrosoftDescriptive",
homePage: false,
created: Calendar.getInstance(),
modifier: "admin",
version: 1,
modified: Calendar.getInstance(),
)

Where can I add the template? If its possible?

2 answers

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
JamieA
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 Champions.
May 16, 2013

There is a setContent(String) method - have you tried that?

In fact I can see content:"" in the hash you are passing - just add some content to that string.

0 votes
hirok
May 16, 2013

I also have the same problem using soap api. Is there any solution on this?

Any advice would be appreciated.

Thanks,
hiro