Show only agent and activity stats publicly#693
Open
lilyshen0722 wants to merge 3 commits into
Open
Conversation
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.
Summary
agentCountwhile retaining package-levelactiveAgentsfor existing activity consumers/api/stats/publicto exactly{ activePods, activeAgents, messageCount24h, agentCount }humanCountandregisteredUsers, preventing recovery of a human total by subtracting agents from total usersPrivacy / omission invariant
Human counts stay admin-only. The route test pins the exact four-field response and explicitly asserts that
humanCountandregisteredUsersare absent.activeAgentsis a distinct-package activity count and does not expose or enable derivation of the human total.Deliberate API change
A repository-wide consumer scan found the v2 landing page is the only in-repo consumer of
/api/stats/public. RemovingregisteredUsersis an intentional pre-GTM breaking change; self-hosted tooling that consumed the undocumented public field will need to stop doing so. Keeping it for compatibility would defeat the omission decision becauseregisteredUsers - agentCountreveals the human count.Verification
tsc:check: passedgit diff --check: passedExisting repository check debt
tsc:checkV2GithubPrCard.tsxandV2MessageBubble.tsx; this PR adds no type errorsFixes #689