Skip to content

feat: analytics - #725

Merged
Rishikant181 merged 13 commits into
Rishikant181:devfrom
vachmara:feat/premium-analytics
Jul 1, 2025
Merged

Rishikant181 merged 13 commits into
Rishikant181:devfrom
vachmara:feat/premium-analytics

Conversation

@vachmara

@vachmara vachmara commented Jun 29, 2025 •

Copy link
Copy Markdown
Contributor

Summary

This PR adds user analytics support with a new Analytics model, API endpoint, service method, updated types, and expanded enums for Premium X users. Related to #613

Key changes:

  • New Analytics class for metrics and processing
  • Extractor for analytics responses
  • API endpoint and service method refactor to fetch analytics
  • Update metrics in RawAnalyticsMetric enum
  • Type updates for analytics data and responses
  • Added USER_ANALYTICS resource type and new fetch args

To do:

  • End-to-end tests for user analytics workflow
  • Test doc generation and type-safe
  • Update Readme

@vachmara

vachmara commented Jun 30, 2025 •

Copy link
Copy Markdown
Contributor Author

All good, if you want to take a look @Rishikant181

@Rishikant181

Copy link
Copy Markdown
Owner

Taking a look at it now

@Rishikant181

Copy link
Copy Markdown
Owner

@vachmara I don't have a premium account so I can't test the functionality, however, if you have tested the functionality, I'll just review the code and merge it

@Rishikant181 Rishikant181 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Please run the following to lint and format code, and fix any issues in the process:

  • npm run lint
  • npm run format

Except these, it seems alright. I'll merge it once the requested changes are done

Comment thread src/models/data/Analytics.ts Resolved
@vachmara

vachmara commented Jul 1, 2025

Copy link
Copy Markdown
Contributor Author

@vachmara I don't have a premium account so I can't test the functionality, however, if you have tested the functionality, I'll just review the code and merge it

Yes, it's a bit unfortunate.

I’ll lint and format to fix and add the raw getter as requested!

That said, I have a few ideas to improve the development experience:

  1. Add a playground to test and debug features more easily
  2. Set up proper bundling and add tests (e.g., Vite, Vitest)
  3. Implement CI/CD for linting and formatting checks

Let me know if you'd like me to open issues to work on one of these.

@vachmara

vachmara commented Jul 1, 2025

Copy link
Copy Markdown
Contributor Author

should be all good now

@Rishikant181
Rishikant181 merged commit 6e6df79 into Rishikant181:dev Jul 1, 2025
@vachmara
vachmara deleted the feat/premium-analytics branch July 1, 2025 15: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.

2 participants