Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
badges earned

Your Points Tracker
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Accessing Confluence Server with API

I am new to Confluence and just joined my company for few months. My company hosts Confluence and JIRA in the local server with Google G-suit account oAuth. In that case, how I can access the company confluence through REST api? 

I tried the following command, but shows connection refused

```curl -u admin:admin -X GET "http://localhost:8080/confluence/rest/api/content?type=blogpost&start=0 &limit=10&expand=space,history,body.view,metadata.labels" | python -mjson.tool```


I guess I need to replace the admin:admin with my username and password. My company Confluence uses G-suit account oAuth, so I need to replace the admin:admin with my G-suit account username and password?

1 answer

1 accepted

0 votes
Answer accepted

Yes, you have to use a username and password that has access to Confluence. Also, you need to make sure the domain is correct and you shouldn't need the port. So, if your companies url to Confluence is then that is all you need then add the "/rest/api..." so , it would be something like this:

curl -u <username>:<passowrd>-X GET " &limit=10&expand=space,history,body.view,metadata.labels" | python -mjson.tool


Good Reference material for Confluence Server 7.0.3, change the link to whatever version of Confluence your company is running:

It works. Thank you Stephen for your help. I still have one question about the authentication. Is it possible to authenticate the get request with the google oauth since my company use google G-suit account to authenticate?

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Jira Service Management

JSM June Challenge #2: Share how your business teams became ITSM rockstars

For JSM June Challenge #2, share how your non-technical teams like HR, legal, marketing, finance, and beyond started using Jira Service Management! Tell us: Did they ask to start using it or...

327 views 9 7
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you