Video Chat app using Gatsby and twilio-2

Welcome to part-2 of the series. You can find part-1 here.

We will continue our journey to build a simple video chat app with twilio api, for the dev.to hackathon.

We had logged into the twilio dashboard in part-1. Now, click on the three dots on the left menu as in the screenshot below.

Image for post
Image for post
Three dots

Next, click on Programmable Video in the menu.

Image for post
Image for post
Programmable Video

In the next screen we have to click on Show API Credentials link.

Image for post
Image for post
Show API Credentials

From the next page note down your ACCOUNT SID and AUTH TOKEN.

Image for post
Image for post
Credentials

Now, time to put both the secrets in a .env file. Create a .env file in the root directory and put ACCOUNT SID and AUTH TOKEN into, TWILIO_ACC_SID and TWILIO_AUTH_TOKEN variables.

Image for post
Image for post
.env

Then click on Tools in the left menu.

Image for post
Image for post
Tools

After that click on the API Keys sub-menu link. Next, we have to click on Create new API Key button.

Image for post
Image for post
API Keys

In the next screen, we have to give the API key a name and then click on Create API Key button.

Image for post
Image for post
Name

After that in the next screen, we will be shown the SID and SECRET. We need to note them both.

Image for post
Image for post
Secret

Then click on the checkbox and the Done button.

Image for post
Image for post
Checkbox

After that in the next screen our secret won’t be shown. And this means our API Keys are saved.

Image for post
Image for post
Saved

Next, again go to the .env file and save these two variables.

Image for post
Image for post
.env

The settings of API keys took a lot of time, so we will start with twilio functions in the next part. You can find part-3 here.

You can also find the code for this project in this github link.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store