Skip to content

feat: include email in account status - #5

Merged
bwayne98 merged 1 commit into
developfrom
feat/account-status-email
Aug 24, 2026
Merged

feat: include email in account status#5
bwayne98 merged 1 commit into
developfrom
feat/account-status-email

Conversation

@bwayne98

Copy link
Copy Markdown
Contributor

摘要

在 lihi 的 AccountStatus 契約中新增必填的非空 email 欄位,讓一般帳號資訊查詢與工作群組/短網址網域切換結果都能顯示目前帳號 email。

一般帳號狀態現在會先顯示 帳號 Email:<email>,再依序顯示短網址用量、目前方案、續訂日期、目前工作群組與目前短網址網域。只查詢 email、群組或網域時仍只顯示使用者要求的欄位,不附加訂閱方案說明。

AccountStatus 契約

  • account_statusaccount_switch_groupaccount_switch_domain 的成功結果都必須包含非空字串 email
  • 顯示 email 時完整保留 server 回傳值,不做正規化或推導;
  • 一般帳號狀態與 selector switch 的完整結果都將 email 放在第一行;
  • 原有 group_namedomain、用量、方案與日期的驗證、null rendering 與顯示順序維持不變;
  • 成功切換 selector 後仍直接使用 switch 回傳的 AccountStatus,不追加狀態查詢。

Skill 與 host parity

同步更新 Codex 與 Claude Code 的三個相關 skills:

  • lihi-account
    • 將帳號 email 納入 skill routing 與觸發描述;
    • 驗證 email 為非空字串;
    • 一般帳號資訊改為依序顯示六個欄位;
    • email/group/domain-only 回覆不顯示訂閱方案說明。
  • lihi-switch-group
    • 驗證 switch 回傳的 email
    • 完整狀態第一行顯示帳號 email。
  • lihi-switch-domain
    • 驗證 switch 回傳的 email
    • 完整狀態第一行顯示帳號 email。

兩個 host 的行為與使用者可見文案保持一致;OAuth、錯誤復原、group switching、domain switching 與 shortening 流程沒有改變。

OpenAI Platform 打包

更新 scripts/package_openai_platform_bundle.py 的 host-neutral rewrite,對應 production skill 新增的 email wording:

  • standalone switch skills 保留 email 欄位驗證與顯示規則;
  • OpenAI skill artifact 仍移除 production host 的訂閱方案導購句;
  • 不改變四個 skill ZIP 的結構、identity、production MCP dependency 或封裝範圍。

文件與 metadata

  • 更新英文與繁中 installation guides,說明一般帳號狀態會先顯示 email;
  • 更新 Codex/Claude plugin-internal READMEs;
  • 更新 MCP contract 與 acceptance scenarios;
  • 更新 repository guide 的 AccountStatus shape 與顯示規則;
  • runtime skill 變更後刷新 Codex plugin 的單一 cachebuster,semantic version core 維持 0.3.1

測試覆蓋

  • 驗證 account skill 將 email 納入 routing、schema 與完整狀態第一行;
  • 驗證兩個 selector switch skills 都要求並顯示 email;
  • 驗證 email-only 回覆不附加訂閱方案說明;
  • 驗證 OpenAI Platform 產生的 switch skill artifacts 保留 email 契約與顯示規則;
  • 保留既有 host parity、packaging isolation 與 artifact 結構測試。

測試與驗證

  • python3 -m unittest discover -s tests -v(71 tests passed)
  • Codex/Claude detector scripts byte-for-byte 相同
  • Codex/Claude shortening workflow byte-for-byte 相同
  • Codex/Claude group/domain switch error-recovery references byte-for-byte 相同
  • git diff --check

Reviewer 重點

  • 確認所有 AccountStatus 成功結果都要求非空 email
  • 確認一般帳號狀態與 selector switch 結果第一行顯示 email,並完整保留 server 回傳值;
  • 確認只查詢 email、目前群組或目前網域時不顯示未要求的欄位與訂閱方案說明;
  • 確認 Codex 與 Claude Code 的 account/switch skills 維持語意一致;
  • 確認 OpenAI Platform rewrite 仍能精確套用,且產物保留 email 契約;
  • 確認本次沒有改變 OAuth、selector mutation、shortening、runtime identity、MCP endpoint 或 semantic version core。

- require and preserve account email in AccountStatus responses
- display email first for general status and selector switch results
- keep Codex and Claude account and switch skills aligned
- update the public OpenAI skill overlay for the revised source wording
- refresh protocol, acceptance, installation, and plugin documentation
- extend source and packaged-skill regression coverage
- refresh the Codex plugin cachebuster after runtime changes
@bwayne98
bwayne98 merged commit 3e3744d into develop Aug 24, 2026
2 checks passed
@bwayne98
bwayne98 deleted the feat/account-status-email branch August 31, 2026 03:55
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