Skip to content

Comments API Reference

The Comments API allows you to retrieve, create, delete, hide/unhide, and like/unlike comments on published posts. All write operations are processed asynchronously.

MethodEndpointDescription
GET/api/posts/:post_id/commentsList comments
GET/api/posts/:post_id/comments/:idGet a single comment
POST/api/posts/:post_id/commentsCreate a comment or reply
DELETE/api/posts/:post_id/comments/:idDelete a comment
POST/api/posts/:post_id/comments/:id/hideHide a comment
POST/api/posts/:post_id/comments/:id/unhideUnhide a comment
POST/api/posts/:post_id/comments/:id/likeLike a comment
POST/api/posts/:post_id/comments/:id/unlikeUnlike a comment

All endpoints require the profile_id query parameter to identify which platform profile’s comments to interact with.

Endpoints that accept a comment :id in the path (get, delete, hide, unhide, like, unlike) accept either:

  • Postproxy ID: The comment’s hashid (e.g. abc123xyz)
  • External ID: The platform’s native comment ID (e.g. 17858893269123456)

Not all platforms support all comment actions. Attempting an unsupported action returns 405 Method Not Allowed.

ActionInstagramFacebookThreadsYouTubeLinkedIn
ListYesYesComing soonComing soonComing soon
ReplyYesYesComing soonComing soonComing soon
DeleteYesYesComing soonComing soonComing soon
Hide/UnhideYesYesComing soonComing soonComing soon
Like/UnlikeNoYesComing soonComing soonComing soon

GET /api/posts/:post_id/comments

Retrieves a paginated list of top-level comments for a published post on a specific profile. Each top-level comment includes a flat replies array containing all nested replies sorted by creation date.

ParameterTypeRequiredDefaultDescription
profile_idstringYes-Profile ID
pageintegerNo0Page number (zero-indexed)
per_pageintegerNo20Number of top-level comments per page
Terminal window
curl -X GET "https://api.postproxy.dev/api/posts/POST_ID/comments?profile_id=PROFILE_ID&page=0&per_page=20" \
-H "Authorization: Bearer YOUR_API_KEY"

Response:

{
"total": 42,
"page": 0,
"per_page": 20,
"data": [
{
"id": "abc123xyz",
"external_id": "17858893269123456",
"body": "Great post!",
"status": "synced",
"author_username": "someuser",
"author_avatar_url": null,
"author_external_id": "12345",
"parent_external_id": null,
"like_count": 3,
"is_hidden": false,
"permalink": null,
"platform_data": null,
"posted_at": "2026-03-25T10:00:00.000Z",
"created_at": "2026-03-25T10:01:00.000Z",
"replies": [
{
"id": "def456abc",
"external_id": "17858893269123457",
"body": "Thanks!",
"status": "synced",
"author_username": "author",
"author_avatar_url": null,
"author_external_id": "67890",
"parent_external_id": "17858893269123456",
"like_count": 1,
"is_hidden": false,
"permalink": null,
"platform_data": null,
"posted_at": "2026-03-25T10:05:00.000Z",
"created_at": "2026-03-25T10:05:00.000Z"
}
]
}
]
}
FieldTypeDescription
totalintegerTotal number of top-level comments
pageintegerCurrent page number
per_pageintegerItems per page
dataarrayArray of top-level comment objects, each with a replies array

Pagination applies to top-level comments only. All replies (regardless of nesting depth) are flattened into the replies array of their root top-level comment, sorted by created_at ascending. Each reply retains its parent_external_id so the client can reconstruct the tree if needed.


GET /api/posts/:post_id/comments/:id

Retrieves a single comment with its direct replies.

ParameterTypeRequiredDescription
post_idstringYesPost ID
idstringYesComment ID or external ID
Terminal window
curl -X GET "https://api.postproxy.dev/api/posts/POST_ID/comments/COMMENT_ID?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY"

Response:

{
"id": "abc123xyz",
"external_id": "17858893269123456",
"body": "Great post!",
"status": "synced",
"author_username": "someuser",
"author_avatar_url": null,
"author_external_id": "12345",
"parent_external_id": null,
"like_count": 3,
"is_hidden": false,
"permalink": null,
"platform_data": null,
"posted_at": "2026-03-25T10:00:00.000Z",
"created_at": "2026-03-25T10:01:00.000Z",
"replies": [
{
"id": "def456abc",
"external_id": "17858893269123457",
"body": "Thanks!",
"status": "synced",
"author_username": "author",
"author_avatar_url": null,
"author_external_id": "67890",
"parent_external_id": "17858893269123456",
"like_count": 1,
"is_hidden": false,
"permalink": null,
"platform_data": null,
"posted_at": "2026-03-25T10:05:00.000Z",
"created_at": "2026-03-25T10:05:00.000Z"
}
]
}

POST /api/posts/:post_id/comments

Creates a new comment on a published post. The comment is stored immediately and published to the platform asynchronously.

ParameterTypeRequiredDescription
textstringYesComment text content
parent_idstringNoID of comment to reply to (Postproxy ID or external ID). Omit to comment on the post itself.
Terminal window
curl -X POST "https://api.postproxy.dev/api/posts/POST_ID/comments?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": "Thanks for the feedback everyone!"
}'

Response (201 Created):

{
"id": "ghi789def",
"external_id": null,
"body": "Thanks for the feedback everyone!",
"status": "pending",
"author_username": null,
"author_avatar_url": null,
"author_external_id": null,
"parent_external_id": null,
"like_count": 0,
"is_hidden": false,
"permalink": null,
"platform_data": null,
"posted_at": null,
"created_at": "2026-03-25T12:00:00.000Z"
}

The comment is created with status: "pending" and external_id: null. Once the async job publishes it to the platform, the status updates to "published" and external_id is populated. If publishing fails, the status becomes "failed".

Terminal window
curl -X POST "https://api.postproxy.dev/api/posts/POST_ID/comments?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": "Glad you liked it!",
"parent_id": "COMMENT_ID"
}'

Post not published (422):

{
"error": "Post is not published"
}

Unsupported platform (405):

{
"error": "Unsupported method for pinterest"
}

Parent comment not found (404):

{
"error": "Parent comment not found"
}

DELETE /api/posts/:post_id/comments/:id

Deletes a comment from the platform asynchronously.

ParameterTypeRequiredDescription
post_idstringYesPost ID
idstringYesComment ID or external ID
Terminal window
curl -X DELETE "https://api.postproxy.dev/api/posts/POST_ID/comments/COMMENT_ID?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY"

Response (200 OK):

{
"accepted": true
}

Unsupported platform (405):

{
"error": "Unsupported method for threads"
}

Comment not yet published (422):

{
"error": "Comment has not been published yet"
}

POST /api/posts/:post_id/comments/:id/hide

Hides a comment on the platform asynchronously. Hidden comments are not visible to the public.

Terminal window
curl -X POST "https://api.postproxy.dev/api/posts/POST_ID/comments/COMMENT_ID/hide?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY"

Response (200 OK):

{
"accepted": true
}

POST /api/posts/:post_id/comments/:id/unhide

Unhides a previously hidden comment on the platform asynchronously.

Terminal window
curl -X POST "https://api.postproxy.dev/api/posts/POST_ID/comments/COMMENT_ID/unhide?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY"

Response (200 OK):

{
"accepted": true
}

POST /api/posts/:post_id/comments/:id/like

Likes a comment on the platform asynchronously.

Terminal window
curl -X POST "https://api.postproxy.dev/api/posts/POST_ID/comments/COMMENT_ID/like?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY"

Response (200 OK):

{
"accepted": true
}

POST /api/posts/:post_id/comments/:id/unlike

Removes a like from a comment on the platform asynchronously.

Terminal window
curl -X POST "https://api.postproxy.dev/api/posts/POST_ID/comments/COMMENT_ID/unlike?profile_id=PROFILE_ID" \
-H "Authorization: Bearer YOUR_API_KEY"

Response (200 OK):

{
"accepted": true
}

FieldTypeDescription
idstringUnique comment identifier (ID)
external_idstring|nullPlatform’s native comment ID (null for pending comments)
bodystringComment text content
statusstringComment status: synced, pending, published, failed
author_usernamestring|nullAuthor’s display name or username
author_avatar_urlstring|nullAuthor’s profile image URL
author_external_idstring|nullAuthor’s platform-specific ID
parent_external_idstring|nullParent comment’s external ID (null for top-level comments)
like_countintegerNumber of likes on the comment
is_hiddenbooleanWhether the comment is hidden
permalinkstring|nullDirect URL to the comment on the platform (when available)
platform_dataobject|nullPlatform-specific metadata
posted_atstring|nullISO 8601 timestamp when the comment was posted on the platform
created_atstringISO 8601 timestamp of record creation
StatusDescription
syncedComment was fetched from the platform during sync
pendingComment was created via API and is being published to the platform
publishedComment was successfully published to the platform
failedComment failed to publish to the platform

Missing profile_id (400):

{
"status": 400,
"error": "Bad Request",
"message": "param is missing or the value is empty: profile_id"
}

Post not found (404):

{
"error": "Not found"
}

Comment not found (404):

{
"error": "Not found"
}

Unsupported method (405):

{
"error": "Unsupported method for {network}"
}