как загрузить файл документа в полоску для проверки. я использую этот код.
include_once(app_path() . '/Stripe/init.php');
\Stripe\Stripe::setApiKey(trans('lang_data.Secret_key'));
$file = $r->file('image');
$file_name = date('Ymdhis') . '.' . request()->image->getClientOriginalExtension();
if(request()->image->move(public_path('image/payout_file'), $file_name)){
$image = 'https://ufitpass.com/public/image/payout_file/'.$file_name;
$filePath = 'https://'.$_SERVER['SERVER_NAME'].strstr($image, '/public');
$filePurpose = 'identity_document';
$fp = fopen($filePath, 'r');
$account = \Stripe\File::create(
[
'purpose' => 'identity_document',
'file' => fopen($filePath, 'r'),
],
[
'stripe_account' => trans('lang_data.Secret_key'),
]
);
echo '<pre>';print_r($account);die;
}else{
echo'error';
}die;
после компиляции этого ответа будет
Stripe \ Exception \ InvalidArgumentException: только потоки ресурсов обычного файла поддерживается в файле / var / www/html/ultimateFitness/app/Stripe/lib/ApiRequestor.php в строке 39