Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Stripe Payouts as an Escrow emulation

I'm trying to emulate the Escrow system using Stripe Payouts. Actually, there is no escrow in Stripe now but in this Q/A article I've received an advice to use Payouts for this case. The official documentation covers Payouts not so good. The best I found is here. The idea is to send payments to user's card. I'm building the web-application using Angular 4 and Symfony Framework 3.2. This part was server-side executed, so the PHP code is the following:

public function payToCardAction()
{
    $apiKey = $this->getParameter('stripe_secret');
    Stripe::setApiKey($apiKey);

    try{
        Payout::create(
            array(
                'amount'      => 400,
                'currency'    => 'gbp',
                'description' => 'Example payment',
                'source_type' => 'card',
                'destination' => preg_replace('/\s+/', '','4242 4242 4242 4242')
            )
        );
    }
    catch (Card $e){
        return new JsonResponse(
            array(
                'status' => 400,
                'message'=> 'Bad request'
            )
        );
    }
    return new JsonResponse(
        array(
            'status'   => 200,
            'message'  => 'Success'
        )
    );
}

I used test card (4242 4242 4242 4242) in order to send there some test money but received the following error:

No such external account: 4242424242424242

Error reference in the documentation didn't help me. How can I solve this issue?

like image 769
Varg Avatar asked Oct 30 '17 01:10

Varg


People also ask

Can I use Stripe for escrow?

Escrow has a precise legal definition and Stripe doesn't support escrow accounts. However, Stripe does provide escrow-like behavior through manual payouts.

How does Stripe escrow work?

Officially, Stripe does not support escrow accounts. However, they do provide escrow-like behavior through manual payouts. This gives you influence over payout timing, with the ability to delay payouts to Custom accounts for up to 90 days.

How does payout work on Stripe?

With Instant Payouts, you can instantly send funds to a supported debit card or bank account. You can request Instant Payouts any time, including weekends and holidays, and funds typically appear in the associated bank account within 30 minutes.


1 Answers

You need to use Stripe Connect to accept payments on behalf of third-parties and send payouts to their bank accounts (or debit cards, in the US).

I recommend you reach out to Stripe's support at https://support.stripe.com/email to explain your business model and desired flow of funds. They will help you make sure your model is supported and advise on which APIs exactly you should use.

like image 77
Ywain Avatar answered Sep 22 '22 06:09

Ywain