#samip_unexpected

1 messages ¡ Page 1 of 1 (latest)

dawn galeBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1282902261642559498

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

untold moon
#

The first Screenshot is before forwaring time and the second is after forwarding time. These are test data.

swift crater
#

Could you share the example subscription schedule ID?

untold moon
#

sub_sched_1PxKW3Gei7MrDZaxXsm9uz8A

swift crater
#

There was no default payment method on the subscription or customer, so payment attempt was failed since no payment method was available to charge

untold moon
#

How did it succeed the first time around ? Also, how do you think I can get around this ?

swift crater
#

In the first invoice sub_1PxKVrGei7MrDZaxnXY0PBoZ, default_payment_method was set on the subscription as the payment method was created from Checkout Session

untold moon
#

Do I extract this from the subscription that was deleted ? i.e sub_1PxKVrGei7MrDZaxnXY0PBoZ this one ?

#

The default payment method I mean.

#

I have a case where a customer subscribes to product A and then when they decide to upgrade I cancel their product A but create a subscription using a subscription schedule for them.

So, inorder to get their payment details do I need to first extract it from the subscription that I am deleting and then use that when creating a subscription ?

Is this a good option ?

#

Also, it would be greatful if you could tell me if there is a workaround for that DRAFT state as I want the payment to go immediately and not stay in DRAFT for the time being .

swift crater
#

There is no need to cancel the existing subscription and create a new one

untold moon
#

These are different products.

#

Product A and Product B are different products but we allow an update from Product A to Product B

swift crater
#

This is supported in Subscription by changing different products

#

Are you facing any error in updating a subscription to a different product?

#

A price belongs to a product. By updating the price, the product will be updated as well

untold moon
#

I am trying to create a distinguishion between Product A and Product B

#

When a customer upgrades to Product B, then I currently expire Product A and create a subscription schedule for them for Product B.

However, the invoice goes to draft mode for 1 hour which is something known to us but was wondering if there is a way to make sure the customer pays the amount when the subscription schedule is released

swift crater
#

What are you trying to achieve here? Could you share your scenario in an example?

By updating the subscription directly should solve the use case you described and there shouldn't be any need to delete an existing subscription and creating a new one. When you update the subscription, you would have been able to distinguish the product A and product B

#

I still don't see your use case why Subscription Schedule should be used

untold moon
#

I am trying to achieve a cross product update if that makes sense

swift crater
#

Subscription Schedule should only be used if you attempt to schedule a subscription or its changes in the future

#

Otherwise, Subscription Schedule shouldn't be used

#

I am trying to achieve a cross product update if that makes sense
What is the problem you're facing if you update the subscription directly?

dawn galeBOT
untold moon
#

I think adding additional prices makes sense

#

I can see why you'd want me to do that.

valid birch
#

Hi @untold moon I'm taking over this thread, let me know if you have any questions.

untold moon
#

Hi jack, River has given me some pointers to work on I will use that and re-open the thread if I cannot still solve it

untold moon
#

Hi @valid birch , just following on the above.

I tried to use one product with multiple prices to manage the subscription and perform upgrade and downgrades. But, the same product can have a different name based on price.

For example If I have a product A with three prices : $99 , $29 and $19.

When in checkout page, I want customer to see something like this when they get to the checkout session:

  1. If the product price is $99 -> The product name is Product A
  2. If the Product Price is $29 -> The product name is Product A Lite
  3. If the Product Price is $19 -> The product name is Product A Lighter ....

How do I configure this ?

#

I know I am not supposed to mention but mentioning because this thread has been idle for a while, sorry in advance !

#

I am using a Stripe Hosted Page in my checkout session

valid birch
#

Hmm, I think you can just name your products "Product A ", "Product A Lite" and "Product A Lighter", does it work for you?

untold moon
#

But that takes me back to making 3 different products and makes me circle around the original issue

valid birch
#

It's a long thread, can you briefly tell me the original issue that you want to solve?

untold moon
#

I have an need to upgrade a customer to a different product using the API . The way I do it is to expire the customer's existing subscription and create a new subscription using subscription schedule for them. Understandably, it keeps it in the draft status until 1 hour, but when I used test clock to forward the time it failed with a retry.

  • This happened due to a missing card.
  • I cannot afford to have a DRAFT state when upgrading.

Now I have two options :

  1. Create one product with multiple pricing and somehow differentiate between them in the checkout page.
  2. Create 16 different products and cross update a customer, so that when a customer wants to go from Product A to Product A lite, I will have to update the subscription with the new product ?
valid birch
untold moon
#

New price of the newer product ?

valid birch
#

It can be the new price of a new product, or a new price of an existing product

untold moon
#

So, if the customer is going from "Product A Lite" to "Product A Lighter" then I should have two products with the name and then upgrade them ?

#

Whilst upgrading them using the Product A Lighter's priceID

valid birch
#

I'd recommend you creating a new product with a new name, so that it can be reflected in the invoice / receipt that your customer receives.

untold moon
#

Okay, if that's the case I am happy to create those three different products.

The problem arises when I have 4 different pricing tier for the product

So, lets assume we are serving Russia, UAE, AU and Nepal

Product A Lighter can have different prices for Russsia, UAE, AU and Nepal

Does this mean I now need to setup a new product for each country ?

#

That would be a looooot of products thought

#

Can I not just update the stripe page product description based on price ?

valid birch
#

No, you can create one product (i.e., Product A), and associate it with prices created for Russia, UAE, AU and Nepal

untold moon
#

Nice

#

So even if the currency differs it does not care?

valid birch
#

You can create a product with prices in different currencies

untold moon
#

That is amazing !