My guess was to use the following syntax:
MyModel::all()->delete();
But that did not work. I\'m sure it\'s super simple, but I\'ve searched
Solution who works with Lumen 5.5 with foreign keys constraints :
$categories = MusicCategory::all(); foreach($categories as $category) { $category->delete(); } return response()->json(['error' => false]);