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

Creating multiple plan subscriptions #816

Closed
gavinvaske opened this issue Apr 5, 2019 · 2 comments
Closed

Creating multiple plan subscriptions #816

gavinvaske opened this issue Apr 5, 2019 · 2 comments
Labels
💡 enhancement Ideas and suggestions
Milestone

Comments

@gavinvaske
Copy link

Versions: - Craft CMS (3.1.21) - Craft Commerce (2.1.2) - Stripe for Craft Commerce (1.2.0)

Problem:

  • My website offers user's ability to subscribe to several subscriptions at the same time. Currently, I have created products that represent each subscription so they may be added to the cart. These products are purchased like a regular 'purchasable' element.

My plugin listens to the event EVENT_AFTER_COMPLETE_ORDER and finds all subscriptions that were in the completed order. I could create each subscription individually using Craft's createSubscription() method found in craft\commerce\services, but doing so causes multiple invoices to be sent out to customers and each invoice created is also charged a fee by Stripe.

My Goal is to create one subscription that contains several subscriptions inside of it (https://stripe.com/docs/billing/subscriptions/multiplan). This would only generate one invoice.

I am able to use the Stripe API to do this successfully but at the cost of bypassing Craft. Is there a way to do this through Craft so it knows about all subscriptions that have been created?

@andris-sevcenko
Copy link
Contributor

@gvwarrior Unfortunately, not at the time. Subscription plans as purchasables that can be added to the cart is on the list and as soon as that happens, you'll be able to do this.

@lukeholder lukeholder added the 💡 enhancement Ideas and suggestions label Jul 3, 2019
@lukeholder lukeholder added this to the 3.0 milestone Oct 11, 2019
@lukeholder
Copy link
Member

Please see #625

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💡 enhancement Ideas and suggestions
Projects
None yet
Development

No branches or pull requests

3 participants