How can I handle the error gracefully in webix when operation makes error on FileManager?

Hello experts, I’m so newbie on web.
I’m doing porting FileManager’s example PHP code to JSP and I want to use my custom file system.
But, I don’t know how I can handle some error of the “Action”.
For instance, I made webix.ui filemanger registers handler on “test.jsp” for “remove” action. and test.jsp call some java library but catch Fatal Error (without moving error page…)
In this situation, How can I distinguish above error.
Cuz, sample code only return some JSONArray, I don’t know there is special attribute for error handling.
Also, Could I get some data sheet for each action returning value?
I mean, when I success to listing directory.
I should make some JSONArray for return consisted of JSONObject like
{“id” : something, “value” : something, “type”: something … }

Filemanager provides onErrorResponse event. You can attach a handler, which will fire in case of data saving error and will provide the full server-side response, so the client side code can read data from server side and output some meaningful error message.

http://docs.webix.com/file_manager__events.html#onerrorresponse

There is no any special attribute. If server side returns status code 500, the onErrorResponse handler will trigger.

Also, Could I get some data sheet for each action returning value?

Only file uploading requires a special response. For all other operation, any JSON object will be fine.

Server side may contain information about new item id, or new item name, but it is fully optional. ( I can’t find the related info in docs, so there is really a gap here, we will try to fix it ASAP )

Thank you for your answer. I’ll try