docs(ee/audit): action type table is out of sync with code
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 76/100
- Issue 类型
- 文档
- 描述清晰度
- 描述清楚
- 活跃度
- 冷清
- 技术栈
- typescript
- 领域
- api, documentation
调研方向
Start with docs/docs/configuration/audit-logs.mdx and compare its table and schemas with the createAudit calls in the named membership.service.ts and ee/features/scim/actions.ts locations. Use docs/api-reference/sourcebot-public.openapi.json and publicApiDocument.ts as references for the query parameters and headers. Done means the MDX reflects the active actions and schemas, documents the pagination and filtering details, renders cleanly, and leaves openapi generation unaffected.
由索引模型根据 Issue 内容生成。
描述
Title: docs(ee/audit): action type table is out of sync with code
The Audit action types table in docs/docs/configuration/audit-logs.mdx (lines 113-150) is missing 4 entries that the code actually writes, and has 1 stale entry that the code does not write.
Missing entries (in code, not in docs)
org.member_deactivated—packages/web/src/features/membership/membership.service.ts:305-310(target typeuser)org.member_reactivated—packages/web/src/features/membership/membership.service.ts:353-358(target typeuser)scim_token.created—packages/web/src/ee/features/scim/actions.ts:75-84(target typescim_token, metadata{ scim_token: <name> })scim_token.deleted—packages/web/src/ee/features/scim/actions.ts:112-121(target typescim_token, metadata{ scim_token: <name> })
Stale entry (in docs, not in code)
user.delete(line 127) — nocreateAudit({ action: "user.delete", ... })orcreateAudit({ action: "user.deleted", ... })call exists inpackages/. Closest active entry isuser.readin the EE user GET handler.
Related gaps in the same file
- The
targetTypeenum in the response schema (line 197) is missingscim_tokenas a value. - The query parameters (
since,until,page,perPage) and the response headers (X-Total-Count,Link) are documented indocs/api-reference/sourcebot-public.openapi.jsonand the correspondingpublicApiDocument.tsregistration, but not in the.mdxpage. The page only shows a single unparameterisedcurlexample. - The
metadataschema (line 201-218) is missingscim_tokenas a known key (used by the two newscim_token.*actions).
Proposed fix
Update docs/docs/configuration/audit-logs.mdx so the action type table, the targetType enum, and the metadata schema all reflect the actual code. Remove the stale user.delete row. Add a short section documenting the four query parameters and the two response headers, with one curl example showing time-range filtering and one showing paginated traversal. No code or behaviour changes; no changelog entry needed (docs only).
Acceptance criteria
- The action type table in the
.mdxcontains everyactionvalue that anycreateAudit/createAuditActioncall writes, and contains no value the code never writes. - The response schema
targetTypeenum includesscim_token. - The
metadataschema includesscim_tokenas a known key. - The page documents
since,until,page, andperPageas query parameters, andX-Total-CountandLinkas response headers. - The page still renders cleanly (Mintlify) and
yarn workspace @sourcebot/web openapi:generateis not affected (the openapi file already documents all of this).
- 主要语言
- TypeScript
- 星标
- 3.9k
- 派生
- 374
- 平均合并
- 21 小时 18 分钟
- 30 天内合并 PR
- 39
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
sourcebot-dev/sourcebot 的其他 Issue
-
bug triage needed
难度 2/5 1-3 小时 新手友好度 84/100
sourcebot-dev/sourcebot#1681 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 84/100
sourcebot-dev/sourcebot#1633 ·
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
sourcebot-dev/sourcebot#1384 · 4 条评论 ·
-
ask_sb bug
难度 2/5 1-3 小时 新手友好度 76/100
sourcebot-dev/sourcebot#1137 · 4 条评论 ·
-
bug triage needed
难度 3/5 1-2 天 新手友好度 48/100
sourcebot-dev/sourcebot#1661 · 1 条评论 ·
查看 sourcebot-dev/sourcebot 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 75/100
vercel-labs/just-bash#464 ·
-
looksLikeSlug() is ASCII-only, so non-Latin entity slugs (e.g. Korean) skip exact match and collapse 未关闭
难度 2/5 1-3 小时 新手友好度 75/100
-
难度 2/5 1-3 小时 新手友好度 65/100
-
难度 2/5 1-3 小时 新手友好度 65/100
-
难度 1/5 1 小时以内 新手友好度 90/100
TanStack/tanstack.com#1293 ·