tarun-singhal/apperrormanager

There is no license information available for the latest version (dev-master) of this package.

To caputure the Api Errors/Exceptions in Apigility or REST API.

dev-master 2015-12-30 13:49 UTC

This package is auto-updated.

Last update: 2024-11-28 20:35:24 UTC


README

AppErrorManager is used to capture the API error and exception on fly. It is very usefull to manage the single place to capture the error message and error code.

  • Steps to Enable and usage of AppErrorMAnager Module

Step 1 :To enable the Module in ZF2, Include the module name inside application.config.php file

return array(
  ...,
  ...,
  'ErrorManager'
);

Step 2: now if you want to capture the api exception then change in ApiProblem i.e. new ApiProblem(200, '1001'); where, '1001' : is the error code,

Step 3: Open the config/Error.ini file, please the error code inside that like as below:

[test.rest.respapiname]
1001 = api problem found

Step 4: Now you can manage the api code and message at one place.

I hope it will help you to handle exception/error and to identify the actual debug happening in the API Calls.