Skip to content

fix: remove token requirement from /v3/stats - #581

Merged
jacoby149 merged 2 commits into
devfrom
jacoby149/fix-missing-token-in-node-stats
Aug 12, 2026
Merged

fix: remove token requirement from /v3/stats#581
jacoby149 merged 2 commits into
devfrom
jacoby149/fix-missing-token-in-node-stats

Conversation

@jacoby149

Copy link
Copy Markdown
Owner

Problem

POST /v3/stats returns 422: Field required for token when called without a token.

Root Cause

The node_stats endpoint required TokenOnly (a JWT token) but never used it — it just calls ch.get_node_stats() which reads public ClickHouse counts. Marketing-ui sends empty body (pre-signup, no auth).

Fix

Removed the TokenOnly body parameter. The endpoint returns public stats (user count, doc count, group count, approved apps, storage) — no sensitive data requires auth.

The node_stats endpoint requires TokenOnly but never uses the token,
just calls ch.get_node_stats() which reads public ClickHouse counts.
Marketing-ui sends empty body (pre-signup, no auth) which caused 422.
@jacoby149
jacoby149 merged commit f9772a4 into dev Aug 12, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant