getAppPopupSwitchConfig(data: GetAppPopupSwitchConfigParams)

版本要求:
@tuya-miniapp/cloud-api≥1.7.0

描述

获取弹窗开关配置(V2)

参数

参数类型必填说明
是请求参数

返回值

类型:Promise<GetAppPopupSwitchConfigResult>
GetAppPopupSwitchConfigResult

引用对象

typeGetAppPopupSwitchConfigResult弹窗开关配置
Record<string, unknown>

示例代码

请求示例

import { getAppPopupSwitchConfig } from '@tuya-miniapp/cloud-api';

getAppPopupSwitchConfig({ miniapp: 'xxx', ownerId: 'home_xxx' })
  .then(response => {
    console.log(response);
  })
  .catch(error => {
    console.error('获取弹窗开关配置(V2)失败:', error);
  });

返回示例

{ "switch": true }