#Talon-checkout-payment

1 messages · Page 1 of 1 (latest)

stuck silo
stone citrus
#

Hey there, bear with me one moment while I double-check some of our options for this scenario.

#

Just to clarify, when you say that you're using the ready made checkout page, are you referring to creating checkout sessions? Or another feature such as payment links?

tender kindle
#

stripe hosted page

#

stripe.checkout.Session.create

#

lemme know if it's possible

stone citrus
#

One option is to look at using a coupon to discount the first month's price. Are you hoping to discount the first month's price for all of your customers?

outer sundial
#

Depending on what you mean by "edit the price for the first month" you'll likely find Promo codes to be a good experience here

tender kindle
#

we offer instalment packages but first month is like a deposit

#

so it has different price

#

client need to pay 100$ for the first month and after price is normal that is 50$

outer sundial
#

so you'd have you 50/mo subscription and a one-time $50 "setup fee" or similar

tender kindle
#

awesome

#

so in my line item, I need to add Price id of my subscription and also price id of one time payment

outer sundial
#

yep, exactly

#

well, in two separate line items, but yes

tender kindle
#
checkout_session = stripe.checkout.Session.create(
                success_url= {{success page}},
                cancel_url= {{Fail page}},
                payment_method_types=['card'],
                mode='subscription',
                customer_email=request.user.email,
                line_items=[{
                    'price': request.data['price_id'],
                    'quantity': 1,
                    'tax_rates': ['txr_1Ivfm9F9Zo1nikLipHNgUMRy']
                }],
 line_items=[{
                    'price': request.data['price_id'],
                    'quantity': 1,
                    'tax_rates': ['txr_1Ivfm9F9Zo1nikLipHNgUMRy']
                }]
            )
#

like this? 2 time line_items list?

outer sundial
#

not two lists, two elements of the list

tender kindle
#

so a new dict

#

i got it now

outer sundial
#

line_items=[{...}, {...}]

tender kindle
#

yup

#

and is it possible to hard code the amount instead of providing the price ID for that one time payment

stone citrus
#

Yup, instead of using the price parameter, you can leverage the price_data one.