I use the paymentIntent API this way:
intent = stripe.PaymentIntent.create(
amount=1000,
currency='eur',
customer=stripe_customer_id,
payment_method=stripe_payment_method_id,
off_session=True,
confirm=True,
receipt_email=customer.email,
)
I have created a product in the dashboard. The dashboard provides a priceID which looks like this: price_1LT0RKGPl0rdJavu7TKMB4F7
.
Is it possible in the paymentIntent to use this priceID
or anything that can be related to my product previously created in the dashboard instead of the amount
value required in the paymentIntent
?
Basically, I would like something like this:
intent = stripe.PaymentIntent.create(
amount=price_1LT0RKGPl0rdJavu7TKMB4F7,
currency='eur',
customer=stripe_customer_id,
payment_method=stripe_payment_method_id,
off_session=True,
confirm=True,
receipt_email=customer.email,
)