搜索

PythonReactSEOPDF
OpenClaw

x-twitter-by-altf1be

Post tweets, threads, and media to X/Twitter via API v2 — secure OAuth 1.0a, no external npm dependencies.

abdelkrim0 来源安装数☆ 0 仓库 Stars

安装与使用

请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。

SkillHub CLI

skillhub install abdelkrim/x-twitter-by-altf1be

打开来源仓库,查看说明和兼容环境后,按来源提供的命令或步骤安装。

将来源链接提供给你的 Agent,让它先读取说明、核对依赖,并向你说明将执行的安装步骤。

查看来源 ↗使用指南

技能说明

X/Twitter by @altf1be

Post tweets, threads, and media to X/Twitter via the X API v2 with secure OAuth 1.0a signing.

Setup

  1. Get API keys from https://developer.x.com
  2. Set environment variables (or create .env in {baseDir}):
X_CONSUMER_KEY=your-api-key
X_CONSUMER_SECRET=your-api-secret
X_ACCESS_TOKEN=your-access-token
X_ACCESS_TOKEN_SECRET=your-access-token-secret
  1. Install dependencies: cd {baseDir} && npm install

Commands

# Verify connection
node {baseDir}/scripts/xpost.mjs verify

# Post a tweet
node {baseDir}/scripts/xpost.mjs tweet "Hello from OpenClaw! 🦞"

# Post with image
node {baseDir}/scripts/xpost.mjs tweet "Check this out!" --media ./screenshot.png

# Reply to a tweet
node {baseDir}/scripts/xpost.mjs tweet "Great point!" --reply 1234567890

# Post a thread (inline)
node {baseDir}/scripts/xpost.mjs thread "First tweet" "Second tweet" "Third tweet"

# Post a thread (from file, tweets separated by ---)
node {baseDir}/scripts/xpost.mjs thread --file ./thread.md

Thread file format

Create a file with tweets separated by ---:

🚀 Announcing something cool!
---
Here's why it matters...
---
Check it out: https://example.com
#OpenSource #AI

Security

  • OAuth 1.0a user context signing (no app-only auth for write operations)
  • No credentials printed to stdout
  • API calls use pure Node.js fetch + built-in node:crypto (no third-party HTTP or OAuth libraries)
  • Minimal dependencies: only commander (CLI framework) and dotenv (env loading)

Author

Abdelkrim BOUJRAF — ALT-F1 SRL, Brussels 🇧🇪 X: @altf1be

来源信息

Source
github
Repository
openclaw/skills
Path
skills/abdelkrim/x-twitter-by-altf1be
Version
—
Commit
94b00a69bc7bd16c5bcb16a56055f5c56dfe6513
分类来源
rules
状态
active
可见性
public

这些信息来自收录时的来源分析,可能滞后;使用前请核对最新来源文件。

README

openclaw-skill-x-twitter

OpenClaw skill for X/Twitter — post tweets, threads, and media via X API v2.

Features

  • Post tweets — text with optional image attachment
  • Post threads — multi-tweet threads from inline args or file
  • Reply to tweets — respond to specific tweets
  • Verify connection — check API credentials and account info

Prerequisites

  • Node.js 18+
  • X/Twitter developer account with Free tier (or higher)
  • API keys (Bearer Token, Consumer Key/Secret, Access Token/Secret)

Setup

cd openclaw-skill-x-twitter
npm install

cp .env.example .env
# Edit .env with your X API credentials

# Verify connection
node scripts/xpost.mjs verify

Usage

# Post a tweet
node scripts/xpost.mjs tweet "Hello world!"

# Post with image
node scripts/xpost.mjs tweet "Check this out" --media ./image.png

# Reply to a tweet
node scripts/xpost.mjs tweet "Great post!" --reply 1234567890

# Post a thread (inline)
node scripts/xpost.mjs thread "Tweet 1" "Tweet 2" "Tweet 3"

# Post a thread (from file, separated by ---)
node scripts/xpost.mjs thread --file ./my-thread.md

Usage with OpenClaw

Once installed as a skill, use natural language:

"Tweet: Just shipped a new feature! 🚀"

"Post this thread about our SharePoint integration"

"Reply to that tweet saying thanks"

License

MIT — see LICENSE.

Author

Abdelkrim BOUJRAF ALT-F1 SRL — Brussels, Belgium

来源内容

SKILL.md
# X/Twitter by @altf1be

Post tweets, threads, and media to X/Twitter via the X API v2 with secure OAuth 1.0a signing.

## Setup

1. Get API keys from https://developer.x.com
2. Set environment variables (or create `.env` in `{baseDir}`):

```
X_CONSUMER_KEY=your-api-key
X_CONSUMER_SECRET=your-api-secret
X_ACCESS_TOKEN=your-access-token
X_ACCESS_TOKEN_SECRET=your-access-token-secret
```

3. Install dependencies: `cd {baseDir} && npm install`

## Commands

```bash
# Verify connection
node {baseDir}/scripts/xpost.mjs verify

# Post a tweet
node {baseDir}/scripts/xpost.mjs tweet "Hello from OpenClaw! 🦞"

# Post with image
node {baseDir}/scripts/xpost.mjs tweet "Check this out!" --media ./screenshot.png

# Reply to a tweet
node {baseDir}/scripts/xpost.mjs tweet "Great point!" --reply 1234567890

# Post a thread (inline)
node {baseDir}/scripts/xpost.mjs thread "First tweet" "Second tweet" "Third tweet"

# Post a thread (from file, tweets separated by ---)
node {baseDir}/scripts/xpost.mjs thread --file ./thread.md
```

## Thread file format

Create a file with tweets separated by `---`:

```
🚀 Announcing something cool!
---
Here's why it matters...
---
Check it out: https://example.com
#OpenSource #AI
```

## Security

- OAuth 1.0a user context signing (no app-only auth for write operations)
- No credentials printed to stdout
- API calls use pure Node.js `fetch` + built-in `node:crypto` (no third-party HTTP or OAuth libraries)
- Minimal dependencies: only `commander` (CLI framework) and `dotenv` (env loading)

## Author

Abdelkrim BOUJRAF — [ALT-F1 SRL](https://www.alt-f1.be), Brussels 🇧🇪
X: [@altf1be](https://x.com/altf1be)
README
# openclaw-skill-x-twitter

OpenClaw skill for X/Twitter — post tweets, threads, and media via X API v2.

## Features

- **Post tweets** — text with optional image attachment
- **Post threads** — multi-tweet threads from inline args or file
- **Reply to tweets** — respond to specific tweets
- **Verify connection** — check API credentials and account info

## Prerequisites

- Node.js 18+
- X/Twitter developer account with Free tier (or higher)
- API keys (Bearer Token, Consumer Key/Secret, Access Token/Secret)

## Setup

```bash
cd openclaw-skill-x-twitter
npm install

cp .env.example .env
# Edit .env with your X API credentials

# Verify connection
node scripts/xpost.mjs verify
```

## Usage

```bash
# Post a tweet
node scripts/xpost.mjs tweet "Hello world!"

# Post with image
node scripts/xpost.mjs tweet "Check this out" --media ./image.png

# Reply to a tweet
node scripts/xpost.mjs tweet "Great post!" --reply 1234567890

# Post a thread (inline)
node scripts/xpost.mjs thread "Tweet 1" "Tweet 2" "Tweet 3"

# Post a thread (from file, separated by ---)
node scripts/xpost.mjs thread --file ./my-thread.md
```

## Usage with OpenClaw

Once installed as a skill, use natural language:

> "Tweet: Just shipped a new feature! 🚀"

> "Post this thread about our SharePoint integration"

> "Reply to that tweet saying thanks"

## License

MIT — see [LICENSE](LICENSE).

## Author

**Abdelkrim BOUJRAF**
[ALT-F1 SRL](https://www.alt-f1.be) — Brussels, Belgium

相关技能