The PHP magic method
__invoke provides a powerful way to encapsulate functionality while separating state from results and errors.
__invoke provides a powerful way to encapsulate functionality while separating state from results and errors.
application/json? Unless your Laravel 4 application is in debug mode, you're out of luck: the client receives text/html!Route facade.