Reference > SDK > Languages
Languages SDK Reference
API reference for the Languages SDK — methods for retrieving configured languages.
WHAT YOU'LL LEARN
- What methods are available on
sdk.languages? - What parameters each method accepts?
- What each method returns?
Overview
The LanguagesSdk is accessed via sdk.languages on a Webiny instance. It provides methods for retrieving the languages configured in Webiny. All methods return a Result type — see the SDK overview for initialization and error handling details.
Methods
listLanguages
Returns all languages configured in the Webiny instance.
Signature:
This method takes no parameters.
Returns:
An array of Language objects:
| Field | Type | Description |
|---|---|---|
id | string | Unique language ID |
name | string | Human-readable language name (e.g. "English") |
code | string | BCP 47 language code (e.g. "en-US") |
direction | "ltr" \| "rtl" | Text direction |
isDefault | boolean | Whether this is the default language |
enabled | boolean | Whether this language is currently active |
Example: