#bhavdip - coupon
1 messages · Page 1 of 1 (latest)
Hello! Just starting a thread for you -- I'll review and respond as soon as I can 🙂
What do you mean by product duration? What are you trying to do?
Hello
Hi, I have a question! I want to create coupons like subscription cycle should be extend 3months from 1month if user apply the coupon.Ex.Gold subscription cycle plan is 1 month. It cost $10.If user apply ABCD coupon on subscriber time than user should get 3 months Gold subscription plan. Cost should be same $10. How can we do this?
@coarse sinew
Here User can get 3 months plan if apply coupon. Amount should be $10.
Hi @coarse sinew Are you there?
hey there, sorry reading now 🙂
You want to offer 3 months free?
You can create coupon that discount either amounts or percent off
What part are you having trouble with exactly?
Yes if use coupon.
You can create the coupon with either amount_off or percent_off
https://stripe.com/docs/api/coupons/create#create_coupon-amount_off
https://stripe.com/docs/api/coupons/create#create_coupon-percent_off
Then you can choose the duration:
https://stripe.com/docs/api/coupons/create#create_coupon-duration
https://stripe.com/docs/api/coupons/create#create_coupon-duration_in_months
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
When you have the coupon, you apply it to the subscription:
https://stripe.com/docs/api/subscriptions/update#update_subscription-coupon
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Ok I am asking about subscription cycle duration. not coupon duration.
I'm not sure what you mean
I want to offer 3 month on subscription cycle if use coupon.
Hi 👋 I'm stepping in for @coarse sinew . I think there may be a misunderstanding here about how Coupons work with subscriptions. They are intended to discount an amount, not a time. If you want to provide a duration based discount you can either calculate the amount yourself or apply a free trial period using the trial_end parameter.
You could also use a Subscription Schedule and when your user enters the coupon you could add an additional 3 month period as an additional phase.
In either case I would highly recommend using our new Test Clocks feature to test out your approach and ensure the behavior is what you expect. Test Clocks will allow you to simulate what will happen with the subscription over time.
https://stripe.com/docs/billing/testing/test-clocks
Ok thanks. trial_end parameter means with $0 amount? i want to go with $10.
In that case you would want to try subscription schedules and add a 3 month price for $10
The last thing you said was Yes. I didn't realize it was a question. Please restate what about the above solution is unclear or does not work for your use case.
Ok Here I am sharing screenshot of my app. In screenshot. Provide 1 month subscription with $10 after start membership. Admin want to give 2 months extra to user if use XYZ coupon.
how to create XYZ coupon without fixed/ percentage amount ?
How to create XYZ coupon with 2 months free subscription plan?
As I said earlier. Stripe coupons work to reduce the amount charged to the user. You would not use Stripe coupons to achieve this outcome
Ok so is there any other provide api without coupons?
I told you above that you could use Subscription Schedules to make a similar change to your customer's subscription. You can use a coupon string in your app and just catch it in your own system and apply the changes that way.
So I need to manage this things on my system with the help of Subscription Schedules Stripe API?
Yes that is what I am suggesting. So if you are wanting to add 2 months to the subscription without charging the customer, you may want to create a free trial as the second phase of the subscription.
Ok I am wanting to add 2 months to the subscription with charging the customer.
so is this confirm that We can not use coupon and free trial if want to give offer add 2 months to the subscription with charge?
What do you mean? you just said the additional 2 months are free?
It means subscription end date should be after 3months instead of 1month if use coupon offer.
Okay so that would be even more simple. You would just have 2 prices. Once that is $10 for one month and one that is $10 for 3 months. When you first create the subscription your application would choose with price to use based on whether the customer entered a valid coupon or not.
Honestly I think that makes more sense.
Here details
Gold subscription plan
Charge amount : $10.
Plan period : 1month
Now action by customer
if customer use coupon on subscription time.
Charge amount : $10.
Plan period : 3months
if customer dnt use coupon on subscription time.
Charge amount : $10.
Plan period : 1month.
Question
How to create coupon for the above case?
Don't use a coupon
Is there any Stripe API to we can create coupon as per above case?
Yes, you can create 2 price records
Price 1: $10, interval is 1 month
Price 2: $10 interval is 3 months
If a user enters a coupon your app chooses Price 2
Otherwise choose Price 1
Ok Got it. thank you @severe dome We have already create others coupon to give offer on percentage and fixed amount. This things is working good with stripe api.
like reduce $X amount charge amount if customer use coupon.
Yes coupons work well for discounting amounts.
But they are not designed to add time to a subscription
Ok Is there any Stripe service if want to give offer with designed to add time to a subscription.
?
No, the best approach is what I just told you
It can look exactly the same to your user
Just your application would handle it differently
I'm glad we were able to get you to a solution that should work for you 🙂
Okay let's chat here
Yes
You said: "Can you provide apis to create price 1 and price 2 as we suggested on thread?"
I'm getting caught up on the above
So you can create prices via the API here: https://stripe.com/docs/api/prices/create
You would just set the same Product ID for the two prices if you want them to be associated with the same product.
Thanks @desert cove