Skip to content

feat(projected-usage): add projected usage data to the current usage endpoint #3905

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 46 commits into from
Aug 4, 2025

Conversation

murparreira
Copy link
Contributor

Context

We offer a endpoint and a UI for the current usage of the customers of our users. They can see in real time the consumption of each feature for the current period. However, there is no way to calculate the projected usage. So we need to add this feature on our platform.
Here is the spec document.
Here is the dive in document.

Description

There are many changes in this PR:

  • Add a service for calculating projected usage data based on the fees and the boundary dates.
  • Change the serializer for the API to use this new service to calculate the projected usage values added to the response.
  • Change the graphql types to use this new service to calculate the projected usage values added to the response.
  • Made several specs to test the behavior and modified existing ones, because there were changes to an existing endpoint.

Copy link
Collaborator

@vincent-pochet vincent-pochet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

Few comments but no blockers

@murparreira murparreira merged commit 6bd69d8 into main Aug 4, 2025
14 checks passed
@murparreira murparreira deleted the feat/projected-usage branch August 4, 2025 14:34
jdenquin added a commit that referenced this pull request Aug 15, 2025
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.

4 participants