Tuesday, July 11, 2017

Changing The Laravel Passport/OAuth-Server Responses

Asked by: Daniel Dewhurst


I'm building an API in Laravel 5.4, using Laravel Passport 3 for authentication. All of my API methods return a set of values that are always returned, success, errors (if there are any errors) etc.

I've changed the response of a \Illuminate\Auth\AuthenticationException throws, to fit with the rest of my app, however I'm not sure how to change the response of various token grant responses, without doing something horrible like editing the vendor files.



Source

No comments:

Post a Comment

Adbox