Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

20
LINES

< > BotCompany Repo | #1028424 // Twilio Send SMS Test [OK]

JavaX source code (desktop) [tags: use-pretranspiled] - run with: x30.jar

Download Jar. Uses 10012K of libraries. Click here for Pure Java version (2711L/16K).

lib 1400402 // twilio

import com.twilio.Twilio;
import com.twilio.rest.api.v2010.account.Message;
import com.twilio.type.PhoneNumber;

// args: Account Sid, Auth Token (see twilio.com/console)
//       & phone number to send from (.e.g. +1...)
//       & phone number to send to (e.g. +1123...)
p {
  Twilio.init(args[0], args[1]);

  Message message = Message
          .creator(new PhoneNumber(args[3]), // to
                  new PhoneNumber(args[2]), // from
                  "Whazzup Eric this is a bot")
          .create();

  print(message.getSid());
}

download  show line numbers  debug dex  old transpilations   

Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv

No comments. add comment

Snippet ID: #1028424
Snippet name: Twilio Send SMS Test [OK]
Eternal ID of this version: #1028424/5
Text MD5: 1902b8f7024e1b344333b9f5bddd9bee
Transpilation MD5: 603acc9c580ce87af34bc125148548d4
Author: stefan
Category: javax / web chat bots
Type: JavaX source code (desktop)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-12-22 23:43:43
Source code size: 584 bytes / 20 lines
Pitched / IR pitched: No / No
Views / Downloads: 131 / 612
Version history: 4 change(s)
Referenced in: [show references]