{
  "openapi": "3.0.1",
  "info": {
    "title": "LinkedIn Post Comments Scraper & Post Reactors",
    "description": "💬 Scrape LinkedIn post comments & replies in bulk. 👍 Get likes, reactions, author names & profile links. 📅 Filter by date. 🔗 Add multiple posts at once. No login required by default.",
    "version": "0.1",
    "x-build-id": "1yiyhcbKcRhmD9qeo"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapier~linkedin-post-comments-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapier-linkedin-post-comments-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/scrapier~linkedin-post-comments-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapier-linkedin-post-comments-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/scrapier~linkedin-post-comments-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapier-linkedin-post-comments-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "startUrls": {
            "title": "🔗 Post URLs or IDs",
            "type": "array",
            "description": "LinkedIn post URLs, activity/ugcPost URNs, or bare numeric post IDs. Each post is captured separately. Example: https://www.linkedin.com/feed/update/urn:li:activity:7289521182721093633/",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "resultLimitPerPost": {
            "title": "💬 Max Comments Per Post",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Caps TOP-LEVEL comments only. Reactors are counted separately and never eat this budget. Default is 10, maximum 500.",
            "default": 10
          },
          "commentEngine": {
            "title": "⚙️ Comment Engine",
            "enum": [
              "auto",
              "public",
              "voyager"
            ],
            "type": "string",
            "description": "Auto starts on the public page (no cookie) and escalates to the logged-in API when you supply a cookie. Public page alone tops out at roughly 10 comments per post — full coverage on a viral post needs the cookie.",
            "default": "auto"
          },
          "scrapeReactors": {
            "title": "👍 Also Capture Post Reactors",
            "type": "boolean",
            "description": "Collect the people who reacted to the post as their own rows (name, headline, profile URL, avatar, reaction type). REQUIRES the li_at cookie below — LinkedIn shows the reactor list to logged-in members only. Reactor rows are never charged.",
            "default": false
          },
          "maxReactorsPerPost": {
            "title": "🔢 Max Reactors Per Post",
            "minimum": 1,
            "maximum": 2000,
            "type": "integer",
            "description": "How many reactor records to collect per post. These are ADDITIONAL to the comment limit above. Default is 50.",
            "default": 50
          },
          "reactionTypeFilter": {
            "title": "🎭 Reaction Type",
            "enum": [
              "ALL",
              "LIKE",
              "PRAISE",
              "EMPATHY",
              "APPRECIATION",
              "INTEREST",
              "ENTERTAINMENT"
            ],
            "type": "string",
            "description": "Keep only one kind of reaction, or all of them. 'Celebrate' is PRAISE, 'Support' is EMPATHY, 'Love' is APPRECIATION, 'Insightful' is INTEREST, 'Funny' is ENTERTAINMENT.",
            "default": "ALL"
          },
          "liAtCookie": {
            "title": "🍪 LinkedIn li_at Cookie (stored as a secret)",
            "type": "string",
            "description": "Unlocks the reactor list and full comment coverage. Get it from your browser: DevTools → Application → Cookies → linkedin.com → li_at. Leave empty to run comments-only with no login. Used only for the logged-in requests — the public comment path never sends it."
          },
          "liAt": {
            "title": "🍪 li_at Cookie (plain-text field)",
            "type": "string",
            "description": "Same cookie, kept for runs and integrations that already pass 'liAt'. If both fields are filled, this one wins. Prefer the secret field above.",
            "default": ""
          },
          "scrapeReplies": {
            "title": "↩️ Include Reply Threads",
            "type": "boolean",
            "description": "Adds replies under each comment. Replies arrive BOTH nested on the parent row and as their own flat rows carrying parentCommentId, isReply and threadDepth, so a thread rebuilds in a spreadsheet. Reply rows are not charged. Requires a cookie.",
            "default": false
          },
          "profileScraperMode": {
            "title": "👤 Commenter Detail Level",
            "enum": [
              "short",
              "full"
            ],
            "type": "string",
            "description": "Full adds each commenter's headline and profile picture where LinkedIn exposes them.",
            "default": "short"
          },
          "postedLimit": {
            "title": "📅 Comment Age Filter",
            "enum": [
              "any",
              "24h",
              "week",
              "month",
              "3months",
              "6months",
              "year"
            ],
            "type": "string",
            "description": "Keep only comments posted within this window. Dates are exact UTC timestamps, so this filter is precise.",
            "default": "any"
          },
          "proxyConfiguration": {
            "title": "🌐 Proxy",
            "type": "object",
            "description": "Optional. LinkedIn throttles bursts with HTTP 999; a residential proxy reduces that. The actor escalates automatically when a request is throttled."
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}