Okta Sign-In Widget: How to Set a Generic Fallback Message for Undefined i18n Keys

Issue Summary
We’re customizing the Okta Sign-In Widget and have successfully overridden specific i18n keys using the i18n config. However, we would like to display a single fallback message for any i18n key that we haven’t explicitly defined

Current Implementation
We’re already overriding specific i18n keys like this:

var oktaConfig = {
issuer: ‘https://our-domain.okta.com’,
clientId: ‘our-client-id’,
redirectUri: ‘https://our-app.com/callback’,
i18n: {
‘en’: {
‘errors.E0000004’: ‘Custom unable to sign in message’,
‘errors.E0000069’: ‘Custom authentication failed message’,
‘primaryauth.title’: ‘Custom sign in title’,
‘oform.errorbanner.title’: ‘Custom error banner’,
// … etc
}
}
};

var signIn = new OktaSignIn(oktaConfig);

This works as expected for keys we have defined.

The Problem
If a message uses an i18n key we haven’t defined — for example, errors.E0000999 or any newly introduced key in future widget versions the widget falls back to Okta’s default English text.
We want to catch all undefined keys and display one generic fallback message such as:“Please contact support for assistance.”

What We’re Looking For
We want the following behavior:
• Defined keys → Use our custom message (already working)
• Undefined keys → Use a single fallback message (not working yet)
We’re aware of the full list of i18n keys available in the login.properties file, but we want to avoid maintaining and overriding each one individually with the same fallback text.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.