0
在下面的代碼中,iot.listCertificates執行完美,我能夠在AWS IOT控制檯中看到所有證書,但是當我嘗試執行命令iot.createKeysAndCertificate時,它會給我提供NETWORK FAILURE ERROR。AWS IOT createKeysAndCertificate給出網絡失敗錯誤
請幫我這個, 謝謝!
var params = {};
iot.listCertificates(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
alert("Attempting to create new thing!!");
params = {
setAsActive:false
};
iot.createKeysAndCertificate(params, function(err, data) {
if (err)
alert(err);
else
alert("New thing added to AWS IOT");
});