Errors & response envelope
Every response — success or failure — shares one envelope shape, so you can parse it the same way every time.
{
"error_code": 0,
"message": "Success",
"errors": null,
"data": { }
}On failure
On failure error_code carries a symbolic code such as WRONG_QUERY, data is null, and errors may hold field-level validation details. The HTTP status reflects the class of error (4xx client, 5xx server) while the code pinpoints the specific cause — see the full error codes reference.