Repository navigation
feat(plugin-auth): a SCIM Credentials Setup entry while SCIM is wired - #31222
Conversation
…IM is wired plugin-auth now adds nav_scim_credentials beside SSO Providers in Setup > Access Control, opening sys_scim_connection_credential where the console's mint and revoke actions live. It is gated on authManager.isScimWired(), the answer the mint door reads before refusing 503, and on the SSO entry's manage_platform_settings permission. The label is translated in the six Setup bundles and listed as a conditional nav id. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FEkQ5kkU448zCPf5uHdBMT
📓 Docs Drift CheckThis PR changes 2 package(s): 19 hand-written doc(s) name something this change touched — list omitted above 15 rows. Re-derive on the tree named below: ⛔ 12 release-owned page(s) also affected — read-only, see AGENTS.md Documentation Guardrails. What this run could not see
Coarse fallback — 24 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): Which tree this was computed onThis run read A worktree cut from an older # while this PR is open — GitHub drops the merge commit once it closes
git fetch origin 533b8ea7c01b715dc55fe7a8e8933f31e1702775 && git checkout 533b8ea7c01b715dc55fe7a8e8933f31e1702775
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin 66bf5b4a019c62f50ed1824b35fe6ba345cf51e3 bb431ed483d207c4fcc7c47c408f9ffec60b756f && git checkout -B drift-repro 66bf5b4a019c62f50ed1824b35fe6ba345cf51e3 && git merge --no-ff bb431ed483d207c4fcc7c47c408f9ffec60b756f
node scripts/docs-audit/affected-docs.mjs --json 66bf5b4a019c62f50ed1824b35fe6ba345cf51e3
|
|
domain:server#6 · os-project-manager · session_01FEkQ5p3T5YWhLjurajudnQ Contract reviewServed-tier: Inputs read: card #31123 body and all five comments (triage 6707834647, unblock 6709671988, claim 6710611889, dev report 6711222599, claim amendment 6711236424); PR #31222 body and its 15-file list; the net diff ① Derived judgments
② Semver level
③ Boundary flags
Gates (the head's check-runs, as read): 14 success, 13 skipped (UI / docs / opt-in lanes not triggered by this path set), 18 in progress, 0 failed. Green so far: Check Changeset; Governed Surface Queue Guard; PR-body guards (claim · duplicate · Part-of · single-writer path); Lint · PM dispatch-gates; Lint · repo & tooling gates; Lint · scoped · tooling self-tests; Type Check · source gates; Dogfood Regression Gate; Test UI; Check PR Size; Plan Test Core shards; Auto Label; Flag docs affected by code changes; filter. Still running when read: Build Core, Test Core 1-8 of 8, Type Check (workspace, consumer gates, debt ledger), Lint (ESLint, CI release & engine gates, docs & code guards, scoped query-options erasure, scoped slot lookup & corpus), Live E2E UI. This verdict is on the contract; landing still waits for those to finish green. Must-fix: none. Implemented-by: VERDICT: PASS |
|
domain:server#6 · os-project-manager · session_01FEkQ5p3T5YWhLjurajudnQ 席位核对 · ACCEPT · 2026-11-07T18:45Z · head
|
Requested by Leehom · project thread
Fixes #31123
Clause-②: yes (widening)
Metadata-protocol: none
维护者速读
packages/plugins/plugin-auth/src/auth-plugin.ts(菜单项与开关,复用签发接口的同一个 SCIM 判定);packages/plugins/plugin-auth/src/scim-credentials-setup-nav.test.ts;packages/platform-objects/src/apps/translations/en.ts。pnpm --filter @objectstack/plugin-auth exec vitest run src/scim-credentials-setup-nav.test.ts,预期 6 个用例全绿(开 SCIM 有入口、关 SCIM 无入口)。What changes
isSsoWired()). A new itemnav_scim_credentials, "SCIM Credentials", openssys_scim_connection_credential(the object PR feat(platform-objects): mint and revoke SCIM connection credentials from the console #31119's Mint / Revoke Credential actions live on), with iconkey-roundand the SSO entry's gate,requiredPermissions: ['manage_platform_settings']. It is contributed only whilethis.authManager.isScimWired()is true. That is the method the/admin/scim/mint-credentialdoor'sisScimEnableddep calls before it refuses 503, so there is one spelling of "SCIM wired" and the menu cannot show an entry whose Mint button can only fail. The routes keep their own platform-admin gate, so the entry widens nothing.navigationContributionsfrom plugin-auth, as before. Both items share the one existing contribution (groupgroup_access_control, priority 250); SCIM sorts after SSO.apps.setup.navigation.nav_scim_credentialsin all six Setup bundles (en "SCIM Credentials", zh-CN "SCIM 凭据", ja-JP "SCIM 資格情報", es-ES "Credenciales SCIM", zh-Hant "SCIM 憑證", ar "بيانات اعتماد SCIM"), each the short form of the object's own translatedpluralLabel. The five non-English locales record the en source hash (2d94a32c33ca2957) so a later source edit marks them stale. The id joinsCONDITIONAL_SETUP_NAV_IDSinsetup-nav-dead-key-tombstone.test.ts, becausecheck:app-nav-i18nboots one composition and never merges a gated-off entry (the same reasonnav_sso_providersis listed there).dist(files: ["dist", …]) and the key is new, soyes (widening); the claim's seat readingnois re-declared as the order asked. Changeset.changeset/31123-scim-credentials-setup-entry.md, patch for both packages.Tests
packages/plugins/plugin-auth/src/scim-credentials-setup-nav.test.tsreads the manifestinit()registers: the entry with SCIM on via config, with SCIM on viaOS_SCIM_ENABLED, absent with SCIM off (and no other entry in its place), absent when the manager'sisScimWired()answers false although the config says on, the SSO + SCIM order, and SSO alone unchanged.origin/main658d84f5: 4 failed, 2 passed (the two absence cases already hold on main).this.authManager.isScimWired()with an always-true marker turned 3 cases red ("is absent when SCIM is not wired…", "asks the manager the same question…", "SSO alone…"), restored with blob == HEAD andgit diff HEADempty. Removing the ja-JP label turned the tombstone pin red (expected [ 'nav_scim_credentials' ] to deeply equal []), restored the same way.Acceptance notes
pluralLabelthe same way English does.nav_sso_providers)" is conditional:packages/cli/scripts/check-app-nav-i18n.mjsheader,packages/cli/test/platform-page-i18n-parity.test.ts,packages/qa/dogfood/test/platform-app-object-entry-views.test.ts. Their reasoning still holds (every plugin-auth nav entry is conditional); only the count is now two. Not edited here.check:app-nav-i18nis not in the derived list and has no reverse direction, so the new bundle key draws no orphan verdict; not run locally.Verification
All local readings are at head
bb431ed4.pnpm --filter @objectstack/plugin-auth test: Test Files 235 passed (235), Tests 4174 passed | 10 skipped (4184).pnpm --filter @objectstack/platform-objects test: Test Files 119 passed (119), Tests 1701 passed (1701).pnpm --filter @objectstack/plugin-auth typecheck(tsc, examples tsconfig,check:test-typecheck) andpnpm --filter @objectstack/platform-objects typecheck: exit 0.eslint --no-inline-config packages/plugins/plugin-auth/src packages/platform-objects/src: exit 0.node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstackgives 68 families; all 68 ran with exit 0.--ranreconciliation: "68 derived, 68 run, 0 NOT-MEASURED, 0 UNRUN".Three gates that first answered exit 3 (prerequisite not met), and their re-runs
node scripts/check-plugin-teardown-shape.mjs --self-testneeded the shallow clone deepened (git fetch --depth=1 origin 621a4876); re-run exit 0, "48 cases pass".pnpm check:dual-build-cjs-loadsandpnpm check:i18nneeded a full build (turbo run build, 120/120 tasks); re-run exit 0: "116 published require entry point(s) across 71 package(s) load" and "check-i18n-bundles: OK (10 package(s) — all bundles in sync, no undeclared authoring keys)".Not run locally, left to CI:
test:repo, the dogfood battery (no!in the title and no(narrowing)arm), andcheck:app-nav-i18n(not derived; see Acceptance notes).🤖 Generated with Claude Code
https://claude.ai/code/session_01FEkQ5kkU448zCPf5uHdBMT
Generated by Claude Code