WEBVTT

00:01.440 --> 00:10.160
If you want to use Google services like Gmail, Google Drive Sheets, docs in your n810 agents and automation,

00:10.480 --> 00:12.040
you have to set up credentials.

00:13.000 --> 00:20.680
So if you are using the paid cloud version of N810, it's very simple.

00:24.120 --> 00:27.240
You just need to sign in using your email account.

00:28.720 --> 00:30.200
So I'm going to show you how.

00:32.360 --> 00:32.720
And.

00:36.960 --> 00:44.400
Basically every time when you want to use Google Apps let's say Gmail.

00:46.840 --> 00:48.640
And we want to use a trigger.

00:52.440 --> 00:56.880
We need to create a new credential and simply sign in with Google.

00:58.720 --> 01:05.730
And your credentials will be automatically saved for the next workflows, so you don't need to do it

01:05.730 --> 01:06.730
over and over again.

01:07.850 --> 01:12.130
But if you are self-hosting n810, you have to stop credentials manually.

01:12.530 --> 01:15.290
And in the next part of this tutorial, I will show you exactly how.

01:16.810 --> 01:22.370
Now, once you successfully sign in to your Google account, it will automatically create credentials

01:22.370 --> 01:27.850
for you and there is a different way to access all your credentials in one place.

01:28.170 --> 01:29.290
Just go to overview.

01:32.650 --> 01:33.730
Click on credentials.

01:36.250 --> 01:38.090
And here you can manage credentials.

01:38.090 --> 01:40.690
So all your accounts connected to your N810 instance.

01:41.570 --> 01:43.210
Now here is something important.

01:43.690 --> 01:49.330
If you are using N810 cloud subscription, you still need to setup credentials for Google Drive manually

01:49.770 --> 01:51.530
by following the rest of this tutorial.

01:55.090 --> 02:02.220
Now I'm in my non self-hosted N810 instance, so for this N810 account I pay for the subscription.

02:02.660 --> 02:05.900
As you can see, if I want to create credential.

02:08.020 --> 02:11.460
It's still asking me for client ID and client secret.

02:11.900 --> 02:13.780
So I have to set up credentials manually.

02:14.580 --> 02:22.220
This is specifically required for the Google Drive for other Google services, and they can make it

02:22.220 --> 02:22.900
easy.

02:22.940 --> 02:27.420
You can simply sign in and Nathan will create the credentials for you automatically.

02:28.180 --> 02:35.700
If you pay for the services and you don't need to sign in over and over again, sometimes it might ask

02:35.700 --> 02:38.580
you to log in again to refresh your credentials.

02:39.620 --> 02:45.580
So whether you are using Nathan Cloud or self-host it yourself, if you want to access Google Drive,

02:45.980 --> 02:49.020
you are gonna need to follow this credential setup steps.

02:50.380 --> 02:57.460
Also, I've prepared a nice PDF guide that's way easier to follow than the official Nathan documentation.

02:57.900 --> 03:03.350
So apart from this video, what I'm showing you exactly how to setup credentials manually.

03:03.390 --> 03:06.190
For Google apps, you can always use that guide.

03:07.790 --> 03:10.110
You will find it in the resources section of this lesson.

03:11.510 --> 03:18.550
Now I'm in the self-hosted instance, and if I want to use Google services such as Gmail, Google Sheets,

03:18.630 --> 03:19.310
Google Drive.

03:20.230 --> 03:25.790
As you can see, when I want to create a new credential, I can just simply sign in.

03:26.030 --> 03:28.590
I need to provide client ID and client secret.

03:33.230 --> 03:34.750
Now let's check Google Sheets.

03:37.510 --> 03:38.070
The same.

03:42.590 --> 03:46.190
Google drive we want to connect to Google Drive.

03:47.190 --> 03:48.710
So we need to create a credential.

03:49.310 --> 03:51.950
And yes we need to provide client ID and client secret.

03:56.590 --> 04:01.190
So recently Google has changed the user interface slightly.

04:01.910 --> 04:05.330
So The Google Cloud Console looks different.

04:05.650 --> 04:11.210
So I'm going to show you how to set up credentials manually if you are self-hosting N810.

04:13.330 --> 04:19.730
First of all, you can always go to the documentation, which is great by the way.

04:20.090 --> 04:24.610
Open docs and follow this guide step by step.

04:31.050 --> 04:34.250
But I'm going to show you how to do it in this video.

04:34.610 --> 04:35.610
It will be easier for you.

04:36.530 --> 04:41.130
Yes, Google recently updated their interface so the process looks a bit different now.

04:41.530 --> 04:43.090
Let's walk you through step by step.

04:43.490 --> 04:49.410
So first let's go to Console.cloud.google.com and sign in to your account.

04:50.370 --> 04:53.650
The first thing we need to do is to create a new project.

04:54.570 --> 04:55.410
So right here.

04:57.450 --> 04:59.290
You can create new project.

05:03.980 --> 05:04.740
Give it a name.

05:13.380 --> 05:14.540
And press create.

05:18.780 --> 05:21.900
If you can see this this is under notifications.

05:24.260 --> 05:25.940
Select the project just created.

05:28.380 --> 05:30.060
Make sure you are in the right project.

05:30.060 --> 05:32.340
So in my case it's credentials demo.

05:34.180 --> 05:38.540
Now we need to enable the for example Google Sheets API.

05:39.300 --> 05:41.980
So let's say let's search for Google Sheets.

05:51.500 --> 05:52.260
Click enable.

05:55.460 --> 05:57.020
The API is now enabled.

05:57.380 --> 05:59.700
So next we need to create credentials.

06:00.100 --> 06:01.900
So click create credential.

06:02.980 --> 06:04.470
Under credentials right here.

06:05.190 --> 06:06.270
Create credentials.

06:08.550 --> 06:11.950
Select user data and hit next.

06:12.950 --> 06:13.950
Now give it a name.

06:15.390 --> 06:17.470
I will call mine N810.

06:19.670 --> 06:20.870
Data integration.

06:24.270 --> 06:25.550
Now user support email.

06:26.110 --> 06:27.510
So provide your email address.

06:33.390 --> 06:36.510
Now the same for the developer contact information.

06:40.070 --> 06:40.630
Perfect.

06:42.070 --> 06:43.190
Save and continue.

06:46.270 --> 06:47.790
Next this is really important step.

06:47.790 --> 06:49.190
We have to provide scopes.

06:49.750 --> 06:55.950
So scopes express the permissions that you request users to authorize for your app and allow your project

06:55.950 --> 06:59.590
to access specific types of private user data from the Google account.

07:01.310 --> 07:06.960
So click on Add or remove scopes And search for Google Sheets.

07:07.160 --> 07:19.320
Just scroll down, change rows per page to 100, scroll down and tick all these boxes related to Google

07:19.320 --> 07:19.800
Sheets.

07:24.280 --> 07:27.720
When I perfect click update.

07:27.760 --> 07:33.240
So in short, these are the permissions for what our app can do with Google Sheets.

07:36.520 --> 07:41.800
Of course, you can read what each one does and deselect any you don't need for security reasons.

07:43.680 --> 07:51.760
But as you can see, you allow any tend to see, edit, create and delete files and so on.

07:53.720 --> 07:55.680
Now let's save and continue.

07:57.800 --> 07:59.440
Let's choose web application.

08:01.160 --> 08:03.160
You can leave the name as it is or change it.

08:04.800 --> 08:05.850
Now this is really important.

08:05.850 --> 08:07.290
We need to add URL.

08:08.650 --> 08:11.490
So we need to go back to our workflow.

08:18.890 --> 08:20.050
Let's open Google Sheets.

08:21.210 --> 08:24.890
If you remember we enabled Google Sheets so far.

08:26.770 --> 08:28.850
So let's create new credential.

08:32.290 --> 08:35.090
And now we need to copy this auth redirect URL.

08:37.610 --> 08:39.450
Go back to our Google Console.

08:42.050 --> 08:44.610
URL and paste it right here.

08:48.170 --> 08:48.970
Let's create.

08:53.810 --> 08:54.730
This very moment.

08:56.570 --> 08:56.850
Yes.

08:56.850 --> 09:01.690
So by doing this we configured our OAuth client.

09:03.410 --> 09:04.450
So it's done for now.

09:07.660 --> 09:10.140
Now let's go to credentials on the left hand side.

09:13.820 --> 09:16.340
You will see the credentials we just created.

09:18.140 --> 09:21.940
So click on edit Edit Auth client.

09:25.100 --> 09:26.660
First copy the client ID.

09:30.940 --> 09:32.140
Switch over 2010.

09:34.980 --> 09:36.100
And paste it right here.

09:38.620 --> 09:41.220
Now we need to provide client secret.

09:44.780 --> 09:48.980
So scroll down copy client secret.

09:51.420 --> 09:56.140
Go to return and paste it right here and hit save.

10:00.660 --> 10:01.020
Right.

10:01.020 --> 10:03.180
As you can see credentials successfully created.

10:04.220 --> 10:05.660
And now this button pops up.

10:06.630 --> 10:07.790
for signing with Google.

10:09.870 --> 10:10.790
So click on it.

10:13.190 --> 10:16.470
Now select the Google account you want to use with Google Sheets.

10:20.270 --> 10:21.230
So that's normal.

10:21.270 --> 10:27.230
We need to add ourselves as a test user as as you can see.

10:27.270 --> 10:28.070
Access blocked.

10:29.310 --> 10:32.710
So let's go to our Google Cloud Console again.

10:35.430 --> 10:36.590
And add an audience.

10:39.350 --> 10:39.870
All right.

10:39.870 --> 10:42.190
So now I'm going to click Get Started.

10:45.870 --> 10:47.790
It's going to ask us a few questions.

10:47.790 --> 10:50.230
So the first thing name of your app.

10:50.550 --> 10:52.550
So I'm just going to call mine N810.

10:54.390 --> 10:56.430
But you can name it whatever you want.

10:56.950 --> 11:00.630
For the email you should only have one option here.

11:00.630 --> 11:02.070
So just select your email.

11:03.350 --> 11:04.070
Hit next.

11:06.070 --> 11:08.280
Now for user type, I'm choosing external.

11:09.040 --> 11:14.520
This basically means we can add external test users to our application, which we'll need later.

11:15.000 --> 11:18.800
We will add ourselves first, but you can add other people later too.

11:19.880 --> 11:21.160
Now press next.

11:23.440 --> 11:24.880
Google needs a support email.

11:24.880 --> 11:25.920
Just add your email.

11:26.680 --> 11:29.520
So we're gonna do the same.

11:38.360 --> 11:39.080
Hit next.

11:42.040 --> 11:43.600
Then agree to the terms of service.

11:46.360 --> 11:48.840
Continue and create.

11:49.840 --> 11:53.400
If you get lost at any point just click the hamburger button.

11:55.000 --> 11:56.800
Then go to APIs and services.

11:59.400 --> 12:00.960
Then all of Constant Screen.

12:02.200 --> 12:03.880
And here you can select audience.

12:05.280 --> 12:06.120
Scroll down.

12:10.180 --> 12:16.580
Click Add Users and at the same email address you are using for this connection.

12:18.780 --> 12:22.700
In my case, N810 gmail.com.

12:25.420 --> 12:26.020
Save.

12:27.220 --> 12:29.380
And now when I test the connection again.

12:33.140 --> 12:34.140
Sign in with Google.

12:40.700 --> 12:43.660
Now you will see Google has verified this app.

12:44.180 --> 12:45.540
So click on continue.

12:51.900 --> 12:53.100
Select all the scopes.

12:55.940 --> 12:56.820
And confirm.

13:00.180 --> 13:00.580
Right.

13:00.620 --> 13:01.460
Got connected.

13:03.420 --> 13:09.830
Now that you know how to connect Google Sheets, you can use the same Credentials for other Google services

13:10.270 --> 13:14.270
like Gmail, Google Calendar, or Google Docs.

13:14.990 --> 13:19.270
The only difference is you will need to enable the specific API for each service.

13:20.230 --> 13:28.670
So let's go to our Google Cloud Console and under the specific project, search for Gmail.

13:39.270 --> 13:40.430
And enable this API.

13:40.990 --> 13:46.350
And the same for Google services and the same for other Google services like Google Drive.

13:59.550 --> 14:00.470
Google drive API.

14:03.070 --> 14:04.790
And just simply enable it.

14:06.150 --> 14:07.790
And now in the credentials section.

14:07.790 --> 14:07.880
Then.

14:10.360 --> 14:12.000
You can grab the same credentials.

14:12.000 --> 14:13.880
So client ID and client secret.

14:16.040 --> 14:17.240
So just edit it.

14:22.000 --> 14:23.200
Copy the client ID.

14:26.800 --> 14:30.160
This time let's connect our Google Drive to N810.

14:30.200 --> 14:33.440
So create credential client ID.

14:35.480 --> 14:36.800
And the client secret.

14:41.760 --> 14:43.160
Hit save and sign in.

14:43.440 --> 14:44.320
And that's it.

14:45.040 --> 14:47.720
You have successfully connected Google Sheets to N810.

14:48.120 --> 14:50.840
And I also showed you how to connect other Google services.

14:54.320 --> 14:59.560
So you need to go through this process once and it will be automatically saved for future automations.

14:59.840 --> 15:03.400
But from time to time you will need to refresh your credentials.

15:03.600 --> 15:07.400
So now you know how to connect all the Google services to your workloads.

15:07.600 --> 15:09.880
Thank you for your attention and see you in the next tutorial.
