Token导航 LogoToken导航TokenDH.com
效率操作浏览器clawhub未标认证来源可访问clear审计通过

x-twitter-browserx 推特浏览器

Agent Skill

x-twitter-browser 用于处理浏览器自动化、网页检查和页面信息提取,适合在 OpenClaw 中需要让 Agent 打开页面、读取网页或验证前端流程时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

15,644

周安装

672

GitHub Stars

1

下载量

5,484
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:x-twitter-browser(x 推特浏览器)
来源仓库:https://github.com/zhanghanjun2/x-twitter-browser
安装命令:
openclaw skills install x-twitter-browser
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install x-twitter-browser

简介

通过真实的浏览器会话登录 X/Twitter 并执行操作 - 通过 Headless Playwright 发布、回复、转发、点赞和添加书签推文。

SKILL.md

name
x-twitter-browser
description
Log in to X/Twitter via a real browser session and perform actions — posting, replying, reposting, liking, and bookmarking tweets via headless Playwright.
version
2.0.0
user-invocable
true
metadata
openclaw
emoji
🐦
skillKey
x-twitter-browser
requires
bins
allowed-tools
Bash(python3:*)

x-twitter-browser

Execute browser actions on X using a saved login session, without the official X API.

Users log in once via a visible browser window. The session is saved and reused for all subsequent headless operations.

After installing into OpenClaw, the skill lives at:

~/.openclaw/workspace/skills/x-twitter-browser/

Commands below assume you run from the skill root directory:

cd ~/.openclaw/workspace/skills/x-twitter-browser

Use cases

  • You want to automate X actions without the official API
  • Running headless on a VM or Linux server
  • Building a long-term extensible browser skill for X automation

Architecture

This skill has two layers:

1. Session layer

Manages login and cookie persistence (stored in the centralised OpenClaw auth directory):

  • scripts/setup_session.py — log in via visible browser, save cookies
  • ~/.openclaw/auth/x-twitter/cookies.json — Playwright storage state

2. Action layer

Performs actions using the saved session:

  • Post tweet: scripts/post_tweet.py
  • Reply to tweet: scripts/reply_post.py
  • Repost (retweet) / Quote tweet: scripts/repost_post.py
  • Like / Unlike tweet: scripts/like_post.py
  • Bookmark / Remove bookmark: scripts/bookmark_post.py

Dependencies

First-time setup (installs Playwright + Chromium):

./scripts/setup.sh

Note: Chromium download is ~150MB and may take several minutes on first run.

OpenClaw: When running setup.sh via OpenClaw, it executes in the background and the user cannot see the echo output. Forward each progress message to the user so they know the setup is progressing.

Session management

Session cookies are stored in ~/.openclaw/auth/x-twitter/cookies.json (centralised auth directory shared by all OpenClaw skills, survives skill updates). Do not commit or share this file.

Log in (first time or when session expires)

This is a two-phase process. You (the agent) drive both phases — the user does not need to touch the terminal.

Phase 1 — Launch the login browser:

python3 scripts/setup_session.py

This opens a visible browser window at the X login page. The script prints a banner and waits for Enter on stdin before saving cookies. Once the browser is open, tell the user:

A browser window has opened with the X login page. Please log in with your account (username, password, 2FA if prompted). Once you see the home timeline, let me know.

Then wait for the user to confirm they have logged in. Do NOT send Enter yet.

Phase 2 — After the user confirms they are logged in:

Send Enter (newline) to the waiting script's stdin to trigger cookie saving. Check the output for Session saved to confirm success.

If the output shows a WARNING ("The page still looks like a login page"), ask the user to double-check they are actually logged in and can see the home timeline. Once confirmed, send Enter again to save anyway.

Verify session

python3 scripts/setup_session.py --verify-only

Success looks like:

Session looks valid: https://x.com/home

If verification fails, re-run the two-phase login flow above.

OpenClaw / headless-only environments

If running on a headless VM, set up the session on a local machine first, then copy:

scp ~/.openclaw/auth/x-twitter/cookies.json user@server:~/.openclaw/auth/x-twitter/cookies.json

Workflow

1. Set up session (once)

Follow the two-phase login flow in the "Session management" section above. Do not simply run setup_session.py and tell the user to press Enter — you must run it, wait for the user to confirm login, then send Enter yourself.

2. Post a tweet

python3 scripts/post_tweet.py \
  --text "hello"

3. Reply to a tweet

python3 scripts/reply_post.py \
  --tweet "https://x.com/username/status/123456789" \
  --text "My reply"

4. Repost (retweet) a tweet

Plain repost (no comment):

python3 scripts/repost_post.py \
  --tweet "https://x.com/username/status/123456789"

Quote tweet (repost with your comment):

python3 scripts/repost_post.py \
  --tweet "https://x.com/username/status/123456789" \
  --text "My comment"

For both reply and repost, --tweet accepts a full URL or just the tweet ID.

5. Like a tweet

python3 scripts/like_post.py \
  --tweet "https://x.com/username/status/123456789"

Unlike (remove like):

python3 scripts/like_post.py \
  --tweet "https://x.com/username/status/123456789" \
  --undo

6. Bookmark a tweet

python3 scripts/bookmark_post.py \
  --tweet "https://x.com/username/status/123456789"

Remove bookmark:

python3 scripts/bookmark_post.py \
  --tweet "https://x.com/username/status/123456789" \
  --undo

For like and bookmark, --tweet accepts a full URL or just the tweet ID.

Rules

  • --verify-only success means the session is likely usable
  • If the page behaves oddly, buttons are disabled, or extra dialogs appear, re-run setup_session.py
  • If Chromium fails to start, run ./scripts/setup.sh to install browser deps

Operational requirements

  • Before the first action, check if session exists; if not, run the two-phase login flow (see "Session management" above)
  • Run --verify-only before any write operation
  • Confirm the action and content before executing
  • Do not commit cookies to the repo (~/.openclaw/auth/)
  • Call scripts/*.py directly

Troubleshooting

No saved session. Run setup_session.py first to log in to X.

No cookies found at ~/.openclaw/auth/x-twitter/cookies.json. Run the two-phase login flow (see "Session management" above).

Session is not authenticated

  • Session cookies expired (typically lasts days to weeks)
  • Account triggered extra verification

Re-run the two-phase login flow to log in again.

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

72.48%
按下载量换算3,975

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills