在线等回复 云调用手机号怎么用啊?文档介绍的不详细,大神救命!

小程序 文章 2022-01-18 17:40 357 0 全屏看文

AI助手支持GPT4.0

在线等回复 云调用手机号怎么用啊?文档介绍的不详细,大神救命!Waiting for a reply online How to use the cloud to call the mobile phone number? The documentation is not detailed, God help!

在线等回复 云调用手机号怎么用啊?文档介绍的不详细,大神救命!


云函数中具体怎么使用 openapi.phonenumber.getPhoneNumber     ,大神救命啊~~~~~~


How to use OpenAPI in cloud functions phonenumber. Getphonenumber, God help~~~~~~

回答:

Mr.Zhao:
比葫芦画瓢啊await cloud.openapi.phonenumber.getPhoneNumber({  code: event.code})
謝勃 Adam Shieh:openapi.phonenumber.getPhoneNumber 这个不好使,errCode: -604100 API not found 提示,API不存在。。。。。
不如吃茶去:

这个api好不知道能不能用


謝勃 Adam Shieh:感觉不怎么好使
brave:

config.json 里填写 "openapi.phonenumber.getPhoneNumber"前端通过<button open-type="getPhoneNumber" bindgetphonenumber="getPhoneNumber">getPhoneNumber</button>获取到cloudID调用云函数wx.cloud.callFunction({  name: "getPhoneNumber",  data: {     weRunData: wx.cloud.CloudID(e.detail.cloudID)  },  complete: console.log})
謝勃 Adam Shieh:cloud里怎么写?
謝勃 Adam Shieh:errCode: -604100 API not found  提示,API不存在。。。。。
謝勃 Adam Shieh:好像就是API的事,悲催~~~~
謝勃 Adam Shieh:config.json 里填写 phonenumber.getPhoneNumber
謝勃 Adam Shieh:也不行
不如吃茶去:exports.main = async (event, context) => {
  const res = await cloud.getOpenData({
    list: [event.cloudID]
  });
  return res;
}

-EOF-

AI助手支持GPT4.0