Localizable Action
Allows you to configure the localization settings of this interaction/command, as well as retrieve a localization context from it.
Configuring localization bundle and prefix
You can change the bundle and prefix in the first lines of your interaction handler, with localizationBundle and localizationPrefix.
See also
Inheritors
Properties
Functions
Link copied to clipboard
Retrieves a DefaultMessages instance, using a locale suitable for messages sent to the user.
Link copied to clipboard
Returns a localization context for the provided bundle name and path prefix.
Link copied to clipboard
abstract fun getLocalizedMessage(locale: Locale, localizationPath: String, vararg entries: Localization.Entry): String
open fun getLocalizedMessage(locale: DiscordLocale, localizationPath: String, vararg entries: Localization.Entry): String
Returns the localized message at the following path, using the provided locale and parameters.
Link copied to clipboard
fun LocalizableAction.getLocalizedMessage(locale: Locale, localizationPath: String, vararg entries: PairEntry): String
fun LocalizableAction.getLocalizedMessage(locale: DiscordLocale, localizationPath: String, vararg entries: PairEntry): String