Juejin

掘金技术社区一站式操作技能,支持热门文章排行榜查询、Markdown 文章一键发布和文章下载保存为 Markdown。

MIT-0 · Free to use, modify, and redistribute. No attribution required.
2 · 1.3k · 0 current installs · 0 all-time installs
byenoyao@Wscats
MIT-0
Security Scan
VirusTotalVirusTotal
Benign
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
Name/description (Juejin hot lists, publish, download) match the provided code and SKILL.md. Network calls and endpoints are to juejin.cn / api.juejin.cn, Playwright is used for interactive login, and markdown conversion/downloading logic is present — all expected for this purpose.
Instruction Scope
SKILL.md and the code instruct the agent to open a browser for login, call Juejin APIs, read local Markdown files, write downloaded articles to disk, and optionally download images. These actions are within the stated scope but do include filesystem reads/writes (~/.juejin_cookie.json, output/ directory, arbitrary local Markdown files) and headless/headful browser navigation for scraping — the user should understand cookies and saved files are created locally.
Install Mechanism
No install spec is provided (instruction-only in registry) though the package includes requirements.txt. Dependencies (httpx, markdownify, playwright, bs4, lxml) are reasonable for the functionality. Note: Playwright requires additional step to install browsers (playwright install chromium). No remote arbitrary binary downloads are embedded in the skill itself.
Credentials
The skill requests no environment variables or external credentials. It does persist authentication cookies to ~/.juejin_cookie.json in plain JSON — these cookies are sensitive because they grant account access. Saving cookies to disk is proportionate to the publish workflow but is a security consideration the user should accept consciously.
Persistence & Privilege
always:false and default model-invocation behavior (agent may call the skill autonomously) is set. Because the skill can load a saved cookie and publish articles programmatically (run_publish.py / ArticlePublisher), an agent that invokes skills autonomously could publish using the saved credentials unless the user prevents it. The skill does not modify other skills or global agent settings.
Assessment
This skill appears to do what it says: query Juejin hot lists, download posts to Markdown, and publish Markdown posts using a browser-obtained cookie. Before installing or using it: 1) Be aware it will store your Juejin session cookies in plaintext at ~/.juejin_cookie.json — treat that file like a secret and remove it if you don't want persistent access. 2) Playwright and its browser binaries must be installed separately; installing these grants the skill the ability to open a local browser context. 3) If you enable autonomous model invocation, the agent could use any saved cookie to publish posts without interactive confirmation — consider disabling autonomous invocation for this skill or avoid saving the cookie. 4) Respect Juejin's terms of service when bulk-downloading content. If any of these behaviors are unacceptable, do not install or do not save cookies; otherwise the bundle is coherent with its stated purpose.

Like a lobster shell, security has layers — review code before you run it.

Current versionv1.0.0
Download zip
latestvk9789qnwjhgg3ry0sfs3rh9zp9832kyz

License

MIT-0
Free to use, modify, and redistribute. No attribution required.

SKILL.md

Juejin Skills - 掘金技术社区操作技能

🚀 快速使用

本技能支持以下自然语言指令,直接对 AI 说出即可:

热门文章排行榜

  • "获取掘金热门文章排行榜"
  • "查看掘金前端分类的热门文章"
  • "掘金有哪些文章分类?"
  • "获取掘金后端/前端/Android/iOS/人工智能分类的热门趋势"
  • "帮我看看掘金最近最火的文章是哪些"

文章发布

  • "帮我把这篇 Markdown 文章发布到掘金"
  • "发布文章到掘金,分类为前端,标签为 Vue.js"
  • "一键发布文章到掘金平台"
  • "登录掘金账号"(会通过 Playwright 打开浏览器让你登录)

文章下载

  • "下载掘金文章并保存为 Markdown"
  • "把这篇掘金文章保存到本地"
  • "批量下载掘金某个作者的所有文章"
  • "下载这个链接的掘金文章:https://juejin.cn/post/xxx"

技能描述

属性内容
技能名称Juejin Skills(掘金技术社区操作技能)
技能类型Prompt-based Skill(自然语言驱动)
技能语言Python
目标网站https://juejin.cn/
激活方式自然语言指令

激活条件

当用户说出或暗示以下内容时,做出回应:

1. 热门文章排行榜技能

  • 用户想要获取掘金网站热门文章排行榜
  • 用户需要查询掘金文章分类列表
  • 用户想了解各分类的热门文章趋势
  • 用户需要获取全部领域或特定领域的热门文章
  • 用户想要了解掘金技术文章排行、阅读量排名
  • 关键词:掘金、热门、排行榜、文章分类、趋势、热榜

2. 文章发布技能

  • 用户想要将 Markdown 文章发布到掘金平台
  • 用户需要登录掘金账号(通过 Playwright 浏览器登录获取 Cookie)
  • 用户想要设置文章分类、标签、摘要和封面图
  • 用户需要一键发布文章到掘金
  • 关键词:发布、发文、投稿、掘金、Markdown

3. 文章下载技能

  • 用户想要下载掘金文章并保存为 Markdown 格式
  • 用户需要批量下载某作者的掘金文章
  • 用户想要保存掘金文章到本地
  • 关键词:下载、保存、导出、Markdown、掘金文章

功能清单

📊 功能一:热门文章排行榜

子功能说明
获取分类列表获取掘金所有文章分类(前端、后端、Android、iOS、人工智能等)
热门文章排行获取指定分类或全部分类的热门文章排行榜
文章趋势分析按时间维度(3天/7天/30天/历史)查看文章热度趋势
排行榜筛选支持按分类、时间范围、排序方式筛选

API 接口

  • 分类列表:GET https://api.juejin.cn/tag_api/v1/query_category_briefs
  • 热门文章:POST https://api.juejin.cn/recommend_api/v1/article/recommend_all_feed
  • 分类文章:POST https://api.juejin.cn/recommend_api/v1/article/recommend_cate_feed
  • 标签列表:POST https://api.juejin.cn/tag_api/v1/query_category_tags

📝 功能二:文章自动发布

子功能说明
浏览器登录通过 Playwright 打开掘金登录页面,用户扫码或密码登录后自动获取 Cookie
Cookie 管理保存、加载、验证 Cookie 状态
Markdown 解析读取本地 Markdown 文件,提取标题、正文内容
文章发布通过掘金 API 创建草稿并发布,支持设置分类、标签、摘要、封面图
草稿管理支持保存为草稿而不立即发布

API 接口

  • 创建草稿:POST https://api.juejin.cn/content_api/v1/article_draft/create
  • 发布文章:POST https://api.juejin.cn/content_api/v1/article/publish
  • 获取标签:POST https://api.juejin.cn/tag_api/v1/query_category_tags

鉴权方式:Cookie 鉴权(通过 Playwright 浏览器登录获取)

📥 功能三:文章下载

子功能说明
单篇下载通过文章 URL 下载单篇文章,保存为 Markdown
批量下载下载指定作者的所有/部分文章
格式转换将掘金文章 HTML 内容转换为标准 Markdown
图片处理可选下载文章中的图片到本地
元数据保留保留文章标题、作者、发布时间、标签等元信息

API 接口

  • 文章详情:POST https://api.juejin.cn/content_api/v1/article/detail
  • 用户文章列表:POST https://api.juejin.cn/content_api/v1/article/query_list

技术架构

juejin/
├── SKILL.md              # 技能定义文档
├── README.md             # 项目说明文档
├── requirements.txt      # Python 依赖
├── juejin_skill/         # 主模块
│   ├── __init__.py
│   ├── config.py         # 配置管理
│   ├── api.py            # 掘金 API 封装
│   ├── auth.py           # 登录鉴权(Playwright)
│   ├── hot_articles.py   # 热门文章排行榜
│   ├── publisher.py      # 文章发布
│   ├── downloader.py     # 文章下载
│   └── utils.py          # 工具函数
└── output/               # 下载文章输出目录

环境要求

Prompt 示例

用户:帮我获取掘金前端分类的热门文章排行榜
AI:正在获取掘金前端分类的热门文章...

用户:把 ./my-article.md 发布到掘金,分类选前端,标签加上 Vue.js 和 TypeScript
AI:正在登录掘金账号并发布文章...

用户:下载这篇掘金文章 https://juejin.cn/post/7300000000000000000
AI:正在下载文章并转换为 Markdown 格式...

Files

13 total
Select a file
Select a file to preview.

Comments

Loading comments…