Automatical page creation

Cardsmobile February 28, 2024

We use Confluence Server 7.13.1. Global administrator rights are missing, but we have administrator rights in spaces.
We have the following task: to create a page automatically from a template once a week, the page should be a child page related to another. How can we solve this problem?

1 answer

0 votes
Marc - Devoteam
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.
February 28, 2024

Hi @Cardsmobile 

Confluence server/DC don't have automation possibilities like the Cloud proposition does.

The rest API is able to create a page, see example (create-a-new-page)

But there is not an option to do this based on a template, you are basically setting in the API call.

You could script this API call on your server to be triggered on a certain time a week.

Cardsmobile February 29, 2024

Hi @Marc - Devoteam ,

Thanks for your answer.

To be more specific, there is Adaptavist Scriptrunner installed on this instance. As space admins, we do have permissions to some built-in scripts within spaces. Can this help us?

Marc - Devoteam
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.
March 1, 2024

Hi @Cardsmobile 

You could google this.

I found this for you: use-scriptrunner-to-create-a-confluence-page-server-vs-cloud , but it's just a script of creating a page.

I also came accross this option:

You'll need to use Confluence REST API to do it.

  1. Locate an example page with the template applied.
  2. Scrub that page via a REST API call using the following endpoint: GET /rest/api/content (This will allow you to get the storage format).
  3. From this, pass the storage format to your create call using this endpoint: POST /rest/api/content

While these steps are simplified, this process should allow you to create a page based off a user template.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
7.13.1
TAGS
AUG Leaders

Atlassian Community Events