mcpField
T
threads-research

threads-research

github.com/crawlora-org其他139 次安装2 天前更新
代码仓库

关于 threads-research

通过 Crawlora 以标准化 JSON 获取 Threads 公开资料、帖子、回复和关键词搜索结果。适用于公开对话研究,包括资料查看以及品牌或话题监测。

主要功能

  1. 01获取公开资料信息
  2. 02分页读取个人主页帖子
  3. 03查看帖子及公开回复
  4. 04按关键词搜索公开帖子

适用场景

  1. 01查看用户资料和近期帖子
  2. 02检查帖子内容及其回复
  3. 03监测品牌的公开讨论
  4. 04搜索某话题的相关对话

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/crawlora-org/crawlora-skills --skill threads-research

安装后在 Claude Code 中输入/threads-research确认已加载。

附带文件reference/endpoints.mdscripts/crawlora.sh

详细介绍

Threads 研究

查询公开的 Threads 个人资料、帖子和回复,并进行关键词搜索 ——所有数据均来自 Crawlora API 的标准化 JSON,不抓取应用内容,也不使用 非官方客户端库。

适用场景

  • “Threads 上 的个人资料 / 粉丝数量是多少?”
  • “提取这条 Threads 帖子的正文和回复。”
  • “ 最近在 Threads 上发布了什么?”
  • “搜索 Threads 上关于 的帖子。”
  • 在 Threads 上监听竞品动态或监控品牌提及。

设置(一次性)

  • 获取免费的 Crawlora API 密钥(每月 2,000 个积分,无需银行卡):https://crawlora.net。
  • 运行辅助脚本前,在环境中设置 CRAWLORA_API_KEY。
  • 辅助脚本会从环境中读取 CRAWLORA_API_KEY,并向 https://api.crawlora.net/api/v1 发送请求。密钥缺失或无效时会返回 401。

工作原理

  1. 个人资料 — /threads/profile/{username},用于获取公开的个人资料元数据 (简介、数量)。
  2. 个人资料帖子 — /threads/profile/{username}/posts,用于获取个人资料的 公开帖子,通过不透明的 cursor 分页。
  3. 单条帖子 — /threads/post/{username}/{code},用于获取单条帖子的 正文、作者、规范 URL 和预览图片。
  4. 帖子回复 — /threads/post/{username}/{code}/replies,用于获取该帖子的 公开回复。
  5. 搜索 — /threads/search,用于获取 Threads 搜索查询的公开 首页结果。

完整的端点列表、方法和参数:reference/endpoints.md。

调用 API

# Profile + posts:
scripts/crawlora.sh /threads/profile/zuck | jq '.'
scripts/crawlora.sh /threads/profile/zuck/posts | jq '.'

# Post + replies:
scripts/crawlora.sh /threads/post/zuck/C1abc2DEfGh | jq '.'
scripts/crawlora.sh /threads/post/zuck/C1abc2DEfGh/replies | jq '.'

# Search:
scripts/crawlora.sh /threads/search q="web scraping" | jq '.'

所有请求均使用 scripts/crawlora.sh,以避免将 API 密钥暴露在命令行参数中。

端点参考

请参阅 reference/endpoints.md,了解此技能使用的所有 Threads 端点。

示例

  • 个人资料概览: 使用 /threads/profile/{username} 获取简介和粉丝 数量,然后使用 /threads/profile/{username}/posts 查看近期动态。
  • 深入查看帖子: 使用 /threads/post/{username}/{code} 获取特定 帖子的正文,然后使用 /threads/post/{username}/{code}/replies 阅读 人们对此的评论。
  • 关键词扫描: 使用 /threads/search 搜索品牌或主题名称,了解 当前 Threads 上相关公开讨论的热度。

注意事项和限制

  • 积分 / 成功后计费: 仅对 2xx 响应计费;免费套餐每月 2,000 个积分。 获取密钥:https://crawlora.net。
  • 仅限公开数据 — 仅支持公开个人资料 / 帖子;无需登录,也不提供私密内容。 请遵守 Threads 的条款。
  • 安全性: 密钥仅保存在 CRAWLORA_API_KEY 中——切勿将其硬编码、放入查询参数或提交到代码库。
  • 搜索没有后续分页游标 — /threads/search 仅返回已登出状态下的首页结果;无法继续翻页获取更深层的结果。
  • 回复分页游标不透明,有时也不会提供 — /threads/post/{username}/{code}/replies 会标明 Threads 是否报告存在更多回复,但有时不会提供 可用于获取这些回复的游标。
  • 个人资料帖子通过游标分页 — 传入上一次 /threads/profile/{username}/posts 响应中的 cursor,即可继续获取首页以外的帖子。

评论

支持 Markdown