请问微信小程序里面如何发送短信呢?这样写有问题吗?

Glory3
2019-02-28 09:53 1.2k 0

wx.request({
url: 'https://api.sms.jpush.cn/v1/codes',
method:'post',
header: {
'Content-Type': 'json',
'Authorization': sgin
},
data:{
mobile:phoneInValue,
temp_id:1
},
success:res => {
console.log(res)
}
})

1个回答

热门排序
  • 这个 API 是服务端调用的,你 web 端调用可能存在跨域问题吧

    你现在这样请求是成功了还是报错了,报什么错