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

## getPanelAgentConfigRoleVariableList

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

> 💡 接口依赖云能力，需在 [小程序开发者平台](https://platform.tuya.com/miniapp/)开发设置 - 云能力 进行授权配置。

### 描述

获取角色变量配置列表。

### 参数

`Params`

| 参数 | 类型 | 必填 | 默认值 | 描述 |
| --- | --- | --- | --- | --- |
| `params` | `GetPanelAgentConfigRoleVariableListParams` | 是 | - | 请求体 |

### 引用对象

##### `interface` GetPanelAgentConfigRoleVariableListParams

| 属性 | 类型 | 描述 |
| --- | --- | --- |
| `devId` | `string` | 设备ID |


### 示例代码

#### 请求示例

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

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

getPanelAgentConfigRoleVariableList(params)
  .then(result => {
    console.log('角色变量配置列表:', result);
  })
  .catch(error => {
    console.error('获取角色变量配置列表失败:', error);
  });
```

#### 返回示例

```json
[
  {
    "variableKey": 1001,
    "variableDesc": "设备名称"
  },
  {
    "variableKey": 1002,
    "variableDesc": "用户昵称"
  }
]
```
