I am trying to find a way of using Nexmo in a Laravel setup to throw errors in json so that they can be easily handled by my rest client but with no success so far.
nexmo/laravel isn't concerned with output formats, only with returning data/errors. To return JSON errors, you need to catch the exception thrown by Nexmo and return json($e->getMessage());
I am trying to find a way of using Nexmo in a Laravel setup to throw errors in json so that they can be easily handled by my rest client but with no success so far.