When you are using a API Before-Save script and use maybe something like this in your formular:
How could you have translated custom error messages?
Code:
recordService\throwBadRequest("This is an invalid value.");