如何用 Claude Code 免费抓取 LinkedIn 个人主页

YouTube AI Channels 工具

摘要

一份免费的分步教程,教你用 Claude Code 搭配 Apify 的无 Cookie 抓取器,把最近 50 条 LinkedIn 帖子导出为 CSV,仅需 10¢,无需任何付费订阅。

本视频演示如何借助 Apify 用 Claude Code 抓取 LinkedIn 个人主页。该 LinkedIn 抓取器可提取帖子数据,包括点赞、评论、转发等。 🎁 获取我的免费 AI...
查看原文
查看缓存全文

缓存时间: 2026/04/22 09:07

TL;DR:用 Claude Code + Apify 的“LinkedIn Profile Post Scraper(无 Cookie)”导出最近 50 条帖子——点赞、评论、转发和自定义互动得分——仅需 0.1 美元,无需订阅。 ## 为什么不能直接让 Claude 爬 LinkedIn 在 Claude、ChatGPT 或 Gemini 的网页版里输入“请爬一下我的 LinkedIn 帖子”,会得到礼貌拒绝: “LinkedIn 禁止自动化抓取,且访问个人资料和帖子需登录。” 绕过办法:走 Apify。这是一个外部 Actor 市场,已有合规的 LinkedIn、Instagram、Google Maps、TikTok、Amazon、Facebook 等爬虫。 ## 设置 Apify(免费层) 1. 免费注册 Apify 账户(链接见视频说明)。 2. 左侧栏打开 **设置 → API 与集成**,复制个人 **API 令牌**。 3. 在 VS Code(已装 Claude Code 扩展)运行: `` save my Apify API key in my APIs .env file `` 出现提示时粘贴令牌。存进 `.env` 可避免出现在聊天记录里。 ## 选对 Actor 在 Apify 商店搜“LinkedIn Profile Post Scraper”。 选 **Harvest API 的“LinkedIn Profile Post Scraper(无 Cookie)”**,因为: - 只需 **每 1,000 条帖子 2 美元** - **无需付费 Apify 订阅** 免费账户每月送 5 美元额度,足够跑多次。 ## 加载 Claude Code 技能 1. 从作者的免费《AI 营销入门指南》(https://example.com,链接见描述)下载 **“LinkedIn Profile Scraper”** 的 Markdown 文件。 2. 在 Claude Code 点 **Upload Skill**,选中该文件。 该技能封装 Apify 调用,等待完成并返回整洁的 CSV。 ## 运行爬虫 在 Claude Code 输入: `` use my LinkedIn profile scraper skill scrape my LinkedIn posts (Ryan Dozer profile) last 50 posts only export CSV with: publish date, URL, post type, likes, comments, shares calculate an “engagement score” and analyze why high-score posts perform well `` 模型:**Claude 3 Opus 4.6** 勾选 **“ask before edits”**,点 **Go**。 Claude Code: - 调用 Apify Actor - 监控运行 - 下载数据集 - 计算互动得分(示例公式:点赞 + 3×评论 + 5×转发) - 在项目文件夹生成 `linkedin_posts.csv` ## 查看并分析数据 VS Code 的表格视图太挤,建议: 1. 把 `linkedin_posts.csv` 拖到桌面。 2. 上传到 Google Drive,用 Google 表格打开。 示例行(节选): | publishDate | url | postType | likes | comments | shares | engagementScore | |-------------|-----|----------|-------|----------|--------|-----------------| | 2024-08-10 | ... | personal | 312 | 42 | 18 | 10 / 10 | | 2024-07-25 | ... | how-to | 89 | 7 | 3 | 5.2 / 10 | **洞察:** 10/10 分的帖子宣布作者第一个孩子即将出生——再次证明个人故事碾压干货。 ## 费用核对 Apify 后台显示 50 条帖子消耗 **0.10 美元**。 按此费率: - 500 条帖子只要 **1 美元** - 每月免费额度可跑 30+ 次 ## 如果 Actor 下架 定价和可用性会变。Claude Code 可自动搜索 Apify 商店里的其他免费 Actor 并更新技能——无需手动改代码。 ## 下一步 - 按帖子类型筛选,看哪种格式转发最多。 - 做数据透视表,对比月度互动趋势。 - 把高分帖子文案喂给 Claude,生成内容模板。 **来源:** How to Scrape LinkedIn Profiles With Claude Code (Free)(https://www.youtube.com/watch?v=iUsYPRwAK8g)

相似文章