Skip to content
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

Feature request: billable Add-ons #19526

Open
1 task done
torronen opened this issue Apr 13, 2024 · 6 comments
Open
1 task done

Feature request: billable Add-ons #19526

torronen opened this issue Apr 13, 2024 · 6 comments

Comments

@torronen
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Is your feature request related to a problem? Please describe the problem.

I am trying to sell additional add-ons, such as extra user, additional storage, feature A,b,c, but currently I am limited in creating a set of predefined plans.

Describe the solution you'd like

I would like to see an option create "add-ons" in additions to plans. The add-ons would typically allow access to a specific module. I think the only difference is selling additional user licenses. Especially the number of user seats should be a common need I believe.

In some future version the "add-on" might override or increase the limit of settings in the plan. However, I think this could be considered separately.

Additional context

No response

@torronen torronen changed the title Feature request: Add-ons' Feature request: billable Add-ons Apr 13, 2024
@maliming
Copy link
Member

@torronen
Copy link
Author

torronen commented Apr 13, 2024

Thx, I will re-read the docs carefully. However, as I understand it might not be possible. I might missunderstand something.

Example of I what I'd like to implement:

SELECT YOUR PLAN:
Edition A: cloud storage, 1 gb, free, only web
Edition B: cloud storeage, 1 gb, free, windows + mac app, $1 /month
Edition c: cloud storeage, 10 gb, free, windows + mac app, $5/ month

SELECT ADD-ONS:
[ ] Mobile support add +$1/month
[ ] +5gb, +$1/month
[ ] data encryption, +$1/month
[ ] monthly backup, +$1/month
[ ] weekly backup, +$5/month
[ ] daily backup, +$10/month
[ ] realtime virus scanner, +$1/month
[1...99] additional user, +$1/month/user
etc.

If I would use Edition I would need to make editions for all these combinations of base plan + different sets of add-ons. Is that correct? I think additionally, maybe, could be to dynamically create editions. For example Edition_Tenant123 that is based on based edition A + 3 additional users + data encryption. But, the problem I see is what if the base edition gets new features or old ones are removed?

I know many apps only have plans like: free,plus,pro,enterprise, but in my case I have lots of features that cost money to produce so the plans would be expensive if pro plan must include all of them. In the above example, ideally user could even take free base plan and add just monthly backups+encryption for a small amount some important files, but he does not need lots of storage of Edition C

@maliming
Copy link
Member

hi

An Edition is a set of features. So you add an Edition and some features(ADD-ONS) to a tenant.

The framework will only check if the tenant has a feature.

Edition A: cloud storage, 1 gb, free, only web
Edition B: cloud storeage, 1 gb, free, windows + mac app, $1 /month
Edition c: cloud storeage, 10 gb, free, windows + mac app, $5/ month

SELECT ADD-ONS:
[ ] Mobile support add +$1/month
[ ] +5gb, +$1/month
[ ] data encryption, +$1/month
[ ] monthly backup, +$1/month
[ ] weekly backup, +$5/month
[ ] daily backup, +$10/month
[ ] realtime virus scanner, +$1/month
[1...99] additional user, +$1/month/user

@torronen
Copy link
Author

Alright, got it. I will double-check this approach and close or add comment soon. Do you have hints on where to look to update the billing and price per addon? I just add directly to stripe?

@maliming
Copy link
Member

hi

I'm not familiar with where to look to update the billing and price per addon.

But we do have a payment module.

https://docs.abp.io/en/commercial/latest/modules/payment

@AhmadAlMunajjed
Copy link
Contributor

Hi @torronen,

Abp provides a dynamic features system supported by value providers.
There are pre-defined providers default, edition and tenant, and you can define your own provider.

To achieve the use case you mentioned, you can implement it yourself by using edition and tenant providers and no need to define a new provider.

You need to use edition provider value for plan/edition and tenant value for add-on.
Each add-on should have a feature name and value, to know how to set tenant feature value based on it.

My approach of implementing it:

  1. Create a plan
  2. Set plan features featureManager.SetForEditionAsync(editionId, featureName, featureValue)
  3. Once a user selects a plan, you need only to set claim value AbpClaimTypes.EditionId with selected plan/edition Id
  4. Once a user selects an add-on, set feature value for tenant like this featureManager.SetForTenantAsync(tenantId, featureName, featureValue)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants