xianyu-publisher

xianyu-publisher is a skill for Claude Code, Codex from AlanSong2077/Amplipost. It costs 76 tokens per session (992 once invoked), scanned A, original, MIT.

An automation tool for listing second-hand goods on Xianyu, a Chinese marketplace. It can fill in product details, generate product images, filter sensitive words, and preserve the browser login after the first sign-in.

In plain words
What is it for?
Use it to create Xianyu listings with a title, price, description, condition, and images, including listings that use automatically generated images.
Why use it?
It removes repetitive listing work and helps prepare the required marketplace fields consistently.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to create Xianyu listings with a title, price, description, condition, and images, including listings that use automatically generated images.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/alansong2077/amplipost/xianyu-publisher
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add AlanSong2077/Amplipost --skill xianyu-publisher
Clone the repo
git clone --depth 1 https://github.com/AlanSong2077/Amplipost

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for xianyu-publisher

README.md
[![agentmods](https://agentmods.dev/badge/skills/alansong2077/amplipost/xianyu-publisher/github.svg)](https://agentmods.dev/skills/alansong2077/amplipost/xianyu-publisher)
Your own site
<a href="https://agentmods.dev/skills/alansong2077/amplipost/xianyu-publisher"><img src="https://agentmods.dev/badge/skills/alansong2077/amplipost/xianyu-publisher/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for xianyu-publisher

Your own site · 80×15
<a href="https://agentmods.dev/skills/alansong2077/amplipost/xianyu-publisher"><img src="https://agentmods.dev/badge/skills/alansong2077/amplipost/xianyu-publisher.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 76 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 992 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00076 $0.00992
Opus 5 $0.00038 $0.00496
Sonnet 5 $0.00015 $0.00198
Haiku 4.5 $0.00008 $0.00099

Measured 12d ago against content hash 109ac6774fb0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

xianyu-publisher scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/auto_publish.py, scripts/xianyu_publish_scrapling.py, scripts/xianyu_publish.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

publishers/xianyu-publisher/SKILL.md · 124 lines

What it actually says

闲鱼自动发布 Skill

适配新版闲鱼 (goofish.com),支持 AI 生成商品配图、中文显示、多种商品分类。

功能概述

  1. 自动发布 - 自动填写标题、价格、描述、新旧程度
  2. AI 配图 - 自动生成支持中文的商品图片
  3. 违禁词过滤 - 自动替换敏感词
  4. 登录态保存 - 首次登录后自动保存 cookies

触发词

  • "发布闲鱼"
  • "闲鱼上架"
  • "卖闲置"
  • "帮我发布商品"
  • "自动发布二手"
  • "闲鱼助手"

快速开始

1. 首次登录

对我说 "登录闲鱼"

会打开浏览器让你登录闲鱼,自动保存登录状态。

2. 发布商品

简单模式:

发布闲鱼:iPhone 15 Pro Max,256GB,5999元,95新

完整模式:

帮我发布闲鱼:
- 商品:MacBook Pro 14寸
- 描述:M3 Pro芯片,18G+512G,无划痕
- 价格:9999
- 新旧:95新
- 图片:/tmp/macbook.jpg

自动配图模式:

帮我发布闲鱼(自动生成图片):
- 商品:中美港股财报数据
- 描述:Excel格式,83列财务指标
- 价格:2
- 新旧:全新

输入参数

参数 必填 说明 示例
商品名称 商品标题 iPhone 15 Pro Max
价格 售价(元) 5999
描述 商品详情 256GB,电池健康98%
新旧程度 全新/95新/9成新等 95新
图片 本地路径或自动生成 /tmp/iphone.jpg

新旧程度选项

  • 全新、99新、95新、9成新、8成新、7成新、6成新及以下

内部结构

xianyu-publisher/
├── SKILL.md                      # 本文件
├── references/
│   ├── content-rules.md          # 发布规则和违禁词
│   ├── troubleshooting.md        # 故障排除
│   └── image-generation.md       # AI 配图指南
└── scripts/
    ├── xianyu_publish.py         # 核心发布脚本 (Playwright)
    └── auto_publish.py           # 高级发布(模板+违禁词)

核心脚本用法

xianyu_publish.py

python3 scripts/xianyu_publish.py \
  --title "【95新】iPhone 14 128GB" \
  --description "功能正常,欢迎咨询" \
  --price "2000" \
  --new-degree "95新" \
  --image "/tmp/product.jpg" \
  --profile "default"

自动配图

使用 references/image-generation.md 中的代码生成支持中文的图片。

违禁词处理

违禁词替换由 content-coordinator Agent 在生成内容时负责处理,Skill 脚本直接接收已处理好的内容执行发布。详见 references/content-rules.md

故障排除

详见 references/troubleshooting.md

常见问题:

  1. 登录失效 → 对我说"登录闲鱼"重新登录
  2. 发布失败 → 检查 cookies 是否过期
  3. 图片中文乱码 → 使用 PIL 中文字体(STHeiti Light.ttc)

更新日志

  • 2026-03-23: 适配新版 goofish.com,修复 contenteditable 标题输入,添加中文配图支持
Files

What ships with it

7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 124 lines · 76 tokens per session scan A 109ac6774fb0

Subscribe to this mod's changes

xianyu-publisher is a skill published in the GitHub repository AlanSong2077/Amplipost (45 stars, last pushed 4mo ago), licensed MIT. It adds 76 tokens to every session and 992 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

ebay-search-listing

Extracts product listings from any eBay search or category page URL, returning per-item cards (itemNumber, url, title, subtitle, caption, price, priceWithCurrency, currency, wasPrice, bids, shipping, seller, sellerFeedbackCount, sellerPositiveRating, reviewsCount, starRating, image) plus pagination state (currentPage…

browser-act/skills · 221 tokens

amazon-bestseller-listing

Amazon Best Sellers listing scraper: extract product cards from any Amazon Best Sellers (zgbs) or /gp/bestsellers/ category page — returns rank (position on chart), asin, title, url, image, imageAlt, price, stars, reviewCount, ratingRaw per item, plus category metadata (categoryName, categoryFullName, categoryUrl) and…

browser-act/skills · 300 tokens

amazon-search-listing

Amazon search and category listing scraper: extract product listings from any Amazon search results page, keyword search URL, or category browse page and return per-item cards (asin, title, url, image, price, listPrice, stars, reviewCount, badges, isAmazonChoice, isBestSeller, isSponsored, delivery, boughtInPast…

browser-act/skills · 341 tokens

etsy-category-listing

Etsy category page scraper: given an Etsy category URL (e.g. https://www.etsy.com/c/jewelry) and optional page number, returns paginated product listings with listingId, shopId, title, url, image, salePrice, originalPrice, currency, rating, reviewCount, shopName, isAd, freeShipping, badge from category and subcategory…

browser-act/skills · 209 tokens

etsy-product-detail

Etsy product detail scraper: given an Etsy listing URL, returns full product detail including listingId, title, priceCurrent, priceOriginal, currency, images (all), description, shopName, shopUrl, rating, reviewCount, favorites, inCartCount, variations (with per-option price ranges), highlights, listedDate…

browser-act/skills · 187 tokens

etsy-shop-catalog

Etsy shop catalog scraper: given an Etsy shop URL (e.g. https://www.etsy.com/shop/{shop-name}) and optional page number, returns paginated product listings from that shop's own storefront with listingId, shopId, title, url, image, salePrice, originalPrice, currency, rating, reviewCount, shopName, isAd, freeShipping…

browser-act/skills · 208 tokens