SuperAPI AI 工具集

reddit

编程与开发

查看项目

更新于 10-16 09:50

技能介绍

用途:从 Reddit 公开 JSON API 抓取帖子、评论、子版块信息和用户资料,无需认证,适合在涉及 Reddit 内容检索时使用。

主要能力:获取子版块帖子(支持 hot、new、top、rising、controversial 排序,top 与 controversial 可配合 hour、day、week、month、year、all 时间范围);搜索帖子(可按关键词、限定子版块、指定排序与时间);查看子版块信息;按帖子 ID 获取帖子及评论;查看用户资料并附带近期帖子。

使用方式:所有命令在技能目录下运行(cd <skill_directory>)。示例: 获取热门帖子 python3 scripts/get_posts.py python --limit 20 按新排序 python3 scripts/get_posts.py python --sort new --limit 20 按周最高票 python3 scripts/get_posts.py python --sort top --time week 搜索帖子 python3 scripts/search_posts.py "AI agent" --limit 20 限定子版块搜索 python3 scripts/search_posts.py "MCP server" --subreddit ClaudeAI --limit 10 子版块信息 python3 scripts/get_subreddit.py python 按 ID 获取帖子及评论 python3 scripts/get_post.py abc123 --comments 50 用户资料 python3 scripts/get_user.py spez --posts 10

API 说明:使用公开 JSON API,无需认证;可在任意 Reddit URL 后追加 .json;速率限制约每分钟 100 次请求;文档见 https://www.reddit.com/dev/api

限制:依赖公开接口,受其速率限制与可用性影响;资料未提供错误处理、缓存或代理等细节。