Files
Nexus/docs/changelog/2026-06-06-frontend-14p-contract-audit.md
T
Nexus Agent ac17f91106 docs(audit): 14 页 API 契约审计与凭据轮询 SSOT 收尾
记录凭据轮询/pending 契约对照与生产验证,更新功能指南与附录 J,并将 pending 相关类型集中到 api.ts。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-06 23:50:05 +08:00

1.6 KiB
Raw Blame History

2026-06-06 — 前端 14 页 API 契约审计(含凭据轮询)

摘要

对 14 页及 composables 与后端 API 做静态契约对照;确认凭据轮询 add-by-ip / pending 四端点与预设 username 前后端一致;补齐共享类型与 SSOT 文档。

动机

凭据轮询功能已合入(4ba45ab),需在 2026-06-04 深审 closure 基础上增量验证 API 契约,避免部署后前后端字段漂移。

涉及文件

  • docs/reports/2026-06-06-frontend-14p-contract-audit.md — 审计报告(新)
  • docs/project/nexus-functional-development-guide.md — §12.2、§12.7
  • docs/project/nexus-functional-development-guide-appendix.md — 附录 J
  • frontend/src/types/api.tsPendingServerItemAddByIpResponsePollErrorItem
  • frontend/src/pages/ServersPage.vue — 改用共享类型

迁移 / 重启

无 DB 变更;文档与类型仅影响前端构建。

验证

.venv/bin/pytest tests/test_credential_poller.py -q  # 7 passed
cd frontend && npx vite build

生产验证(2026-06-06 续)

结论

14 页 API 契约 PASS0 P0/P1 新 FINDING。生产 API + SPA 已部署;本地 local_verify 因宿主机 MySQL 2013 未跑通。