An open API service indexing awesome lists of open source software.

https://github.com/tangka/x-post-cover

把 X 推文转成公众号封面卡图 + Markdown · Codex/Claude Code skill
https://github.com/tangka/x-post-cover

claude-code codex skill twitter wechat

Last synced: about 5 hours ago
JSON representation

把 X 推文转成公众号封面卡图 + Markdown · Codex/Claude Code skill

Awesome Lists containing this project

README

          

# x-post-cover

A Claude Code skill that turns any X (Twitter) post into a styled cover image + Markdown file — ready for WeChat articles.

**One command:**
```
/x-cover https://x.com/someone/status/123456789
```

Claude scrapes the tweet, translates it, generates a cover PNG, and saves everything to your library folder.

---

## What it produces

```
library/
└── 2026-05-31_OpenAIDevs_206076.../
├── cover.png ← styled tweet card (360 × auto px, 2× retina)
└── content.md ← original text + translation + metadata
```

---

## Requirements

- macOS (uses Chrome's cookie store for X authentication)
- [Node.js](https://nodejs.org) ≥ 18
- Google Chrome — logged into X
- [Claude Code](https://claude.ai/code)
- A [DeepSeek API key](https://platform.deepseek.com) for translation

---

## Install

```bash
git clone https://github.com/tangka/x-post-cover ~/.claude/skills/x-post-cover
```

Then run `/x-cover ` — the skill handles the rest automatically.

---

## Configuration (`.env`)

| Key | Required | Description |
|-----|----------|-------------|
| `DEEPSEEK_API_KEY` | Yes | DeepSeek API key for translation |
| `LIBRARY` | Yes | Absolute path to output folder |
| `TARGET_LANG` | No | Translation language — BCP 47 tag (default: `zh`) |
| `QRCODE` | No | Show QR code: `show` or `hide` (default: `show`) |
| `CHROME` | No | Chrome executable path (macOS default works out of the box) |
| `COOKIES_DB` | No | Chrome Cookies DB path (override for non-default profiles) |

Replace `public/assets/codexx-qrcode.jpg` with your own QR code image.

---

## Usage

```
/x-cover https://x.com/someone/status/123456789
```

Or run directly:

```bash
npm run cover -- https://x.com/someone/status/123456789
```

---

## Supported translation languages

`zh` · `ja` · `ko` · `fr` · `de` · `es` · `pt` · `ru` · `ar`

---

## License

MIT

## 📣 关于作者 & 支持

这套工具来自我运营的两个公众号,欢迎关注 👇

- **Codexx** —— Codex 铁粉中文社区
- **ClaudeDevs** —— Claude 中文社区

Codexx 公众号    ClaudeDevs 公众号

如果这些工具帮到你,欢迎请我喝杯咖啡 ☕

微信    支付宝