Install
openclaw skills install 07ClawHub Security found sensitive or high-impact capabilities. Review the scan results before using.
为AI Agent提供完整的互联网访问能力,支持多个主流平台
openclaw skills install 07为AI Agent提供完整的互联网访问能力,支持Twitter、YouTube、Reddit、小红书等平台。
提供多个主流互联网平台的数据访问能力,包括Twitter、YouTube、Reddit、小红书、B站等。使用开源工具,零API费用,支持Cookie加密存储和安全审计。
位于 channels/ 目录:
twitter.py:Twitter访问模块youtube.py:YouTube访问模块reddit.py:Reddit访问模块xiaohongshu.py:小红书访问模块bilibili.py:B站访问模块web.py:网页搜索模块部分平台需要Cookie:
cd 07-互联网访问
bash install.sh
Twitter:
# 导出Cookie
python cookie_extract.py twitter
# 或手动设置
export TWITTER_COOKIE="your_cookie_here"
YouTube:
# 安装yt-dlp
pip install yt-dlp
# 可选:配置代理
export YOUTUBE_PROXY="socks5://127.0.0.1:1080"
小红书:
# 导出Cookie
python cookie_extract.py xiaohongshu
Reddit:无需配置,直接使用
B站:无需配置,直接使用
# 加密Cookie
python security/encrypt_cookies.py import --file cookies.json
# 使用时解密
python security/encrypt_cookies.py decrypt
用户:"搜索Twitter上的AI新闻"
AI:
from channels.twitter import TwitterChannel
twitter = TwitterChannel()
tweets = twitter.search("AI news", limit=10)
# 返回:推文列表,包含内容、作者、时间等
用户:"获取这个YouTube视频的字幕" 链接:https://youtube.com/watch?v=xxx
AI:
from channels.youtube import YouTubeChannel
youtube = YouTubeChannel()
subtitles = youtube.get_subtitles("video_id")
# 返回:视频字幕文本
用户:"Reddit上关于Python的讨论"
AI:
from channels.reddit import RedditChannel
reddit = RedditChannel()
posts = reddit.search("Python", subreddit="learnprogramming", limit=20)
# 返回:帖子列表,包含标题、内容、评论等
用户:"小红书上有哪些穿搭推荐"
AI:
from channels.xiaohongshu import XiaohongshuChannel
xhs = XiaohongshuChannel()
notes = xhs.search("穿搭", limit=10)
# 返回:笔记列表,包含内容、图片、点赞等
用户:"搜索最新的AI新闻"
AI:
from channels.web import WebChannel
web = WebChannel()
results = web.search("最新AI新闻")
# 返回:搜索结果,包含标题、链接、摘要
# 加密Cookie
python security/encrypt_cookies.py import --file cookies.json --password "your-password"
# 轮换密钥(建议每月)
python security/encrypt_cookies.py rotate
# 生成安全报告
python security/audit_monitor.py report --days 7
# 实时监控
python security/audit_monitor.py monitor
# 完整检查
python security/dependency_check.py full
# 建立基线
python security/dependency_check.py baseline
| 平台 | 功能 | Cookie | 备注 |
|---|---|---|---|
| 推文搜索、用户信息 | ✅ 需要 | 免费API有频率限制 | |
| YouTube | 字幕、评论、元数据 | ❌ 不需要 | 可选代理 |
| 帖子搜索、评论 | ❌ 不需要 | 公开API | |
| 小红书 | 笔记搜索、用户信息 | ✅ 需要 | 需要登录 |
| B站 | 视频信息、弹幕 | ❌ 不需要 | 公开API |
| 网页搜索 | 搜索引擎集成 | ❌ 不需要 | DuckDuckGo等 |
现象:提示认证失败
解决:
# Cookie可能过期,重新导出
python cookie_extract.py twitter
现象:连接超时
解决:
# 配置代理
export YOUTUBE_PROXY="socks5://127.0.0.1:1080"
现象:pip install报错
解决:
# 运行依赖检查
python security/dependency_check.py full
现象:无法解密Cookie
解决:
# 删除密钥重新导入
rm ~/.config/agent-reach/.key
python security/encrypt_cookies.py import --file cookies.json