---
name: "getPanelAgentConfigLanguageList"
mode: "api"
versionRequirements:
  - { name: "@tuya-miniapp/cloud-api", version: "1.0.6" }
---

## getPanelAgentConfigLanguageList

> [VERSION] @tuya-miniapp/cloud-api >= 1.0.6

> 💡 This API relies on cloud capabilities. Configure authorization in the [Mini App Developer Platform](https://platform.tuya.com/miniapp/) under Development Settings - Cloud Capabilities.

### Description

Get the list of supported languages.

### Parameters

`Params`

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `params` | `GetPanelAgentConfigLanguageListParams` | Yes | Request body |

### Return Value

Type: `Promise<Object[]>`

GetPanelAgentConfigLanguageListResult (see type definitions and minituya response parameters for field meanings)
| Property | Type | Description |
| --- | --- | --- |
| `langCode` | `string` | Language code |
| `langName` | `string` | Language name |
| `hasDefault` | `boolean` | Whether it is the default language |

### Referenced Types

##### `interface` GetPanelAgentConfigLanguageListParams

| Property | Type | Description |
| --- | --- | --- |
| `devId` | `string` | Device ID |


### Examples

#### Request example

```typescript
import { getPanelAgentConfigLanguageList } from '@tuya-miniapp/cloud-api';

const params = {
  devId: 'your_device_id',
};

getPanelAgentConfigLanguageList(params)
  .then(result => {
    console.log('Supported languages:', result);
  })
  .catch(error => {
    console.error('Failed to get language list:', error);
  });
```

#### Response example

```json
[
  {
    "langCode": "zh-CN",
    "langName": "Chinese (Simplified)",
    "hasDefault": true
  },
  {
    "langCode": "en-US",
    "langName": "English",
    "hasDefault": false
  }
]
```
