Skip to content

feat(xianyu): add inbox, messages, and reply commands#1639

Open
jun0315 wants to merge 2 commits into
jackwener:mainfrom
jun0315:feature/xianyu-im-messaging
Open

feat(xianyu): add inbox, messages, and reply commands#1639
jun0315 wants to merge 2 commits into
jackwener:mainfrom
jun0315:feature/xianyu-im-messaging

Conversation

@jun0315
Copy link
Copy Markdown
Contributor

@jun0315 jun0315 commented May 17, 2026

Description

Adds Xianyu private-message support:

  • Add xianyu inbox to list recent IM conversations with unread and unread_count
  • Add xianyu messages to read recent messages from a specific conversation
  • Add xianyu reply to reply to a specific conversation
  • Support --rank for messages / reply so commands can operate on visible inbox rows when Xianyu does not expose itemId / peerUserId
  • Refactor shared Xianyu IM DOM helpers into clis/xianyu/im.js
  • Update docs, README command list, manifest, and tests

Related issue:

Type of Change

  • Bug fix
  • ✨ New feature
  • New site adapter
  • Documentation
  • ♻️ Refactor
  • CI / build / tooling

Checklist

  • I ran the checks relevant to this PR
  • I updated tests or docs if needed
  • I included output or screenshots when useful

Documentation (if adding/modifying an adapter)

  • Added doc page under docs/adapters/ (if new adapter)
  • Updated docs/adapters/index.md table (if new adapter)
  • Updated sidebar in docs/.vitepress/config.mts (if new adapter)
  • Updated README.md / README.zh-CN.md when command discoverability changed
  • Used positional args for the command's primary subject unless a named flag is clearly better
  • Normalized expected adapter failures to CliError subclasses instead of raw Error

Screenshots / Output

Checks run:

npx vitest run --project adapter clis/xianyu
5 files passed, 33 tests passed

npx tsx src/main.ts validate xianyu
opencli validate: PASS
Checked 7 command(s)
npm run check:silent-column-drop -- xianyu/inbox xianyu/messages xianyu/reply xianyu/chat
OK - no new silent-column-drop violations.

xianyu inbox --limit 10 --unread-only true --site-session persistent
Returned only unread conversations.
Returned real conversation messages.

xianyu reply --rank 1 --text "测试消息,请忽略" --site-session persistent
Returned status: sent, and the message was visible when read back.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant