Are you in the loop? Keep up with the latest by making sure you're subscribed to Community Announcements. Just click Watch and select Articles.

×
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

How to get footer comment details using Rest Api

Currently we 'https://api.atlassian.com/ex/confluence/{my_clouid_id}/wiki/api/v2/footer-comments/{comment-id}' use this API for footer comments details. After running this api we get
{
"id": "xxxxx",
"status": "current",
"title": "Re: <page name>",
"pageId": "xxxxxxx",
"version": {
"number": 1,
"message": "",
"minorEdit": false,
"authorId": "xxxxxxxxxxx",
"createdAt": "2023-10-03T06:34:30.003Z"
},
"_links": {
"webui": "/spaces/{my_space_key}/pages/{my_page_id}/{page_name}?focusedCommentId={comment_id}"
}
}
this response, but confluence documentation say that response should be {
"results": [
{
"id": "",
"status": "current",
"title": "",
"pageId": "",
"version": {
"createdAt": "",
"message": "",
"number": 19,
"minorEdit": true,
"authorId": ""
},
"body": {
"storage": {},
"atlas_doc_format": {}
},
"_links": {
"webui": ""
}
}
],
"_links": {
"next": ""
}
}
So, can you help to get the correct answer for the footer comment details using Rest api.

https://developer.atlassian.com/cloud/confluence/rest/v2/api-group-comment/#api-footer-comments-comment-id-get this confluence documentation we follow.

1 answer

1 accepted

0 votes
Answer accepted
Andrii Maliuta
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.
Oct 05, 2023

Hello @Sagnik Mukhopadhyay ,

To get the ARRAY  of comments (footer comments) for a page you use:

/pages/{id}/footer-comments

then the response contains the object with results element.

To get the data about ONE exact comment you use:

/footer-comments/{comment-id}

 Then you get one comment object with necessary data.

@Andrii Maliuta Yes, we follow this way and we get a response but we couldn't see
"body": { "storage": { "representation": "<string>", "value": "<string>" }, "atlas_doc_format": { "representation": "<string>", "value": "<string>" }, "view": { "representation": "<string>", "value": "<string>" } }, this part,
In our API response, we are missing this body part.

Andrii Maliuta
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.
Oct 05, 2023 • edited

@Sagnik Mukhopadhyay ,

To get the body, you should add the 'body-format' query parameter:

ex:

/api/v2/pages/1234567/footer-comments?body-format=storage

/api/v2/footer-comments/11223344?body-format=storage

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events