Localize API Error Messages Returned by 3rd Party Providers

Problem statement

When configuring a Passwordless SMS connection and a user sends an invalid phone number, the SMS provider responds with the following error message in the ‘error_description’ field:

status 400

{
"error": "sms_provider_error",
"error_description": "The 'To' number +1XXXXXXXX is not a valid phone number. (Code: 21211)"
}

There are several other situations where a third party service might return an error message due to some issue in the login flow. Is it possible for Auth0 to localize these error messages so a translated error can be presented to the end-user?

Solution

Currently, this is not supported; Auth0 will pass along whatever error message a 3rd party service sends without any further processing to the message itself.

Feel free to open a Feature Request on the Community Site to have this use case reviewed by the Auth0 Product Team.