Skip to content

Count freebuff premium sessions by Pacific day#598

Merged
jahooma merged 1 commit intomainfrom
jahooma/freebuff-daily-premium
May 5, 2026
Merged

Count freebuff premium sessions by Pacific day#598
jahooma merged 1 commit intomainfrom
jahooma/freebuff-daily-premium

Conversation

@jahooma
Copy link
Copy Markdown
Contributor

@jahooma jahooma commented May 5, 2026

Summary

Freebuff premium-session usage now counts from the most recent midnight in America/Los_Angeles instead of a rolling 20-hour window, so the user-facing quota resets daily on Pacific time.
This also adds shared zoned-day helpers, updates the rate-limit payload with explicit reset metadata, refreshes CLI/docs copy, and keeps deprecated windowHours compatibility for older clients.

Validation

Ran bun test common/src/util/__tests__/zoned-time.test.ts common/src/__tests__/freebuff-models.test.ts web/src/server/free-session/__tests__/public-api.test.ts, package typechecks for common, web, cli, and packages/internal, plus git diff --check.

@jahooma jahooma merged commit 2ac2b09 into main May 5, 2026
35 checks passed
@jahooma jahooma deleted the jahooma/freebuff-daily-premium branch May 5, 2026 23:11
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