• 4 months ago

Category

😹
Fun
Transcript
00:00Hello everyone and welcome back.
00:04So, in this video we will see how you can enable a different APIs within a projects.
00:10So, what does here the enabling API mean?
00:13So, let's say Google Cloud has a number of different products and a number of different
00:19services.
00:20Now, either you interact your Google Cloud from your Google console through your Python
00:26code or maybe Java code or there are other ways to interact later on, we'll see like
00:32a Google Cloud SDK or Google Cloud Shell.
00:36So when you interact with those resources, you're going to interact with some kind of
00:42application programming interface.
00:44So let's say on the left hand side, we have things like, let me just.
00:56So here we have, let's say, SDK or we have, let's say, Python code or we have, let's say,
01:06Java code.
01:08So those things want to interact with, let's say, compute engine or some kind of database.
01:16So this is like a compute engine, some kind of database it wants to interact like a Cloud
01:21SQL or a Cloud Spanner.
01:24So they are interacting with some kind of API.
01:27Now this API is not necessary that always enable.
01:31But when you create a project, there are some default APIs already being enabled, but not
01:37necessary every one of them.
01:39So how we can enable them?
01:40Because after you enable those API, then only you can interact with those resources through
01:46different kinds of client.
01:48So let me go to Google Cloud Console and let me go to IAM, above IAM we have APIs and services.
01:59So let's just go to the dashboard of APIs and services.
02:02Now when you want to go to dashboard or a very first link appear on individual menu,
02:08you do not need to worry about, I mean, going and put it your cursor here.
02:13You can just directly click on here and by default it will redirect to the very first
02:19link.
02:20Alright.
02:21So you can see we have a dashboard of APIs and services.
02:24So currently there is no traffic for individual APIs, there is no error and we don't have
02:31any median latency.
02:33But on a down, on a bottom of this particular dashboard, you can see we earlier created
02:39this compute engine.
02:41So obviously, compute engine APIs got enabled and there are some 1600 JO4 requests got hit
02:50out of them.
02:51There is a zero percentage error, this latency, median latency and is 95% latency.
02:57Alright.
02:58So these two API must be enabled.
03:01That's why we are able to hit those resources from our Google Cloud Console.
03:06Now let's say if you want to enable some API, you can just click on Enable APIs and
03:12services or you can just simply go to libraries.
03:15Let me click on Enable APIs and let's say we have lots of lots of services and products
03:22are available.
03:23Let's just search for some, let's say BigQuery, yeah, we have a BigQuery API.
03:29So let me just select on it and let's see whether this particular API is unable or not.
03:37It's still loading.
03:38Yeah, so it is already enabled.
03:41But if you want to, let's say, just manage it, you can just simply go to manage and from
03:48here you can always create a credential because without credential, how you're going to interact
03:54with this BigQuery API, you can always disable it from here.
03:58But we have already this is enabled.
04:01So what we'll do, let's just go back to our APIs and services, go to libraries.
04:09Let me search for some other API, let's say PubSub.
04:12So PubSub is something like a Apache Kafka inside the Google Cloud and you can see this
04:18PubSub API is still not enabled.
04:21So we can just make it enabled by click on Enable.
04:25So this will enable Cloud PubSub API inside our project.
04:29Now corresponding to every single project, this API enabling is different because project
04:35is something like a segregating your work under one single umbrella.
04:40Whatever you are doing under this particular project, that doesn't mean that this got reflected
04:45into another project.
04:47Because if you just go to, let's say, our my first project and let me just open it into
04:53another tab, that will be better.
04:55Let's just keep this screen as it is.
04:58And you can see now Cloud PubSub API got enabled.
05:05You can always find some details about your API that what is the traffic for this particular
05:11API, what are some of the details, like a service name pubsub.googleapis.com.
05:18And if you want to find, let's say, credential, why we require credential?
05:23Because when you hit to this particular services, like this particular API, how you are going
05:29to authenticate?
05:30So there are a number of methods through which we can authenticate ourselves while calling
05:36this Cloud PubSub API.
05:38So you can always use service account or client ID.
05:42And depending on different APIs, this authentication mechanism also varies a little bit.
05:47We have a matrix.
05:49So corresponding to this API, Cloud PubSub, what are the reports it will generate?
05:57You can see the traffic error by API code.
05:59So which particular some API got failed?
06:02We don't have any data that are available as of now.
06:05So there is nothing to show here.
06:07Quotas.
06:08So obviously, there are some limits.
06:10So daily quota resets at midnight, what it says that midnight pacific time.
06:16That's perfectly OK.
06:18If you just open administrator operation, yeah, so on the bottom of this quotas, you
06:27can see administrator operation per minute.
06:30So there is a limit of 6000 and this limit may not be added.
06:35So this is like 6000 is the maximum might be API call, you can always do it.
06:42Now if you want to request more quota and limit, you can always go to this quota page.
06:47Maybe later on, we'll see about that.
06:49But this is how you can enable the API.
06:51You can disable the API.
06:53If you want to disable, you can go to overview and you can disable it.
06:56Now let me go to another project.
06:58Currently, I am inside my Learn GCP AC23.
07:05Now what we'll do, we'll go to another project still.
07:10The project is not visible here.
07:13Yeah, I don't know how to navigate to the project.
07:18So what we'll do, we'll just change the project from here.
07:22Just remember that this Cloud PubShop API is enabled inside this particular project.
07:27Now when I go to my first project, let's just enable PubShop.
07:36And you will be able to see this also enabled here.
07:40Might be I have enabled for some other reason.
07:43Otherwise, this is not enabled.
07:45Let me just disable inside this my first project.
07:48And let's just go back to our Learn GCP AC projects.
07:54So any resources you have created by this may be deleted after this API got disabled.
08:01Now let me just go back to my original projects like a Learn GCP.
08:06And let me just manage it.
08:08Yeah.
08:09So that is for some different purpose.
08:11We have disabled APIs inside my first project, but inside this particular project, it is
08:17still not disabled.
08:18So APIs varies from project to project.
08:22Inside each project, those APIs, APIs calling, API disabling, enabling is a completely different
08:29story.
08:30Alright, so that is all about how one can enable the APIs and disable the API.

Recommended