Skip to content

feat: add QueryTeamUsageStatsAsync API for multi-tenant metrics#198

Merged
daksh-r merged 3 commits into
masterfrom
feat/add-query-team-usage-stats-api
Feb 16, 2026
Merged

feat: add QueryTeamUsageStatsAsync API for multi-tenant metrics#198
daksh-r merged 3 commits into
masterfrom
feat/add-query-team-usage-stats-api

Conversation

@daksh-r
Copy link
Copy Markdown
Contributor

@daksh-r daksh-r commented Feb 16, 2026

Add IStatsClient with QueryTeamUsageStatsAsync method for querying team-level usage statistics from the warehouse database.

  • New TeamUsageStats model with all 16 metrics
  • Returns metrics grouped by team with cursor-based pagination
  • Supports monthly aggregation (Month) or daily breakdown (StartDate/EndDate)
  • Includes comprehensive test coverage

Submit a pull request

CLA

  • I have signed the Stream CLA (required).
  • The code changes follow best practices
  • Code changes are tested (add some information if not applicable)
  • Commit message fits conventional commits. Important for CHANGELOG generation.

Description of the pull request

Daksh and others added 2 commits February 16, 2026 10:11
Add IStatsClient with QueryTeamUsageStatsAsync method for querying
team-level usage statistics from the warehouse database.

- New TeamUsageStats model with all 16 metrics
- Returns metrics grouped by team with cursor-based pagination
- Supports monthly aggregation (Month) or daily breakdown (StartDate/EndDate)
- Includes comprehensive test coverage

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@daksh-r daksh-r marked this pull request as ready for review February 16, 2026 09:41
slavabobik
slavabobik previously approved these changes Feb 16, 2026
The API now returns 'queued' as a valid import state, which was causing
deserialization failures in TestImportsEnd2EndAsync.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@daksh-r daksh-r merged commit 47006b9 into master Feb 16, 2026
2 checks passed
@daksh-r daksh-r deleted the feat/add-query-team-usage-stats-api branch February 16, 2026 09:56
@github-actions github-actions Bot mentioned this pull request Feb 16, 2026
@github-actions github-actions Bot mentioned this pull request Feb 27, 2026
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.

2 participants