Forums

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

Is there a way to get the Server Information of Confluence with REST API

Fabian Duft July 6, 2021

Hi,

I am looking for a way to get basic server information like the baseUrl from Confluence with the help of the REST API.
Jira provides this information via: GET /rest/api/2/serverInfo

I could not find a way to do this with the REST API. Does it even exist?

Best regards
Fabian

1 answer

1 accepted

0 votes
Answer accepted
Fabian Duft July 6, 2021

I have found a workaround for all those who are interested in this:

One can use /rest/api/user/current to get information about the current user. With this a JSON in the following format will be reutrned:

{ "type": "known", "username": "jsmith", "userKey": "402880824ff933a4014ff9345d7c0002", "profilePicture": { "path": "/wiki/relative/avatar.png", "width": 48, "height": 48, "isDefault": true }, "displayName": "Joe Smith", "_links": { "base": "http://myhost:8080/confluence", "context": "/confluence", "self": "http://myhost:8080/confluence/rest/experimental/user?key=402880824ff933a4014ff9345d7c0002" }, "_expandable": { "status": "" } }

With this you can access _links and then base. Base will then represent your base URL. 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events