Lemmy Comment API
One comment with its post and community, including a removed or deleted row and its flags.
GET /v1/lemmy/comment1 credit Failed requests are free
About this endpoint
GET /v1/lemmy/comment?instance=lemmy.ml&id=1000 returns data.comment with id, content, postId, path, depth, parentId, distinguished, languageId, isLocal, removed, deleted, publishedAt, updatedAt, score, upvotes, downvotes, replyCount, isAdmin, isModerator, bannedFromCommunity, and the post, community and author objects.
The id belongs to the instance you name. A missing id returns lookupStatus: not_found. A removed or deleted comment is still served when the instance keeps it, with empty content and removed or deleted set; the public moderation log can hold the removed text.
Lemmy Comment API FAQ
Why is a removed comment still returned?
The instance keeps the row and clears its content, so you get the id, author, score, post and the removed or deleted flag. The moderation log may have the removed text.
Does the id work on another instance?
Not reliably. A comment id is local to the instance that issued it. Ask the same instance, or resolve the comment through the post that holds it.
How many credits does a comment lookup cost?
Pricing is documented on the operation in the API registry (shown on this page). Confirm on every response with meta.creditsCharged: that field is the billing source of truth.