#kiroolos

1 messages · Page 1 of 1 (latest)

still joltBOT
prisma jay
#

// Create a subscription with a trial that ends on the first day of the next month at 12AM
const subscription = await stripe.subscriptions.create({
customer: customer.id,
items: [
{
price: process.env.STRIPE_PLAN_ID
}
],
trial_end: lastDayOfMonthWithTime, // set trial end to last day of the month at 11:59PM
collection_method: "send_invoice",
expand: ["latest_invoice.payment_intent"],
days_until_due: 1
});

polar jasper
#

Hi 👋 can you elaborate on where you're running into trouble accomplishing that?

prisma jay
#

i just want to stop sending user the email of asking to pay

#

as i already created a cronjob that pays automatically with adding extracost

#

All i need is to stop sending email to user asking to pay manually

polar jasper
#

Gotcha, I'll take a look to see what we have, but I'm not sure if that is possible when the collection_method is send_invoice.

prisma jay
#

Thanks i will have a lookinto this