1
00:00:01,110 --> 00:00:02,700
-: In the previous section

2
00:00:02,700 --> 00:00:05,400
we discussed various types of APIs

3
00:00:05,400 --> 00:00:09,090
and we concluded that Web APIs is the most popular

4
00:00:09,090 --> 00:00:11,760
and most useful kind of API.

5
00:00:11,760 --> 00:00:15,060
So let's dive a little bit deeper into Web APIs

6
00:00:15,060 --> 00:00:17,820
and explain what it is exactly.

7
00:00:17,820 --> 00:00:20,220
So, let's remind ourselves

8
00:00:20,220 --> 00:00:23,370
the definition of Web API that we have used.

9
00:00:23,370 --> 00:00:26,220
An API exposed by a web component,

10
00:00:26,220 --> 00:00:29,670
allowing other component to interact with it.

11
00:00:29,670 --> 00:00:31,380
It's important to remember

12
00:00:31,380 --> 00:00:34,680
some common characteristics of Web API.

13
00:00:34,680 --> 00:00:37,920
First, Web API is platform agnostic

14
00:00:37,920 --> 00:00:40,920
meaning .NET components, for example,

15
00:00:40,920 --> 00:00:45,330
can easily communicate with Python component using Web API.

16
00:00:45,330 --> 00:00:48,870
And of course this is true also for other platforms.

17
00:00:48,870 --> 00:00:52,560
In addition, Web APIs use standard protocols

18
00:00:52,560 --> 00:00:56,403
usually over HTTP as you see in this diagram.

19
00:00:57,330 --> 00:01:02,330
And also Web API usually using request/response

20
00:01:02,700 --> 00:01:06,330
meaning when we have a core component,

21
00:01:06,330 --> 00:01:08,460
in this case the .NET component,

22
00:01:08,460 --> 00:01:10,860
which is calling the Python component,

23
00:01:10,860 --> 00:01:15,860
then the .NET component will request or will send a request

24
00:01:17,010 --> 00:01:20,610
based on the HTTP protocol to the Python component

25
00:01:20,610 --> 00:01:24,870
and we'll receive back an HTTP response.

26
00:01:24,870 --> 00:01:27,810
This is part of the HTTP protocol,

27
00:01:27,810 --> 00:01:30,660
and almost all kinds of Web APIs

28
00:01:30,660 --> 00:01:34,800
will use this paradigm of request response.

29
00:01:34,800 --> 00:01:37,350
Now, when discussing Web API types

30
00:01:37,350 --> 00:01:39,240
we should understand what is the difference

31
00:01:39,240 --> 00:01:42,060
or what is the main differences between them.

32
00:01:42,060 --> 00:01:44,880
So the Web APIs are differentiated

33
00:01:44,880 --> 00:01:48,060
mainly by the request format.

34
00:01:48,060 --> 00:01:51,240
It could be JSON or XML or anything else.

35
00:01:51,240 --> 00:01:53,190
The request content.

36
00:01:53,190 --> 00:01:55,380
What is the content of the request

37
00:01:55,380 --> 00:01:57,297
that is sent over the web?

38
00:01:57,297 --> 00:01:59,310
The response format.

39
00:01:59,310 --> 00:02:02,943
Again, is JSON or XML or Clear text or something else.

40
00:02:03,780 --> 00:02:06,660
And of course the response contents.

41
00:02:06,660 --> 00:02:08,820
What is the content of the response

42
00:02:08,820 --> 00:02:11,343
sent by the server back to the client.

43
00:02:12,450 --> 00:02:14,250
So with that in mind,

44
00:02:14,250 --> 00:02:17,490
let's explore the various types of Web APIs.

45
00:02:17,490 --> 00:02:19,023
First, SOAP,

46
00:02:20,010 --> 00:02:24,570
and REST, GraphQL and gRPC.

