I am using Loopback4 to build REST APIs that can communicate directly with native mobile apps. As part f the error handling process what I need to do is formulating a standard error response with the following structure:
{
code (Error code),
errorName (Error Name),
description (detailed description of the error)
}
This object will be sent to the native app in case any error occurs.