sendScheduledSms method

Future<int> sendScheduledSms({
  1. required String toNumber,
  2. required String messageBody,
  3. required String sendAt,
})

sendScheduledSms toNumber : The number to which sms message has to be sent. messageBody : The content of the message to be sent. sendAt : Time at which the sms has to be sent (Minimum 15 minutes after current time) Method called to send scheduled sms messages to the specified phone number with given content. This requires a Messaging service SID registered with twilio and it has to be passed in while creating TwilioFlutter. Returns 201 -> message scheduled successfully.

For more status codes refer

Implementation

Future<int> sendScheduledSms(
    {required String toNumber,
    required String messageBody,
    required String sendAt}) async {
  return await _smsService.sendScheduledSms(
      toNumber: toNumber,
      messageBody: messageBody,
      twilioCreds: _twilioCreds,
      sendAt: sendAt);
}