#Kesteris

1 messages · Page 1 of 1 (latest)

west tideBOT
strange dove
#

Hi there! Pasting your other message in this thread:

var priceCreateOptions = new PriceCreateOptions
{
Product = createdProduct.Id,
UnitAmountDecimal = (decimal)subscription.Price * 100,
Recurring = new()
{
Interval = "day",
IntervalCount = subscription.PeriodDays,
TrialPeriodDays = subscription.DelayDays,
},
Currency = "eur",
};

#

Can you share the Payment Link ID?

abstract violet
#

Wondering how can I do that

strange dove
#

Can you share the Payment Link here?

abstract violet
#

Do you need the ID like pi_.....?

strange dove
#

If you are using Payment Links, you should have a plink_xxx ID.

#

But feel free to share the actual Payment Link here if that's simpler for you.

strange dove
#

You menationed "payment link" in your first message, so I assumed that you were using our Payment Link product. Thanks, having a look!

abstract violet
#

Oh sorry, I was talking about checkout url

#

My mistake

strange dove
abstract violet
#

I see.. I set up recurring Price object instead with trial days.. I guess that might a problem

#

Although, can I mix subscription and product in the same session?

#

While paying once for the product and having recurring payment for subscription?

strange dove
#

I see.. I set up recurring Price object instead with trial days.. I guess that might a problem
When using Checkout Session, you need to set the trial when creating the Checkout Session itself.
Although, can I mix subscription and product in the same session?
Yes Checkout Session work with multiple prices. Note that you'll need to use mode: subscription if at least one price is recurring.

abstract violet
#

Won't customer be charged for the product with recurring payment also if I set mode to subscription?

strange dove
#

For recurring prices, then customers will have recurring payments. For one time price, customer will only pay once.

abstract violet
#

Just to be clear, for having a subscription with recurring payment and trial days, I need to create Session with SubscriptionData which includes TrialPeriodDays and also when creating Price, I should define that it's Recurring payment with the same TrialPeriodDays?

strange dove
#

You can completely ignore the trial setting on the price. Everything else is correct.

abstract violet
#

Alright, thanks