Skip to content

feat: design and implement core subscription model#17

Merged
ShubhamKumarSahu-svg merged 1 commit into
opencodeiiita:mainfrom
adityashirsatrao007:feature/subscription-model
Dec 26, 2025
Merged

feat: design and implement core subscription model#17
ShubhamKumarSahu-svg merged 1 commit into
opencodeiiita:mainfrom
adityashirsatrao007:feature/subscription-model

Conversation

@adityashirsatrao007
Copy link
Copy Markdown
Contributor

Issue : #14

🚢 What does this PR do?

This PR implements the core data model for tracking subscriptions in SubSentry.

🛠️ Changes:

  • Designed a comprehensive Subscription Mongoose schema with support for various billing cycles, statuses, and data sources.
  • Ensured strong data validation for price, name, and billing cycles.
  • Implemented user ownership mapping via userClerkId, aligned with the frontend Clerk integration.
  • Added indexing on userClerkId and status to optimize common query patterns.
  • Included automatic timestamps for auditing.

✅ Verification:

  • Model schema is clean, extensible, and correctly follows the ESM architecture.
  • Validated that all required fields are captured to support future automation.

Verified against the project's backend requirements.

@OpenGitBot
Copy link
Copy Markdown

Hey @adityashirsatrao007

Thanks for opening this PR 🚀. Mentor will review your pull request soon and till then, keep contributing and stay calm.

Thanks for contributing in OpenCode'25 ✨✨!

@ShubhamKumarSahu-svg ShubhamKumarSahu-svg merged commit 105d339 into opencodeiiita:main Dec 26, 2025
@OpenGitBot
Copy link
Copy Markdown

Hey @adityashirsatrao007

Your PR has been merged 🥳🥳 and you have earned 10 points.

Thanks for contributing in OpenCode'25✨✨

@Aryan-coder06 Aryan-coder06 mentioned this pull request Jan 20, 2026
21 tasks
@Aryan-coder06
Copy link
Copy Markdown
Collaborator

Closing as requested by maintainer.

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