.getShareTemplates
一、概述
开发者可通过这个接口接收保存在天幕上的分享素材相关数据。
使用该接口前,请先进行SDK初始化
二、调用方法
wx.tmSDK.getShareTemplates().then((res) => {
console.log(res);
})
三、返回值样例
{
"scene_1":[{
"channel_code": "channelA", //渠道码
"title":"分享标题",
"image":"分享图片",
"path":"pages/index/index", //跳转小程序路径
"scene":"scene_1", //使用的分享位ID
}],
"scene_2":[{
"channel_code": "channelB", //渠道码
"title":"分享标题",
"image":"分享图片",
"path":"pages/index/index", //跳转小程序路径
"scene":"scene_2", //使用的分享位ID
}]
}
四、返回值详解
字段
字段类型
字段说明
channel_code
String
分享渠道码
title
String
分享标题
image
String
分享图片地址
path
String
跳转小程序路径
scene
String
分享位ID
最后更新于