List the comments on a proposal that are visible to the panelist. Requires the canComment capability, which is only granted by the community_forum access level (see Get Idea Bank). The response is paginated with an encrypted cursor.
GET /public/ideabank/proposals/{proposalId}/comments
Path Parameters
Parameter
Type
Description
proposalId
string
The proposal identifier from the proposal listing
Headers
Header
Required
Description
Authorization
Yes
Compound idea-bank token from Tenant API
Query Parameters
Parameter
Required
Description
sort
No
Sort order for comments
limit
No
Page size
cursor
No
Encrypted cursor from a previous response; omit for the first page
Response
{"items":[{"commentId":"c-abc123","text":"Great idea, I would use this daily.","authorType":"panelist","tsCreated":1700000000},{"commentId":"c-def456","text":"Thanks for the suggestion, we are reviewing it.","authorType":"admin","tsCreated":1700001000}],"cursor":"encrypted-cursor-token"}
Response Fields
Field
Type
Description
items
array
List of comment objects
cursor
string
(Optional) Encrypted cursor for the next page. Absent on last page.
Comment Object
Field
Type
Description
commentId
string
Unique comment identifier
text
string
The comment text (HTML stripped)
authorType
string
Who wrote the comment: own, panelist, or admin
tsCreated
integer
Unix timestamp (seconds) when the comment was posted
The authorType field is computed relative to the requesting panelist:
authorType
Meaning
own
The requesting panelist wrote this comment
panelist
Another panelist wrote this comment
admin
A researcher (idea bank owner) wrote this comment
Comments are filtered for visibility: panelists see all comments marked visible, plus their own comments regardless of moderation status. A panelist never sees another panelist’s hidden comment.
Pagination
Pages are traversed with an opaque, encrypted cursor. Because hidden comments are filtered out server-side, a page may contain fewer items than limit; keep following the cursor until the response omits it.
Examples
cURL
curl -X GET \"https://api.votito.com/public/ideabank/proposals/p-abc123/comments"\-H"Authorization: abc123:xyz789:ses456"
JavaScript
constlistComments=async (publicKey,proposalId,{sort,limit,cursor}={})=>{consturl=newURL(`https://api.votito.com/public/ideabank/proposals/${proposalId}/comments`);if (sort){url.searchParams.set('sort',sort);}if (limit){url.searchParams.set('limit',String(limit));}if (cursor){url.searchParams.set('cursor',cursor);}constresponse=awaitfetch(url,{headers:{'Authorization':publicKey}});if (!response.ok){thrownewError(`Failed to list comments: ${response.status}`);}returnresponse.json();};// Usageconstpage=awaitlistComments(publicKey,'p-abc123');page.items.forEach((c)=>console.log(`[${c.authorType}] ${c.text}`));