The comments resource reads comments that people leave on your published posts and replies to them as the connected account. It needs the Team or Agency plan. Supported platforms are YouTube, Bluesky, Reddit and Mastodon.
CommentListParams also takes postId (a Socifyr post ID) and page. Your own replies are not included. supportedPlatforms lists the platforms the inbox reads.
The API answers 202 with { queued: true } (CommentSyncResult) and the sync runs in the background, so list comments again after a short wait. A sync checks up to 50 posts published in the last 30 days. It is limited to 3 calls per minute.
YouTube comment sync runs on a daily quota budget: a post is only re-read when its comment count changed, or on an age-based backoff. New YouTube comments can take a while to appear.
Comments older than 60 days are removed, and comments deleted on the platform disappear on the next full sync. Disconnecting an account or deleting a workspace deletes its stored comments.
const reply = await socifyr.comments.reply(comment.id, { text: 'Thanks! Part two is out next week.',})console.log(reply.url)
text is 1 to 5000 characters, and must fit the platform's own limit (300 graphemes on Bluesky; on Mastodon the @mention of the author counts). The reply is public as soon as it returns and cannot be edited from Socifyr. The original comment is marked done.
The plan is Free or Creator, the key's role lacks comment.reply, or a guarded key called anything other than list()
ValidationError (400)
The platform refused the reply, the reply is too long for the platform (Reply is too long for bluesky: 312 of 300 characters), the post or comment was deleted, the account is disconnected, a connection filter does not match an active account, or a parameter is invalid
NotFoundError (404)
The comment ID is not in this workspace
SocifyrError (409)
A reply to that comment is already being sent
RateLimitError (429)
Any comments call over the global limit of 60 requests per minute, more than 3 sync() calls in a minute, or the platform is rate limiting replies
The plan error message is The comments inbox is not available on your current plan. Upgrade to Team or Agency to continue. See Errors.
Comments with the TypeScript SDK
The
commentsresource reads comments that people leave on your published posts and replies to them as the connected account. It needs the Team or Agency plan. Supported platforms are YouTube, Bluesky, Reddit and Mastodon.Methods
list(params?)sync(){ queued: true }reply(id, { text })update(id, { status })statustoopenordonemarkDone(id)update(id, { status: 'done' })reopen(id)update(id, { status: 'open' })How do I list comments?
CommentListParamsalso takespostId(a Socifyr post ID) andpage. Your own replies are not included.supportedPlatformslists the platforms the inbox reads.Each result is a
Comment:idstringreply()andupdate()platformstringyoutubeconnection{ id, slug, name }slugisnullif the account was removedpost{ id, platformPostId }idis the Socifyr post IDtextstringauthor{ name, handle?, avatarUrl?, profileUrl? }urlstring | nulllikeCountnumber | null0or negativeparentIdstring | nullisOwnbooleantruefor your own repliesstatus'open' | 'done'postedAtstringrepliedAtstring | nullHow do I fetch new comments now?
Comments sync every 30 minutes. To queue a sync now:
The API answers
202with{ queued: true }(CommentSyncResult) and the sync runs in the background, so list comments again after a short wait. A sync checks up to 50 posts published in the last 30 days. It is limited to 3 calls per minute.YouTube comment sync runs on a daily quota budget: a post is only re-read when its comment count changed, or on an age-based backoff. New YouTube comments can take a while to appear.
Comments older than 60 days are removed, and comments deleted on the platform disappear on the next full sync. Disconnecting an account or deleting a workspace deletes its stored comments.
How do I reply to a comment?
textis 1 to 5000 characters, and must fit the platform's own limit (300 graphemes on Bluesky; on Mastodon the@mentionof the author counts). The reply is public as soon as it returns and cannot be edited from Socifyr. The original comment is markeddone.How do I mark a comment done?
Example: answer open questions
What errors should I handle?
PermissionError(403)comment.reply, or a guarded key called anything other thanlist()ValidationError(400)Reply is too long for bluesky: 312 of 300 characters), the post or comment was deleted, the account is disconnected, aconnectionfilter does not match an active account, or a parameter is invalidNotFoundError(404)SocifyrError(409)RateLimitError(429)sync()calls in a minute, or the platform is rate limiting repliesThe plan error message is
The comments inbox is not available on your current plan. Upgrade to Team or Agency to continue.See Errors.Next steps