How do I set the application fee on Stripe Omnipay? It works fine when I use stripe's php library but could not get around with Omnipay.
Error Message: Can only apply an application_fee when the request is made on behalf of another account (using an OAuth key, the Stripe-Account header, or the destination parameter).
$formData = [
'number' => '4242424242424242',
'expiryMonth' => '8',
'expiryYear' => '2018',
'cvv' => '123',
'firstName' => 'John',
'lastName' => 'Wags',
'email' => '[email protected]' ,
];
$response = $gateway->purchase(
[
'amount' => '16.00',
'applicationFee' => '2.00',
'destination' => 'acct_24xxxxxxxxxxxxxx',
'currency' => 'AUD',
'card' => $formData,
'receipt_email' => '[email protected]',
'description' => 'Ref:10201'
]
)->send();
Am I doing something wrong here?