get('path'); // create bucket $bucket = Bucket::find($id); // getting files $files = FileManager::find($bucket->path.'/'.$path); return response()->json([ 'files' => $files ]); } /** * * * @param Request $request [description] * @param [type] $id [description] * @return [type] [description] */ public function upload(Request $request, $id) { // create bucket $bucket = Bucket::find($id); } }