Feature Overview
This skill is used to retrieve technical article ranking data from the Juejin (juejin.cn) website, including:
- Article category list (frontend, backend, AI, mobile development, etc.)
- Trending article rankings for each category
- Article details (title, author, read count, like count, etc.)
Workflow
1. Get category list
When the user needs to learn about Juejin article categories:
node scripts/juejin.js categories
Example return:
[
{ "id": "6809637769959178254", "name": "前端" },
{ "id": "6809637769959178255", "name": "后端" },
{ "id": "6809637769959178256", "name": "Android" },
{ "id": "6809637769959178257", "name": "iOS" },
{ "id": "6809637769959178258", "name": "人工智能" },
{ "id": "6809637769959178260", "name": "开发工具" },
{ "id": "6809637769959178261", "name": "代码人生" },
{ "id": "6809637769959178262", "name": "阅读" }
]
2. Get trending articles
When the user needs to get trending articles in a specific category:
node scripts/juejin.js articles <category_id> [type] [limit]
Parameters:
category_id: Category ID (obtained from the category list)type: Sort type, optionalhot(trending) ornew(latest), defaulthotlimit: Number of articles to return, default 20
Example return:
[
{
"title": "文章标题",
"brief": "文章摘要...",
"author": "作者名",
"articleId": "123456789",
"popularity": 100,
"viewCount": 5000,
"likeCount": 200,
"collectCount": 150,
"commentCount": 50,
"url": "https://juejin.cn/post/123456789",
"tags": ["JavaScript", "Vue"]
}
]
Usage examples
View all categories
node scripts/juejin.js categories
Get trending frontend articles (top 10)
node scripts/juejin.js articles 6809637769959178254 hot 10
Get latest backend articles
node scripts/juejin.js articles 6809637769959178255 new 15
Author introduction
- Omnipresent One Piece Fan
- My WeChat official account: Omnipresent Technology