nhi: GitLab class-B — project/group access-token syncers (Phase-1, M-scope)#91
Open
c1-squire-dev[bot] wants to merge 1 commit into
Conversation
c1-squire-dev
Bot
force-pushed
the
paul.querna/nhi-gitlab-class-b/m-scope
branch
3 times, most recently
from
June 10, 2026 17:46
6673039 to
1be85b4
Compare
…scope) Adds the per-parent-fan-out access-token syncers (pqprime NHI Phase-1, RFC §5.8.1 — class B), stacked on the S-scope PR: - project_access_token (K1 / STATIC_SECRET, axis-2 gitlab.token.project_access) GET /projects/:id/access_tokens, fanned out per project. - group_access_token (K1 / STATIC_SECRET, axis-2 gitlab.token.group_access) GET /groups/:id/access_tokens, fanned out per group (incl. subgroups). Each access token is backed by a per-resource bot user; that user_id is emitted as the SecretTrait identity back-reference. Fan-out is wired via ChildResourceType annotations on the project and group resources. Co-authored-by: c1-squire-dev[bot] <c1-squire-dev[bot]@users.noreply.github.com>
c1-squire-dev
Bot
force-pushed
the
paul.querna/nhi-gitlab-class-b/m-scope
branch
from
June 10, 2026 17:52
1be85b4 to
f7aaaf6
Compare
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.
🔗 Preview: C1
nhi: GitLab class-B — project / group access-token syncers (Phase-1, M-scope)
Part of the pqprime NHI program (RFC
plans/nhi/rfc/rfc-v6.md). This is the M-scope half of the GitLab class-B work, stacked on #90 (S-scope). Merge #90 first; this PR's base is the S-scope branch.What this PR adds (RFC §5.8.1, class B)
project_access_tokengitlab.token.project_accessGET /projects/:id/access_tokens— per-project; metadata only, backed by a per-project bot usergroup_access_tokengitlab.token.group_accessGET /groups/:id/access_tokens— per-group; metadata only, backed by a per-group bot userThese are the new-syncer (M) cases: per-parent fan-out rather than a single list call. Fan-out is wired by adding
ChildResourceTypeannotations to the existing project and group resources, so the SDK invokes each token builder once per project / per group (group access tokens exist on subgroups too, so the annotation is emitted on every group).SecretTraitstampedcredential_type = STATIC_SECRET+ axis-2credential_detail.user_id, which is set asSecretTrait.identity_id(K1↔K2 link).RFC rule compliance
credential_typeonly ever set toSTATIC_SECRET.V1Identifier; no reserved slots; axis-2 strings follow<platform>.<object>.<purpose>(§2.8).Testing
go build ./...,go test ./...,golangci-lint run,gofmt— all green.🤖 Built with pqprime
Exposed endpoints
🏰 Squire environment: sleepy-dolphin-46579
Task: d94ceb36-4399-49c3-a3fd-977c87ce323b