#Anjali - clarification

1 messages · Page 1 of 1 (latest)

foggy raven
#

Hello let's chat in here

sharp snow
#

hi

#
  1. How can I add application fee amount in separate charge and transfer?
  2. 'Amount' specified in the payment intent is what?
  3. Could you please explain the flow for example a customer paid CAD 100 we gets 5% and our user gets 95% after deducting stripe fees from 100usd.
  4. From our website i will get the amount charges to the customer. Using code, how can i write 5% goes to platform and 95% goes to user?
nova latch
#

hey there, looking at this

#

WIth separate charge and transfer, you effectively collect your application fee by transferring less than the payment amount

#

there is not an explicit fee

#

You would calculate the amount to send to your user after the payment

#

Reserving whatever necessary for your platform

sharp snow
#

So I need to fetch the amount from stripe after deducting stripe fee? Then deduct our application fee and transfer to connected account?

nova latch
#

Correct

sharp snow
#

one more thing. 'amount' specifies in the payment intent refers to which amount? amount chrged to customer or deducted amount after stripe fee?

#

$paymentIntent = \Stripe\PaymentIntent::create([
'amount' => 1000,
'currency' => 'cad',
]);

// Create a Transfer to a connected account (later):
$transfer = \Stripe\Transfer::create([
'amount' => 700,
'currency' => 'cad',
'destination' => 'acct_1KrMxdPFuBAwSNy4',
]);

#

amount 1000 means (amount from customer - stripe fee)?

nova latch
#

it's the amount that the customer will pay. Stripe fees are deducted from that amount and the remainder will go to your platform's balance.

sharp snow
#

amount 1000 means amount from customer

#

amount 700 means (amount from customer - stripe fee)?

#

My question is amount 1000 in payment intent is that customer amount. After that i need to retrieve the amount-stripe fee from stripe dashboard. Then that deducted amount will put inside the transfer amount, right?

nova latch
#

You can transfer whatever amount you need to the connected account, i don't know what that needs to be for your business

#

but using made up fee of say 100, if you used amount 1000 for the payment then amount 700 for the transfer, then you platform should end up at net +200 (+1000 payment - 100 fees - 700 transfer)

sharp snow
#

Hi

#

Fatal error: Uncaught (Status 400) (Request req_YE39cCK87QrP6d) You have insufficient funds

#

why this happening?

#

I am checking in test mode

nova latch
#

You need to either use the test card that makes the balance available immediately, or use source_transaction:

#

For test mode the test card is a quick workaround

sharp snow
#

ok

nova latch
#

but in live mode you must use the charge reference to link the pending balance

sharp snow
#

ok

sharp snow
#

can you tell me how can i do that? I added balance manually from dashboard. It is showing like it takes somedays to wire transfer

#

So my balance like 0. Then try to add one payment manually. But that amount also not showing up in my account. I can see it in transactions.

nova latch
#

You can't use source_transaction for that top up flow, you'd need to wait for it to be available

sharp snow
#

oh

nova latch
#

In test mode, use the card that skips pending balance to accrue some balance

sharp snow
#

Then how can i check the transfer is doing correctly?

nova latch
#

What do you mean?

sharp snow
#

How can I check the transfer amount going to connected account? I wrote the code for payment transfer. Then in local, i created on checkoput form. It will redirect me to a error sufficient funds. My doubt is how can I check from dsahboard that funds are flowing correctly to connected account and my platform?

#

insufficient**

nova latch
#

What do you mean "check the amount"? You create the transfer with the amount, right?

nova latch
sharp snow
#

No, i meant i need to check whether my code is working or not. I have set the code for payment transfer. I need to check correct amount is getting in my platform and connected account

#

for that i need to complete checkout. within the checkout action page i write code for payment transfer. There i am getting insufficient funds. fatal error

#

How can i rid of that?

nova latch
#

Can you share a specific example? Where are you seeing insufficient funds?

sharp snow
#

ok

#

Just i need to know am i doing right or not, thats why

#

i have the prebuilt checkout form. In its suucess url , i write the code for payment transfer. Chcekout page works fine. After entering card details and pay now button, it will redirect to success url that is to the page conatins payment transfer code. In that page , am getting the error. So this prevents me from checking at the dashboard that what is the collected fee, transfer amount like that

nova latch
#

Where does this error happen, on your server trying to create the transfer?

sharp snow
#

yes

nova latch
#

Note that for success URL returns you likely also want to set up checkout.session.completed webhooks in case the redirect fails for some reason

#

OK, do you have an example of that transfer request failing?

#

You need to switch to manual payouts to accrue balance, if you haven't already done that

sharp snow
#

Now i switched to manual.

#

showing that cash balance will be available soon

nova latch
#

Yes, now you can use that test card to skip pending again

#

or, as mentioned for live, using the source_transaction