#mtoledo2

1 messages ยท Page 1 of 1 (latest)

rough boneBOT
obsidian salmon
#

Hi ๐Ÿ‘‹

I think you can do that. Have you tested anything yourself?

polar patio
#

From the UI it doesn't allow me but curious if through the API there is a difference, I suspect not but have found there are things you can do through API that cannot be done through UI

obsidian salmon
#

You can test this yourself pretty quickly using Test mode API keys.

polar patio
#

Yeah, should've done that, let me do that and report back

obsidian salmon
#

Thanks!

polar patio
#

FYI, it's not supported

{
    "error": {
        "message": "Checkout does not support multiple prices with different billing intervals.",
        "type": "invalid_request_error"
    }
}
#

I wonder if this is because of the invoice model and just can't have 2 different invoices with different cadences

obsidian salmon
#

Okay I think the issue is it's trying to create a single subscription with multiple prices

#

And the Subscription model needs to have a single billing cycle associated with it

polar patio
#

I see. So solution here is basically to have essentially 2 different payments for each subscription.

Any workarounds you can think of to only have 1 transaction? Hoping to not have 2 transactions on a user's statement when they initially purchase.

Ideally have a single invoice/charge for the first purchase

obsidian salmon
#

But you want to have 2 separate billing cadences?

polar patio
#

Correct

#

My mental model is if I'm at a cash register I wouldn't swipe my card twice for 2 things that I'm buying even if they're different cadences

obsidian salmon
#

I can see that but it isn't how Subscriptions are designed in Stripe. You can do it like this but it would be tricky

#

Here is how I would square that circle

#
  1. create one subscription with one cadence - generates an initial invoice
  2. create second subscription with different cadence - generates an initial invoice.
  3. Create a separate payment intent for an amount that covers both initial prices.
  4. mark each invoice for the subscription as Paid with the paid_out_of_band parameter set to true
polar patio
#

Ok, awesome thanks! Agreed it's tricky and might not be worth the hassle but wanted to understand how it can be done to be able to make that decision

obsidian salmon
#

Happy to shed what ๐Ÿ’ก I can ๐Ÿ™‚

This approach does mean you will need to track the association between the initial payment and the subscriptions yourself. I recommend putting that info in the metadata of the Payment Intent in step 3