Repository navigation
docs(api-reference): daily api-review 2026-11-10 — exchange calendars, team assignment, RUM crash-beacon knobs - #1177
Open
flashduty[bot] wants to merge 2 commits into
Open
flashduty[bot] wants to merge 2 commits into
flashduty[bot] wants to merge 2 commits into
Conversation
added 2 commits
November 10, 2026 08:12
…, team assignment, RUM crash beacon Audit window 2026-11-09T09:16:29Z → 2026-11-10T08:12Z. On-call calendars (fc-pgy feat/exchange-calendar, merged 8e09b643): - CalendarListRequest.kind / CalendarItem.kind gain `exchange.holiday`. - CalEventItem.day_end and CalDay.day_end document the early-close wall clock. - extra_cal_ids: at most one exchange calendar, and linking one sets `timezone`. - calendar/create usage: the per-account cap is 20, not 5. On-call incidents (fc-event feat/manual-incident-notify, merged 5da74c6de): - AssignedTo.team_ids and CreateIncidentRequest.assigned_to.team_ids (1–20). - AddIncidentResponderRequest: person_ids no longer required, maxItems 100, new team_ids. - assigned_to.notify.template_id must exist in the account. RUM remote config (fc-rum feat/crash-ledger-main, merged 49ec5df): - RemoteConfigValues gains crashBeaconEnabled and crashBeaconTimeoutMs (500–2000). No paths added or removed, so docs.json and api-catalog.mdx are untouched.
…e calendar timezone fc-event feat/channel-calendar (merged aa61cb096) changed TimeFilter.Check so that a calendar decides the day and the calendar's timezone the wall clock `start`/`end` are read in: a rule on a US trading calendar means New York time wherever the service runs. TimeFilter is used by the escalation-rule and silence-rule request/response bodies. Also says how /calendar/list filters the shared exchange calendars by locale.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
本轮审计
窗口 2026-11-09T09:16:29Z → 2026-11-10T08:12Z(约 23 小时)。两遍扫描都跑了:
git log --since=<窗口起点>的非 merge 提交逐条看git diff <commit>^1 <commit>;git diff <窗口前最后一个提交>..origin/main(忽略 merge 提交的字段虚影)。本轮三处真实漂移中有两处只由 (b) 命中——分支写于窗口之前、合并落在窗口内:fc-pgy
feat/exchange-calendar(merge8e09b643)、fc-eventfeat/manual-incident-notify(merge5da74c6de)。第三处(fc-rumfeat/crash-ledger-main,merge49ec5df)两遍都命中。无 operation 增删,
docs.json与en|zh/openapi/api-catalog.mdx不动。On-call — Calendars(updated,无新增 operation)
CalendarListRequest.kindexchange.holiday,描述补充"共享交易所休市日历"CalendarItem.kindexchange.holiday,并说明其时区即交易所时区CalEventItem.day_endHH:MM)CalDay.day_endCalEventListRequest.cal_idkind=exchange.holiday返回的交易所日历 ID 同样可用CalendarCreateRequest.extra_cal_idsexchange.holiday;关联后timezone跟随交易所并覆盖入参;关联两个返回InvalidParameterCalendarUpdateRequest.extra_cal_idsPOST /calendar/create使用说明POST /calendar/list使用说明region.official.holiday/exchange.holiday)都按调用方 locale 过滤;交易所日历的cal_id可在规则中直接引用证据:
fc-pgy/structs/calendar.go(CalKindExchangeHoliday、CalEventItem.DayEnd、CalDay.DayEnd)、fc-pgy/cmd/server/controller/calendar/calendar.go(listInput.Kind的binding:"oneof=region.official.holiday exchange.holiday personal"、maxCalInOneAccount = 20、linkedTradingCalendar)、fc-pgy/cmd/server/controller/calendar/event.go(calendarOf接受交易所日历 ID)。On-call — Escalation / Silence rules(updated,无新增 operation)
TimeFilter.cal_idstart/end按该日历的时区解读(交易所日历即交易所时区),并说明共享日历 ID 也可直接用证据:
fc-event/structs/channel.go(FnIsDayOff→FnCalDay,TimeFilter.Check里t = t.In(loc),注释放纽约时间语义)、fc-event/logic/incident/assign.go(cL.CalDay),随aa61cb096 Merge pull request #3536 from feat/exchange-calendar落在窗口内。TimeFilter被CreateEscalationRuleRequest、UpdateEscalationRuleRequest、CreateSilenceRuleRequest、UpdateSilenceRuleRequest、EscalateRuleItem、SilenceRuleItem引用,属公共面行为变化。On-call — Incidents(updated,无新增 operation)
AssignedTo.team_idsperson_ids;展开后上限 100;落存不保留(响应不返回)AssignedTo描述team_idsCreateIncidentRequest.assigned_to.team_idsAssignedTo同语义)CreateIncidentRequest.assigned_to.notify.template_idInvalidParameterAddIncidentResponderRequestperson_ids移出required(改为"person_ids与team_ids至少一个")、加maxItems: 100;新增team_ids(最多 20)证据:
fc-event/structs/channel.go(AssignedTo.TeamIDs,binding:"omitempty,gt=0,lte=20")、fc-event/cmd/server/controller/incident/action.go(Create的 notify 校验/默认值、addRspdInput.PersonIDs由required改为omitempty,lte=100、addRspdInput.Validate、createFormAssignValues纳入TeamIDs)、fc-event/logic/incident/assign.go(scopeAssignTargets团队展开 + 100 人上限、resolveResponderPersonIDs、scoped.TeamIDs = nil快照语义)。RUM — Applications(updated,无新增 operation)
RemoteConfigValues.crashBeaconEnabledboolean | nullRemoteConfigValues.crashBeaconTimeoutMsinteger | null,minimum 500/maximum 2000证据:
fc-rum/types/remote_config.go(两个指针字段、Min/MaxCrashBeaconTimeoutMs = 500/2000、Validate的取值校验、Merge、IsEmpty);该结构经/rum/application/remote-config/{get,update,preview,history/*}的config.values出入公共面。removed
无。
不改项与依据
8ae9d4e21、b3b5de47b)——改动全在内部件:cmd/api/runtime/*、logic/session/actor/*、logic/runner/*、logic/runtime/*、types/{steering.go(删除),turn_diagnostics.go,stream.go,drain.go,compact.go}。公共面/safari/session/{get,list,delete,export}的EventItem早已含error_code/error_message/status,PendingUserMessage早已含steering,本轮无新字段可写。RunRequest/UserMessageBody的Steering语义变化是进程内调用协议,不是 app_key 入参。logic/ai_sre/*运行时状态机,无 json/binding 变化。442cc9c(保留 incident ID、ID 冲突重试)——只动model/change、model/structure、model/id_insert_log、types/id.go与唯一约束探测,无字段标签变化,公共 status-page 请求/响应结构不变。a95a480(alert-rule outbox claim 死锁)——加锁顺序修复,无字段变化。6a6da88/11cb98e/e67af7b)——新增内部表t_crash_ledger与 field scopecrash_ledger,但公共 scope 枚举没有扩:/rum/facet/count的oneof仍是session view action error resource long_task vital issue sourcemap(fc-rum/cmd/server/controller/facet/count.go),types/dashboard/validate.go的rumScopes与types/nlquery.go的NLQueryScopes均未变,故不写crashscope。同批新增的launch_time/beacon字段在 Datadog intake 协议(SDK 上报)里,不在 app_key 公共面。/calendar/holiday/list、/calendar/holiday/event/syncregistryauth=none,不在公共面,其day_end校验不写;is-day-off不在 registry。83c2516(IsDayOff 返回时区)——内部 RPC 契约,公共面无对应 operation。unresolved(维持不写入 spec)
POST /channel/incident/daily-countsPOST /change/info/safari/session/masking/*与SessionItem.masking_enabled——registryAuth: "all"、handler 在 main,但fc-safari/etc/masking.yml为enabled: false,属 pre-GA 待产品定,保持 flagged。registry 差集
scripts/parse_pgy_registry.py解析fc-pgy/logic/api/api_test.go共 1262 行,过滤(auth == "all"、非/event/push/、模块未 hidden)得公开面 357 行。按 gin:param↔{param}归一后与 5 个 split 的 paths 求差,spec 缺 8 条,全部是上面的 unresolved 组(daily-counts + change/info + 6 个 masking),没有需要新增的 operation。另需说明:skill 目录下发的
mapping.yaml副本仍是旧的(缺/integration、/route、/oncall/license、/monit/dashboard、/rum/dashboard、/rum/data/query、/rum/field/list、/rum/resource/info、/monit/query/*等前缀),所以这些前缀的 registry 行在差集里表现为"spec 有、registry 无归属"。逐一核对后它们都已在对应 spec 中,与claude-plugins-flashduty#101的 mapping 更新一致,只是本地副本尚未同步——本轮不需要新增或删除 operation。示例
未新增 operation,既有 request/response 示例一律保留未动。本轮未取 dev API 凭据,新增字段均落在既有 schema 上且不要求示例体同步:
team_ids是可选请求字段(响应不含),day_end/crashBeacon*在各自响应示例中可缺省(schema 均非 required)。故无构造示例。校验
json.load通过(12 个*.openapi.*.json+openapi.legacy.zh.json)。python3 scripts/lint_openapi.py→OK: 12 spec files, no violations,exit 0。python3 scripts/api_path_redirects.py --check→ exit 0。DutyError.reason(consolidated 独有)与 safari 的BadRequest/Forbidden示例如名差异,均未触碰。x-mint块逐项比对 shape 一致,只有人类可读文本不同。与开放 PR 的关系
on-call/rum两份 split + 两份 consolidated),但 schema 不相交(RumApplicationItem.active_devices_enabled、/oncall/license/list计数字段、LicensePersonItem.status/via/acquired_at);本轮未重复其内容(那些提交都在窗口起点之前)。两者合并时会在同一文件上产生文本级冲突,需后合并者 rebase。minItems、RUM session summary、session credits)。api-reference/*.json(分别为 doc-review 与 rum 文档),与本轮无冲突。