Skip to main content
Defined in: core/provider.ts:1261 What buildMessageContext needs to localize a context (implemented by the Bot’s I18n).

Properties

defaultLocale

Defined in: core/provider.ts:1263 Initial ctx.lang (the bot re-resolves it inside the per-chat queue).

userKey

Defined in: core/provider.ts:1265 ctx.user key ctx.setLang() writes.

enabled

Defined in: core/provider.ts:1267 Whether per-message language resolution is on; ctx.setLang() refuses otherwise.

Methods

supported()

Defined in: core/provider.ts:1269 The registered locale serving code (itself or its base language), else undefined.

Parameters

Returns

string | undefined

translate()

Defined in: core/provider.ts:1270

Parameters

Returns

string