Taking fee and payment reservation Stripe

225 Views Asked by At

Pretty new to Stripe, we're building an online marketplace. Each user can buy assets from any other user. We also take fees for each payment.

We go with connected accounts. Seller goes through the onboarding flow (create connected account, create account link etc), while buyer is registered as a customer of our platform on Stripe.

Now, whenever buyer makes a payment we create a payment intent to pay to us (amount + 20% fee via):

stripe.paymentIntents.create(params)

Then we create new payout to seller (amount) using source transaction from payment intent above:

await stripe.transfers.create({
            amount: payment.amount * 100,
            currency: payment.currency,
            destination: seller.stripeAccountId,
            source_transaction: sourceTransaction,
});

Is this the preferred and best way of handling this? In terms of time, we need first to wait for payment to settle to our bank account to be able to payout seller?

Is there any better way of doing this instead of manual payouts? Is there a way to make direct transfer to connected account when user does payment? I tried with payment intent, specifying connected account id in request, but API is complaining that customer id is on our platform but account id is specified, so it's not possible obviously.

Also, manual payouts would come handy to simulate payment escrow/deposit. When user create a request for some asset, we would immediately transfer certain amount to our account, like reserving that amount. And if the seller accepts the offer, we would do a payout. If seller rejects the offer, we would do payout to the buyer, giving him back his money.

Does this make sense?

Thanks in advance

1

There are 1 best solutions below

1
On

You don't need Payout (yet) in your use case. You are doing Separate Charges and Transfers, and fund simply moves from your Account's balance to Connected Account's balance. It hasn't been out of your Connected Account's balance to your Connected Account's bank account yet, which is called "Payout".

In another word, Payout is separated process than Charges and Transfers. Charges and Transfers can happen immediately, and Payouts normally happen later on a daily basis or manually.

Find more explanation on Connect Balance. There is also Destination Charge which is simpler than Separate Charges and Transfers. I recommend Destination Charge unless you have specific reason to use Separate Charges and Transfers, ie. you need to transfer to multiple Connected Accounts on one payment.