> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # ListSupportedLocales # Package: localeManagement # Namespace: SupportedLocalesService # Method link: https://dev.wix.com/docs/api-reference/business-management/multilingual/locale-management/locales/list-supported-locales.md ## Permission Scopes: Wix Multilingual: SCOPE.MULTILINGUAL.MANAGE_TRANSLATIONS ## Introduction Retrieves a list of all Wix-supported locales that can be added to a site. Call this method to display supported language details when creating or updating a locale. --- ## REST API ### Schema ``` Method: listSupportedLocales Description: Retrieves a list of all Wix-supported locales that can be added to a site. Call this method to display supported language details when creating or updating a locale. URL: https://www.wixapis.com/v2/locales/supported Method: GET Method parameters: query param name: includeAllLocales | type: includeAllLocales | description: Whether to include all possible regional variants for each language code in the response. When `false`, only the default locale, such as `"en-US"`, is returned and regional variants like `"en-GB"` and `"en-AU"` are excluded. query param name: includeRegionOptions | type: includeRegionOptions | description: Whether to include region-specific options such as flags and regional codes for each locale in the response. query param name: languageCode | type: languageCode | description: Language to filter by. For example, `"en"` for all English locales. Return type: ListSupportedLocalesResponse - name: supportedLocales | type: array | description: A list of all the locales that can be added to a site. - name: id | type: string | description: - name: languageCode | type: string | description: Language code. - name: regionCode | type: string | description: Region code. - name: defaultFlag | type: string | description: Default flag code for the locale. - name: defaultRegionalFormat | type: string | description: Default format for how to display data types such as dates, times, numbers, and currencies. - name: machineTranslationCode | type: string | description: Language code used when content is sent for machine translation. - name: displayName | type: string | description: Display name of the locale. - name: regionOptions | type: array | description: All flags and their regional formats per locale. - name: flag | type: string | description: Flag code of the region. - name: regionalFormat | type: string | description: Format for how to display data types such as dates, times, numbers, and currencies. ``` ### Examples ### List Supported Locales ```curl curl -X GET \ 'https://www.wixapis.com/locales//v2/locales/supported?languageCode=en&includeRegionOptions=true' \ -H 'Authorization: ' \ -H 'Content-Type: application/json' \ ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.localeManagement.SupportedLocalesService.listSupportedLocales(options) Description: Retrieves a list of all Wix-supported locales that can be added to a site. Call this method to display supported language details when creating or updating a locale. Method parameters: param name: options | type: ListSupportedLocalesOptions none - name: languageCode | type: string | description: Language to filter by. For example, `"en"` for all English locales. - name: includeAllLocales | type: boolean | description: Whether to include all possible regional variants for each language code in the response. When `false`, only the default locale, such as `"en-US"`, is returned and regional variants like `"en-GB"` and `"en-AU"` are excluded. - name: includeRegionOptions | type: boolean | description: Whether to include region-specific options such as flags and regional codes for each locale in the response. Return type: PROMISE - name: supportedLocales | type: array | description: A list of all the locales that can be added to a site. - name: _id | type: string | description: - name: languageCode | type: string | description: Language code. - name: regionCode | type: string | description: Region code. - name: defaultFlag | type: string | description: Default flag code for the locale. - name: defaultRegionalFormat | type: string | description: Default format for how to display data types such as dates, times, numbers, and currencies. - name: machineTranslationCode | type: string | description: Language code used when content is sent for machine translation. - name: displayName | type: string | description: Display name of the locale. - name: regionOptions | type: array | description: All flags and their regional formats per locale. - name: flag | type: string | description: Flag code of the region. - name: regionalFormat | type: string | description: Format for how to display data types such as dates, times, numbers, and currencies. ``` ### Examples ### listSupportedLocales ```javascript import { locales } from '@wix/multilingual'; async function listSupportedLocales(options) { const response = await locales.listSupportedLocales(options); }; ``` ### listSupportedLocales (with elevated permissions) ```javascript import { locales } from '@wix/multilingual'; import { auth } from '@wix/essentials'; async function myListSupportedLocalesMethod(options) { const elevatedListSupportedLocales = auth.elevate(locales.listSupportedLocales); const response = await elevatedListSupportedLocales(options); } ``` ### listSupportedLocales (self-hosted) Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md). ```javascript import { createClient } from '@wix/sdk'; import { locales } from '@wix/multilingual'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { locales }, // Include the auth strategy and host as relevant }); async function listSupportedLocales(options) { const response = await myWixClient.locales.listSupportedLocales(options); }; ``` ---