<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Rkauff</title>
    <description>The latest articles on Forem by Rkauff (@rkauff).</description>
    <link>https://forem.com/rkauff</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F176555%2Fc4796554-ba41-4c21-b13f-b37dfcca5ada.jpeg</url>
      <title>Forem: Rkauff</title>
      <link>https://forem.com/rkauff</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/rkauff"/>
    <language>en</language>
    <item>
      <title>Teacher's Little Helper</title>
      <dc:creator>Rkauff</dc:creator>
      <pubDate>Wed, 22 Apr 2020 16:51:18 +0000</pubDate>
      <link>https://forem.com/twilio/teacher-s-little-helper-15ib</link>
      <guid>https://forem.com/twilio/teacher-s-little-helper-15ib</guid>
      <description>&lt;p&gt;My wife Teaches 5th grade, and is currently e-Teaching from home due to Covid-19. They use lots of Google Sheets for various assignments. She needed a way for her students to let her know they need help. She can’t monitor them all simultaneously, so I used some Google Apps Script, Twilio, AWS API and AWS Lambda to help. The students click on a button in a Google sheet if they need help, and she gets a text message letting her know.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Goal&lt;/strong&gt;:&lt;br&gt;
This is actually really easy to build, so I want to show you how I did it, in order for you to recreate yourself, or for any of the Teachers in your life.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/WZ4M8M2VbauEo/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/WZ4M8M2VbauEo/giphy.gif" alt="lets begin"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Tech Stack&lt;/strong&gt;:&lt;br&gt;
&lt;a href="https://www.twilio.com/sms" rel="noopener noreferrer"&gt;Twilio SMS&lt;/a&gt;: To send a text message.&lt;br&gt;
&lt;a href="https://www.google.com/sheets/about/" rel="noopener noreferrer"&gt;Google Sheets&lt;/a&gt;: What the Students see, the User Interface.&lt;br&gt;
&lt;a href="https://developers.google.com/apps-script" rel="noopener noreferrer"&gt;Google Apps Script&lt;/a&gt;: The "trigger" that will execute this app.&lt;br&gt;
&lt;a href="https://aws.amazon.com/api-gateway/" rel="noopener noreferrer"&gt;AWS API&lt;/a&gt;: The "front door" to the cloud that connects the Google Sheet to the Lambda.&lt;br&gt;
&lt;a href="https://aws.amazon.com/lambda/" rel="noopener noreferrer"&gt;AWS Lambda&lt;/a&gt;: The "logic", also known as the serverless environment to hold our Python code.&lt;br&gt;
&lt;a href="https://www.python.org/downloads/release/python-382/" rel="noopener noreferrer"&gt;Python version 3.8&lt;/a&gt;: The language we will write our code in.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Create a Twilio account and select your phone number&lt;/strong&gt;&lt;br&gt;
The first thing to do is sign up for a &lt;a href="//www.twilio.com/referral/872AjC"&gt;Twilio&lt;/a&gt; account. Sign up for free using this &lt;a href="//www.twilio.com/referral/872AjC"&gt;link&lt;/a&gt; and receive a $10 account credit. Once you've signed up, buy a &lt;a href="https://www.twilio.com/console/phone-numbers/search" rel="noopener noreferrer"&gt;phone number&lt;/a&gt;. &lt;em&gt;Make a note of the phone number you’ve bought, your Account SID, and your Auth Token. You’ll need them all later.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Ftwilio-cms-prod.s3.amazonaws.com%2Fimages%2F23aM_64fcvL3L1v_8Qabb3EDaSwB9AUJ4IdZtrvZo5nGJe.width-800.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Ftwilio-cms-prod.s3.amazonaws.com%2Fimages%2F23aM_64fcvL3L1v_8Qabb3EDaSwB9AUJ4IdZtrvZo5nGJe.width-800.png" alt="phone number"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Create an AWS Account&lt;/strong&gt;&lt;br&gt;
Even if you already have an Amazon account or Prime membership, you will need to create a new &lt;a href="https://aws.amazon.com" rel="noopener noreferrer"&gt;AWS login&lt;/a&gt;, because it is separate from the rest of Amazon.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Ftwilio-cms-prod.s3.amazonaws.com%2Fimages%2F2JM2NaG8wOF_yq3spSjQBNQiOF5413TK4Q1A6iSdyJrJ1q.width-800.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Ftwilio-cms-prod.s3.amazonaws.com%2Fimages%2F2JM2NaG8wOF_yq3spSjQBNQiOF5413TK4Q1A6iSdyJrJ1q.width-800.png" alt="AWS Account"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once you've created your AWS account, you will need to create a Lambda function. Don't worry if you've never done this before, it's actually pretty simple. Just go to the &lt;a href="https://aws.amazon.com/lambda/" rel="noopener noreferrer"&gt;Lambda&lt;/a&gt; service, and click on "Create Function."&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdasample.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdasample.PNG" alt="teacher lambda"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Select "Author From Scratch"&lt;/li&gt;
&lt;li&gt;Type a "Function Name" (this is whatever you want to call your function, it can be anything)&lt;/li&gt;
&lt;li&gt;Enter a "Runtime" (I used Python 3.8, but any 3.x will work) &lt;/li&gt;
&lt;li&gt;Go to "Permissions" and click "Create a new role with basic Lambda permissions." This lets AWS set it up for you, which is a good idea, unless you're an experienced user.&lt;/li&gt;
&lt;li&gt;Click on "Create Function" on the bottom right hand side of the page.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2F1.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2F1.PNG" alt="teacher lambda1"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This will bring you into the Lambda configuration. Paste the code below to your Lambda. You can also find this code on &lt;a href="https://github.com/Rkauff/twilio-dev-hackathon/blob/master/lambda_handler.py" rel="noopener noreferrer"&gt;Github&lt;/a&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;    &lt;span class="c1"&gt;#import the twilio module
&lt;/span&gt;    &lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;twilio.rest&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Client&lt;/span&gt;

    &lt;span class="c1"&gt;#define your lambda function
&lt;/span&gt;    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;lambda_handler&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;

        &lt;span class="c1"&gt;#enter your account details here
&lt;/span&gt;        &lt;span class="n"&gt;account_sid&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;paste your twilio account SID here&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
        &lt;span class="n"&gt;auth_token&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;paste your twilio auth token here&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;

        &lt;span class="n"&gt;client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Client&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;account_sid&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;auth_token&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="n"&gt;message&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;create&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;to&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;+The phone number you want to send the message to here&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;from_&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;+The twilio phone number you bought earlier here&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;body&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Mrs. Kauffman, I need some help.&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It should look like this when you're done: &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdasample3.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdasample3.PNG" alt="teacher lambda2"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Make sure to add your own Twilio Account SID, Twilio Auth Token, Twilio phone number that you bought earlier, and the phone number that you want the text message to go to in your code.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Click "Save" in the top right hand corner. Your Lambda is done, but there is one more thing you need to do here. Since we are editing the code inline, we need to handle the Twilio dependency. There are essentially two main ways to use Lambda. We could build our own zip file, details on how to do that &lt;a href="https://www.twilio.com/blog/help-button-python-aws-iot-aws-lambda-twilio-wireless" rel="noopener noreferrer"&gt;here&lt;/a&gt;. Alternatively, we can write the code inline, and use Lambda Layers for dependencies. For simplicity, we are going to Layer our Lambda function.&lt;/p&gt;

&lt;p&gt;Click on "Layers" below "kristins-lambda-function" in my example. Then click "Add a layer."&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdalayer2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdalayer2.png" alt="lambda layer 2"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Click "Provide a layer version ARN" and paste &lt;a href="https://github.com/keithrozario/Klayers/blob/master/deployments/python3.8/arns/us-west-2.csv" rel="noopener noreferrer"&gt;Keith Rozario's&lt;/a&gt; Twilio layer:&lt;/p&gt;

&lt;p&gt;aws_lambda_us-west-2_770693421928_layer_Klayers-python38-twilio_7&lt;/p&gt;

&lt;p&gt;This ARN is specific to the us-west-2 region, so if you have difficulty here, double check that you're region in the "Oregon" region.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FCapture2.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FCapture2.PNG" alt="region"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Click "Add."&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdalayer.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Flambdalayer.png" alt="lambda layer"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Congrats! Your Lambda function is ready to go!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/pa37AAGzKXoek/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/pa37AAGzKXoek/giphy.gif" alt="yay"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Now we need a way to trigger the Lambda function. That's where the AWS API Gateway comes in.&lt;/p&gt;

&lt;p&gt;In "Services", find the "API Gateway," then click "Create API."&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fapisample.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fapisample.PNG" alt="teacher api"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Scroll down to find "REST API," and click "Build." &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2F4.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2F4.PNG" alt="rest api"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;From here, select "REST," "New API," Give your API a name, Description, and use "Regional" for Endpoint Type, and click "Create API."&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-21_154557_us-west-2.console.aws.amazon.com.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-21_154557_us-west-2.console.aws.amazon.com.png" alt="api3"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Next, you need to create a method, so under the Actions dropdown menu, click on "Create Method," then use "Post," and then click the check mark.&lt;/p&gt;

&lt;p&gt;In the "Post" method, you want to select "Lambda Integration," your region (I'm using US-West-2 for this tutorial), and the ARN (Amazon Resource Number), or the &lt;em&gt;name&lt;/em&gt; of the Lambda Function you just created. Either way works. I'm using the name of my Lambda function here. Hit Save.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-21_215828_us-west-2.console.aws.amazon.com.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-21_215828_us-west-2.console.aws.amazon.com.png" alt="api 3"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It will give you a warning: "You are about to give API Gateway permission to invoke your Lambda function:" &lt;/p&gt;

&lt;p&gt;Click OK.&lt;/p&gt;

&lt;p&gt;It should look like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fapisample2.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fapisample2.PNG" alt="teacher api2"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Nice work! You just built your API, now you just need to Deploy it. You do this by clicking on "Actions", then "Deploy API." You can use "New Stage" as your Deployment Stage, then come up with a Stage Name (I usually call it "Prod", but feel free to call it anything you want, it's your API). Then hit "Deploy."&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-21_222328_us-west-2.console.aws.amazon.com.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-21_222328_us-west-2.console.aws.amazon.com.png" alt="deploy API"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Awesome, your API is live!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/l3UcA1HpL5kLuiWOc/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/l3UcA1HpL5kLuiWOc/giphy.gif" alt="nice job"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The only thing left to do is build your trigger in the Teacher's Google Sheet. &lt;/p&gt;

&lt;p&gt;In the Google Sheet, click on "Tools," then "Script Editor." &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fgoogledoc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fgoogledoc.png" alt="google doc"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Paste this simple function into your Google App Script Editor. &lt;em&gt;You will need to change it to be the API endpoint you just created, otherwise your Google sheet will be trying to call my API.&lt;/em&gt;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;function doPost() {
  UrlFetchApp.fetch("https://git4xk3aif.execute-api.us-west- 
  2.amazonaws.com/Prod/kristins-lambda-function", {muteHttpExceptions: 
  true});
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;It should look something like this (modified with your API):&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fgoogleappscript.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fgoogleappscript.png" alt="google app script"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Save your script by hitting Ctrl + S. Then you can close out of the script editor.&lt;/p&gt;

&lt;p&gt;In your Google Sheet, you need a button that will serve as the trigger for your students to press, in case they need your assistance. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-22_122707_docs.google.com.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-22_122707_docs.google.com.png" alt="inserting a picture"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;And then upload any picture you like. I've used one of my favorite pictures of my wife.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FCapture5.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FCapture5.PNG" alt="kristin"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Way to go, you just inserted a picture into your Google Sheet. Now you need to turn that picture into a button that &lt;em&gt;does something&lt;/em&gt;. &lt;/p&gt;

&lt;p&gt;You can do this by right-clicking anywhere in the image, and then left-clicking in the top right hand corner of the picture (where the red arrow is in the image below). Then click on "Assign Script," and assign the script that you created in your Google Script above.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-22_231322_docs.google.com.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FOpera%2BSnapshot_2020-04-22_231322_docs.google.com.png" alt="assign script"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Type "doPost" in the box, and click OK.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FCapture6.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2FCapture6.PNG" alt="assign script 2"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The first time you click your new button, you will most likely be prompted to give your Google script access, details on how to do that are &lt;a href="https://developers.google.com/apps-script/guides/services/authorization" rel="noopener noreferrer"&gt;here&lt;/a&gt;. It's pretty straightforward.&lt;/p&gt;

&lt;p&gt;Now, when her students click anywhere on that picture, she receives this text message from Twilio.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fteacher%2Btext.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fteacher-stuff.s3-us-west-2.amazonaws.com%2Fteacher%2Btext.jpg" alt="teacher text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You're done!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/xUOwG28DNal5A63KEg/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/xUOwG28DNal5A63KEg/giphy.gif" alt="done"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F370okk7q7n4o4vayhdfg.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F370okk7q7n4o4vayhdfg.gif" alt="done2"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you have any questions, feel free to reach out to me on Twitter &lt;a href="https://twitter.com/RyanKauffman80" rel="noopener noreferrer"&gt;@ryankauffman80&lt;/a&gt;, &lt;a href="https://www.linkedin.com/in/ryan-kauffman-mba-2108227/" rel="noopener noreferrer"&gt;LinkedIn&lt;/a&gt;, or send me an email at &lt;a href="//koontz2k4@gmail.com"&gt;koontz2k4@gmail.com&lt;/a&gt;. &lt;/p&gt;

&lt;p&gt;I'm a Twilio Champion, so if you want to check out any of the blog posts I've written for the Twilio blog, you can see them &lt;a href="https://www.twilio.com/blog/author/rkauffman" rel="noopener noreferrer"&gt;here&lt;/a&gt;! We can't wait to see what you &lt;a href="//www.twilio.com/referral/872AjC"&gt;build&lt;/a&gt;!&lt;/p&gt;

</description>
      <category>python</category>
      <category>twiliohackathon</category>
      <category>aws</category>
    </item>
    <item>
      <title>Hi! </title>
      <dc:creator>Rkauff</dc:creator>
      <pubDate>Thu, 06 Jun 2019 03:01:50 +0000</pubDate>
      <link>https://forem.com/rkauff/hi-4dff</link>
      <guid>https://forem.com/rkauff/hi-4dff</guid>
      <description>&lt;p&gt;Hi, I just signed up for dev.to a minute ago, and am looking for fellow Pythonista’s to chat with. :)&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
