Create a new comment
Creates a new comment or reply to an existing comment.
You can create a comment for a post or changelog. Comments support:
- HTML content (images are automatically uploaded to our storage)
- Threading (replies via
parentCommentId) - Privacy controls (private comments visible only to admins)
- Author attribution (post on behalf of users)
Required Fields
content- Comment content in HTML formatpostIdORchangelogId- One is required to specify the target
Optional Fields
parentCommentId- Create a reply to an existing commentisPrivate- Make comment visible only to admins (default: false)sendNotification- Notify voters about the comment (default: true)author- Post comment under a specific user (uses authenticated user if not provided)createdAt- Backdate creation (useful for imports)
Author Object
The author field supports multiple identification methods:
id- Featurebase user ID (direct reference)userId- External user ID from your system (via SSO)email- Email address (finds existing or creates new user)name- Display name (used with email for new users)profilePicture- Profile picture URL
If no author is provided, the comment is posted under the authenticated user.
Content Format
Content should be formatted as HTML. For images:
- External URLs in
img srcattributes are automatically pulled into our storage - Base64 encoded data URIs (
data:image/...) are also supported and processed
Response
Returns the created comment object with all fields populated, including:
id- Unique comment identifierauthor- Author information- Voting stats and timestamps
Errors
400- Invalid input (missing required fields, invalid IDs)403- Commenting disabled or not authorized404- Post/changelog not found or parent comment not found
Body
Author to attribute the post to. If not provided, uses the authenticated user — unless source is given, in which case a guest author is synthesised from source.label (or the channel name), because a relayed request belongs to the customer who said it. Supports multiple identification methods: id (Featurebase ID), userId (external SSO ID), or email.
Changelog ID to comment on (accepts ObjectId or slug)
507f1f77bcf86cd799439012Comment content in HTML format
2<p>This is a great idea!</p>Set the date when the comment was created. Useful for importing comments from other platforms.
2025-01-15T10:30:00.000ZInitial downvotes count. Useful for importing comments from other platforms. Score will be calculated as upvotes - downvotes.
0 <= x0Whether the comment is private (only visible to admins)
falseWhether to notify voters of the submission about the comment
trueResponse
Created
Changelog ID this comment belongs to
507f1f77bcf86cd799439013Parent comment ID for replies, null for root comments
507f1f77bcf86cd799439014More in Comments
PATCHUpdate a commentDELDelete a commentPOSTSearch commentsStill need help? Ask the team