I am trying to make POST to a rest API where I need to send multiple files from a user input form. I have managed to get it to work with a single file, but when there are multiple files sent as an array ($file[]), I can't see anything in the laravel docs to show how this can be done.
$response = 'API_URL';
$response = Http::withToken(ENV('API_KEY'))
->attach('file', fopen($request->file, 'r'))
->post($url, [
'uuid' => $request->uuid,
]);