Just as per the title. Default api middleware in Laravel 5.6 is listed in Kernel.php
as:
protected $middlewareGroups = [
'api' => [
'throttle:60,1',
'bindings',
],
];
I'd appreciate a layman's explanation of what bindings
does, which I can't find anywhere.
It uses the SubstituteBindings
class which has the handle
method:
public function handle($request, Closure $next)
{
$this->router->substituteBindings($route = $request->route());
$this->router->substituteImplicitBindings($route);
return $next($request);
}
Though I still don't follow what it does.