Forums

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

curl - new page from template

ant werp
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!
November 21, 2022

Hi 

 

I am trying to create a new page from a user template using curl.

I am interested in creating the new page with its own title (name) and leave the rest of the template data as is.

 

How can this be done ?

 

Thank you

1 answer

0 votes
Scott Wai Chee Tan May 16, 2024
I'm guessing you would like to create a confluence page 

 

you can done it like this way:
curl -X POST \

-H "Authorization: Basic <Base64EncodedCredentials>" \

-H "Accept: application/json" \

-H "Content-Type: application/json" \

-d '{ "spaceId": "your-space-id", "status": "current", "title": "Your Page Title", "parentId": "your-parent-id", "body": { "representation": "storage", "value": "<p>This is the <strong>content</strong> of the page.</p>" } }' \

https://your-domain.atlassian.net/wiki/api/v2/pages

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events