Return to Video

Setting Up Our Code - Programming Foundations with Python

  • 0:00 - 0:03
    Okay, let's begin writing code. Now, the first thing
  • 0:03 - 0:07
    I've done is created a new file called send_text.py. And
  • 0:07 - 0:09
    as you can see, this file is empty for now.
  • 0:10 - 0:13
    Then, if you go to Twilio's installation page, oh by
  • 0:13 - 0:15
    the way, this link is also available on the
  • 0:15 - 0:19
    instructor notes. If you scroll down on this page, you
  • 0:19 - 0:22
    will notice that Twilio has provided some sample code that
  • 0:22 - 0:26
    allows us to send text messages to our phone. Now,
  • 0:26 - 0:28
    I just want to run and see if this code
  • 0:28 - 0:32
    even works. If this program does work only then will
  • 0:32 - 0:34
    I try and understand how it actually sends a text
  • 0:34 - 0:38
    message to our phone. So, for now, all I'm going to do
  • 0:38 - 0:41
    is copy this code and go back to my syntax
  • 0:41 - 0:44
    program and paste that code. Okay, so it seems that
  • 0:44 - 0:48
    the code is importing Twilio. Although it is a little
  • 0:48 - 0:51
    different then what we have seen thus far, there is this
  • 0:51 - 0:53
    keyword here called from which we haven't seen
  • 0:53 - 0:56
    before, I will return to this later. Okay,
  • 0:56 - 1:01
    if you read the next two lines in the program they talk about account sid and
  • 1:01 - 1:05
    authorization token. Now, these must be for Twilio
  • 1:05 - 1:08
    to figure out who I am. Almost like
  • 1:08 - 1:10
    my username and password. So, let's go to
  • 1:10 - 1:13
    the Twilio website and figure out these two values.
タイトル:
Setting Up Our Code - Programming Foundations with Python
概説:

more » « less
Video Language:
English
Team:
Udacity
プロジェクト:
UD036 - OOP
Duration:
01:14

English subtitles

改訂 Compare revisions