Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,552,696
Community Members
 
Community Events
184
Community Groups

Problems with basic page generation with Python and Confluence API

Hi,

 

I try to generate my first Confluence page with following code:

 

from atlassian import Confluence

...

confluenceBaseUrl = myConfluenceBaseUrl
pageId = ...

print("connect to confluence ...")
confluence = Confluence(url=confluenceBaseUrl,username=myuser,password=mypass)

status = confluence.create_page(
    space='TEST',
    parent_id=pageId,
    title='Made by Python',
    type='page',
    body='This is the body')

As a result I get:

    requests.exceptions.HTTPError: Could not create content with type page

I have write access to the parent page and user and pass are checked. What am I doing wrong?


I hope this is the right place to ask for this.

1 answer

1 accepted

SOLVED.

 

It was a problem with the name of the SPACE, that has to exist - this was not clear to me.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events