#NotP_Dot

1 messages ยท Page 1 of 1 (latest)

gleaming mulchBOT
normal furnace
craggy pawn
#

ahh okay

#

by any change is there a way to perform the following - create a subscription with a one time payment. But that one time payment could be any cost and not necessarily a pre defined product

normal furnace
#

hmmm, so you have two items - item #1 is a one time payment, item #2 is the recurring payment?

craggy pawn
#

they're technically the same product with two prices. One for the initial payment, and after that a subscription that gets charged per month

#

the product is a certification course, a user pays a one time fee for the certification course of 100 dollars and after that a 10 dollars fee per month for access to the learning platform and some fees

#

sorry if its a bit confusing

normal furnace
#

just to make sure i understand this correctly, to illustrate this with an example : Sep 1 - i pay the one time fee, Oct 1 (and every month henceforth) - i pay the $10 fee?

craggy pawn
#

yes

#

but the one time fee could vary depending on the product. The subscription fee every month is the same $10 dollars

normal furnace
#

but you do have a fixed price for the one time fee right (although it may differ based on the product)? It's not that the customer decides how much they want to pay

craggy pawn
#

yes its a fixed price for the one time fee

#

I just didn't wanna keep track of strip price Ids in a external db

#

to pass in the add_invoice_items

#

for stripe.Subscription.create

normal furnace
#

you can schedule it such that the customer pays $x for month 1, then update the subscription to pay $y for subsequent months

craggy pawn
#

would I not have to create priceIds still?

#

apologies for the many questions, just wanna understand the best approach for this

normal furnace
#

you don't have to pre-define Prices

#

but you still have to pre-define the Product at least

craggy pawn
#

yeah I have a list of the products in my db.

normal furnace
craggy pawn
#

Thank you for that

#

I understand the schedule with phases but what would I use to charge them for the initial payment. I am a bit confused in terms of the steps

#

does stripe.SubscriptionSchedule.create not require the subscription to be already created?

normal furnace
#

it doesn't require the subscription to already be created. You can create a subscription first, then create a Subscription Schedule to manage it, and update the phases in the Subscription Schedule. Or alternatively just create the Subscription Schedule

craggy pawn
#

Can you let me know if these steps are what you'd do

1- create stripe.SubscriptionSchedule.create
2- create phase 1 for the one time payment
3 - create phase 2 for the subscription every month

normal furnace
#

how are you planning to collect the payment method details from your user - are you using Stripe Checkout or a Payment Element? that might help decide whether to create a subscription first

craggy pawn
#

at the moment via stripe elements from the frontend if that's the answer you're looking for

#

I think the big issue that I am running into is if the user purchases multiple products

product 1 = course = one time fee + monthly subscription
product 2 = course tshirt = one time fee

combining these two products and create a single payment is my biggest issue lol

normal furnace
#

i don't really see a problem though, like you mentioned before, you can use add_invoice_items

craggy pawn
#

yeah that's my goal but I realized add_invoice_items requires pre created priceIds from stripe

normal furnace
#

but it doesn't? you can pass in the details here : add_invoice_items.price_data

#

to generate a Price inline, instead of passing in a Price id

craggy pawn
#

you can ? I though it was more of add_invoice_items=[{"price": 'price_1LkxfpxxxxxxxxxxxdsMuC8oH6O'}],

normal furnace
#

why don't you test it out, it'd be easier for you to understand

craggy pawn
#

yes, apologies for the questions I can simply test out

#

Thank you for your much help Alex

normal furnace
#

nono, i'm happy to answer your questions, you just seemed a bit confused over how it works. And sometimes i find the best way to go about things is to just test it out

craggy pawn
#

you're absolutely right. just a bit new to Stripe and picking up where old developers left off lo l

normal furnace
#

maaaan, that's difficult

#

going back to another question - whether to create the Subscription Schedule, or create a Subscription then create the Subscription Schedule from the Subscription

#

i think it would be better to create the Subscription first, then pay for that, and create a Subscription Schedule from the Subscription

craggy pawn
#

yeah I'll take your recommendation on that.

#

Appreciate all your help.

normal furnace
#

the reason being that when you create a Subscription Schedule, the Subscription is already active, even if you haven't collected payment for the first invoice yet

craggy pawn
#

yeah I think I set up something similar last week with Installments.

normal furnace
#

i would assume, you want to customer to first pay, before you consider the subscription as active for the scenario we're talking about currently

#

so yep! feel free to reach out if you have any other questions ๐Ÿ˜„