Skip to content

lnvestor/twitr-skills / skills/x-presence

x-presence

Verified

Run an unattended X/Twitter presence — watch topics and mentions in real time, draft posts and replies in the user's own voice, publish original posts on a schedule, and hold replies for a one-tap approval. Trigger whenever the user wants to automate their X/Twitter account, grow an audience on X, schedule or draft tweets, set up an X routine or cron job, get alerted about topics or mentions on X, or run an X agent in the background — including casual phrasings like "post for me on X" or "keep an eye on Twitter for me". Works in Claude Code routines, Hermes cron, and OpenClaw cron. Paid per call in USDC via twitr.sh through an x402 wallet — no API key, no signup. Do NOT trigger for reading a single tweet or profile (use x-twitter-data), for bulk dataset exports (use x-twitter-research), or for non-X platforms.

FileKindSize
SKILL.mdskill md10.2 KB
references/ranking-signals.mdmarkdown5.7 KB
references/scheduling.mdmarkdown4.9 KB
references/x-rules.mdmarkdown3.1 KB

references/scheduling.md

View on GitHub
# Scheduling the cycle

Pick one runtime. All three below were verified against installed versions; flags and
subcommands that don't exist have been left out deliberately.

The prompt is the same everywhere:

> Run one x-presence cycle. Read new monitor events, draft in my voice, publish approved
> original posts, and append reply drafts to .twitr/pending.md. Post no replies.

**Every runtime starts a fresh session with no memory of the last run.** State lives in
`.twitr/state.json`, never in context. Read it first, write it last.

---

## Claude Code routines — cloud, runs with your laptop closed

Best option if the user is on Pro/Max/Team/Enterprise with Claude Code on the web.

```
/schedule every 4 hours, run one x-presence cycle and queue reply drafts
```

Or create it at https://claude.ai/code/routines. Then:

1. **Repositories** — routines require at least one GitHub repo. It gets cloned each run, and
   it's where `.twitr/` lives. Claude pushes to `claude/`-prefixed branches unless you enable
   unrestricted pushes.
2. **Connectors** — include **AgentCash**. Connector traffic is proxied through Anthropic's
   servers, so it works *without* adding any host to the allowed-domains list.
3. **Network access** — if the routine calls `twitr.sh` over plain HTTPS rather than through the
   AgentCash connector, the Default environment blocks it (`403`,
   `x-deny-reason: host_not_allowed`). Fix: edit the environment → Network access → **Custom** →
   add `twitr.sh`, keeping the default list checked. Using the connector avoids this entirely.

Constraints: **minimum interval is one hour**; runs are staggered a few minutes; they draw down
subscription usage and a daily routine cap. Runs are fully autonomous — no approval prompts —
which is exactly why the cycle queues replies instead of posting them.

A green run status only means the session exited without an infrastructure error. Open the run
to confirm what actually happened.

Docs: https://code.claude.com/docs/en/routines

---

## Hermes cron — local daemon

Verified on Hermes Agent 0.19.x.

```sh
hermes cron create "every 4h" \
  "Run one x-presence cycle. Queue reply drafts to .twitr/pending.md. Post no replies." \
  --name x-presence --skill x-presence
```

Schedule accepts `30m`, `every 2h`, or a 5-field cron expression. Useful neighbours:
`hermes cron list`, `hermes cron run <id>` (fires on the next tick), `hermes cron pause`,
`hermes cron status` to confirm the scheduler is alive, and `hermes cron tick` to drain due jobs
once and exit — handy for testing without waiting.

The scheduler ticks about once a minute and locks against overlapping runs, so a slow cycle
won't be started twice.

---

## OpenClaw cron — local, via the Gateway

Verified on OpenClaw 2026.3.1.

```sh
openclaw cron add --name x-presence \
  --cron "0 */4 * * *" \
  --message "Run one x-presence cycle. Queue reply drafts to .twitr/pending.md. Post no replies." \
  --session isolated \
  --tz "$(readlink /etc/localtime | sed 's|.*zoneinfo/||')"
```

`--cron` takes a 5-field expression (or 6-field with seconds). Use `--session isolated` so the
job doesn't accumulate context in the main session. `--stagger 5m` spreads load. Inspect with
`openclaw cron list`, `openclaw cron runs` for history, and `openclaw cron run <id>` to fire once.

Set `--tz` explicitly — an unset timezone means the expression is interpreted in the Gateway's
zone, which may not be the user's.

Docs: https://docs.openclaw.ai/cli/cron

---

## Local cron / launchd + headless Claude

If none of the above fit. **Only these flags exist** — verified against Claude Code 2.1.220:
`-p`/`--print`, `--permission-mode`, `--output-format`, `--allowed-tools`,
`--disallowed-tools`, `--max-budget-usd`. (`--max-turns` does **not** exist; ignore any guide
that uses it.)

```sh
0 */4 * * * cd /path/to/repo && /usr/local/bin/claude -p \
  "Run one x-presence cycle. Queue reply drafts. Post no replies." \
  --permission-mode acceptEdits \
  --max-budget-usd 2 \
  --output-format json >> .twitr/cron.log 2>&1
```

Prefer `acceptEdits` over `bypassPermissions` — an unattended presence loop should not hold
blanket permission. `--max-budget-usd` is a real spend rail; set it.

On macOS prefer **launchd** over crontab: launchd runs jobs missed while the machine slept
(coalesced into one), whereas cron silently skips them. That coalescing is precisely why every
write needs an `Idempotency-Key`.

Log in first — headless cannot establish auth mid-run. `claude setup-token` mints a long-lived
subscription token for unattended use. Note `ANTHROPIC_API_KEY` **outranks** it and silently
switches you to metered API billing, so unset it in the cron environment if you don't want that.

---

## Approving the queue

Scheduling handles everything except replies. In any interactive session:

> review my pending X replies

The skill reads `.twitr/pending.md`, shows each draft with its source post and cost, and posts
only what the user approves.
reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 322kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 322kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is availableStars: 322kUpdated Claude CodeCodexVerifiedInstall