Interface TwilioServiceClient

  • All Known Implementing Classes:
    TwilioServiceClientImpl

    public interface TwilioServiceClient
    The Twilio service client.
    • Method Detail

      • sendMessage

        Task<Void> sendMessage​(@NonNull
                               String to,
                               @NonNull
                               String from,
                               @NonNull
                               String body)
        Sends an SMS/MMS message.
        Parameters:
        to - the number to send the message to.
        from - the number that the message is from.
        body - the body text of the message.
        Returns:
        a task that completes when the send is done.
      • sendMessage

        Task<Void> sendMessage​(@NonNull
                               String to,
                               @NonNull
                               String from,
                               @NonNull
                               String body,
                               @NonNull
                               String mediaUrl)
        Sends an SMS/MMS message.
        Parameters:
        to - the number to send the message to.
        from - the number that the message is from.
        body - the body text of the message.
        mediaUrl - the URL of the media to send in an MMS.
        Returns:
        a task that completes when the send is done.