Skip to content

Commit d9a7616

Browse files
Add files via upload
1 parent 39a6edf commit d9a7616

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

test1.py

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,20 @@
11
from twilio.rest import Client
2+
from app import auth_token
23

3-
#auth_token = AccessToken('AC0d79e56293d4494c36eee4f48a59ff8e', 'SKeb5a25313bb48bd91b84eedbe6834520', 'bsamiAWrhwdHLCYpPNiy6Ch2t9WT1gAT', identity='PythonCovidBot')
44
account_sid = 'AC0d79e56293d4494c36eee4f48a59ff8e'
5-
auth_token = 'add1554bab0e843fabc0cf9bfcf4c99c'
5+
#auth_token = 'e28b70572daa7f80fe2bccb3b7357432'
66
client = Client(account_sid, auth_token)
77

8+
89
def send_message(message_, from_, to):
9-
print('whatsappFROM:' + from_)
10-
print('whatsappTO:' + to)
10+
print('whatsappFROM: ' + from_)
11+
print('whatsappTO: ' + to)
1112

1213
if 'w' in list(to):
1314
message = client.messages \
1415
.create(
1516
body=message_,
16-
from_="whatsapp:" + from_,
17+
from_="whatsapp:"+ from_,
1718
to=to
1819
)
1920
else:
@@ -32,4 +33,4 @@ def send_message(message_, from_, to):
3233
)'''
3334

3435

35-
send_message("Hi there", "+14155238886", "whatsapp:+19142822807")
36+
#send_message("Hi there", "+14155238886", 'whatsapp:+19142822807")

0 commit comments

Comments
 (0)