#vell2x_webhooks

1 messages ¡ Page 1 of 1 (latest)

past finchBOT
#

👋 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/1354644219477627051

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

heady otter
past finchBOT
fair scroll
#

can you review my snippet

#

const account = await stripe.accounts.create({
type: 'express',
email: req.body.email,
business_type: 'company',
metadata: {
'proid': req.body.proid,
},
settings: {
payouts: {
schedule: {
interval: 'weekly',
weekly_anchor: 'friday'
}
}
}
});

#

I want to pay out every other friday

lapis zealot
#

Hi @fair scroll I'm taking over this thread

fair scroll
#

const account = await stripe.accounts.create({
type: 'express',
email: req.body.email,
business_type: 'company',
metadata: {
'proid': req.body.proid,
},
settings: {
payouts: {
schedule: {
delay_days: 7,
interval: 'weekly',
weekly_anchor: 'friday'
}
}
}
});

#

would this work?

lapis zealot
#

This is to schedule weekly payouts on Friday. Is this what you want to achieve?

fair scroll
#

Yes

#

I added delay_days to simulate a bi weekly effect

lapis zealot
#

No, setting delay_days doesn't change the payout frequency

fair scroll
#

ok

#

So what I have will pay out every friday

lapis zealot
#

Just use

  interval: 'weekly',
  weekly_anchor: 'friday'
fair scroll
#

What do delay_days do? We do want a buffer to allow funds to settle before being paid out

lapis zealot
#

The delay_days is to delay the payout. For example, the you have $10 funds available on 1 Jan, and you set delay_days to 7. The $10 will only pay out 7 days later on 8 Jan.