Get comments from a post
Retrieve comments from a LinkedIn post with pagination support. Useful for analyzing engagement, finding leads who commented, or monitoring discussions. Returns comment content, author info, timestamps, and like counts.
/posts/commentsGet comments from a post
Retrieve comments from a LinkedIn post with pagination support. Useful for analyzing engagement, finding leads who commented, or monitoring discussions. Returns comment content, author info, timestamps, and like counts.
Code Examples
curl -X POST 'https://api.connectsafely.ai/linkedin/posts/comments' \ -H 'Authorization: Bearer <your_api_key>' \ -H 'Content-Type: application/json' \ -d '{"postUrl":"https://linkedin.com/posts/example-post"}'Parameters
No parameters.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
accountId | string | No | LinkedIn account ID to use. If not provided, uses the default account. |
postUrl | string | Yes | Full URL of the LinkedIn post to get comments from |
commentCount | number | No | Number of comments per page (enables pagination mode) |
start | number | No | Pagination offset (0-indexed) |
paginationToken | string | No | Token from previous response to fetch next page |
maxComments | number | No | Maximum total comments to retrieve |
batchSize | number | No | Internal batch size for fetching |
Example
{
"postUrl": "https://linkedin.com/posts/example-post"
}Responses
| Status | Description |
|---|---|
| 200 | Comments retrieved successfully |
Repost a LinkedIn post
Repost/share a LinkedIn post to your feed. This creates an instant repost without additional commentary. Requires either a post URL (will be scraped for URNs) or the share/ugcPost URN directly. The activityUrn is optional but helps with engagement tracking.
Get all comments from a post
Fetch all comments from a LinkedIn post in a single request. Automatically handles pagination internally. Ideal for bulk analysis of post engagement. Use for posts with many comments where you need complete data.
