chore: remove obsolete /api/modelstats endpoint#2740
Merged
chrarnoldus merged 1 commit intomainfrom Apr 24, 2026
Merged
Conversation
This endpoint is only consumed by the legacy kilocode-legacy extension (KiloModelInfoView.tsx). That code path wraps the fetch in try/catch, reports the error via telemetry, and renders without pricing stats when the request fails, so removal degrades gracefully.
Contributor
Author
Code Review SummaryStatus: 1 Issue Found | Recommendation: Address before merge Overview
Fix these issues in Kilo Cloud Issue Details (click to expand)WARNING
Other Observations (not in diff)No additional observations. Files Reviewed (1 files)
Reviewed by gpt-5.4-20260305 · 143,421 tokens |
markijbema
approved these changes
Apr 23, 2026
This was referenced Apr 23, 2026
catgirl3d
pushed a commit
to catgirl3d/kilocode-legacy-p
that referenced
this pull request
Apr 23, 2026
The /api/modelstats endpoint is being removed from the cloud backend (Kilo-Org/cloud#2740). This drops the now-dead fetch and the unused averageKiloCodeCost translation strings.
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
apps/web/src/app/api/modelstats/route.ts, a hardcoded JSON endpoint that is no longer consumed by any current client.Kilo-Org/kilocode-legacy) inwebview-ui/src/components/kilocode/settings/KiloModelInfoView.tsx.Verification
cloudrepo for any reference tomodelstats: none remain after this deletion.data: undefined, and the component readsmodelStats?.find(...)with optional chaining, so the pricing row simply doesn't render. The rest ofKiloModelInfoView(description, supports flags, context window, max output) is unaffected. Failure is graceful.Visual Changes
N/A
Reviewer Notes
If we still want to keep the legacy extension functional indefinitely, we could leave an empty-array stub instead — but the existing fallback already handles a 404 without user-visible breakage.