#yaldabaoth_xx

1 messages ยท Page 1 of 1 (latest)

hard hamletBOT
low reef
#

Hi ๐Ÿ‘‹

Promotion codes don't work with PaymentIntents. You cannot consume them using the Payment Intent and you cannot mark them as consumed using the API.

The closest option would be to set the Promo Code as inactive but it's not clear to me what you are trying to do.

SInce you are looking to apply a promotion code to the payment intent, and this isn't something you can do with Stripe, you could build out the code tracking system in your own integration.

humble yoke
#

hi!

our flow is currently:

  1. User signs up and pays using a PaymentIntent
  2. The Subscription is created based on if that succeeds or fails.
  3. We apply a "First Month" discount coupon for 100% off. And the billCycleAnchor date is set to some time in the future for Month 2.

We want to support Promotion Codes for various durations. 1 Month, 3 Month, etc. There are PromotionCodes that can also only be used one-time.

I was thinking if a Promotion Code was only for one month, how we could best ensure it would be marked as redeemed. my initial thought was just calculating the discount of the Promotion Code for the amount of the Payment intent and then marking it as redeemed.

now i'm curious if:
โ€ข can we apply a promotion code to a Subscription if there is already a coupon?

low reef
humble yoke
#

ok thanks for your help! we will tinker ๐Ÿ™‚

low reef
#

Yes I would recommend testing this out to make sure you get the behavior you want.

Are you currently using Test Clocks?

humble yoke
#

Yep we are

low reef
#

Great! I just wanted to make sure you had all the tools so you could test promotion codes of various lengths without having to wait.

#

Before test clocks we were creating prices with billing periods in the minutes so we could test these behaviors. It was no fun