Envie SMS usando Twilio no nó
const smsSid = process.env.SMS_SID
const smsAuthToken = process.env.SMS_AUTH_TOKEN
const twilio = require('twilio')(smsSid, smsAuthToken, {
lazyLoading: true,
});
async sendBySms(phone, otp) {
return await twilio.messages.create({
to: phone,
from: process.env.SMS_FROM_NUMBER,
body: `Your codershouse OTP is ${otp}`,
});
}
Shirshak kandel