#! python3
# P05_textMyself.py - Defines the textmyself() function that texts a message
# passed to it as a string.

from twilio.rest import TwilioRestClient

# Preset values:
accountSID = ''
authToken = ''
myNumber = ''
twilioNumber = ''


def textmyself(message):
    twilioCli = TwilioRestClient(accountSID, authToken)
    twilioCli.messages.create(body=message, from_=twilioNumber, to=myNumber)
    return None

@@ -169,16 +169,56 @@
 values:%0A
+with open('twilio_info') as config:%0A    
 accountS
@@ -219,22 +219,18 @@
 countSID
+,
  
-= ''%0A
 authToke
@@ -234,45 +234,61 @@
 oken
- = ''%0AmyNumber = ''%0AtwilioNumber = ''
+, twilioNumber, myNumber = config.read().splitlines()
 %0A%0A%0Ad

Update P05_textMyself get credentials from file