1 00:00:00,210 --> 00:00:01,290 Not bad, not bad. 2 00:00:01,350 --> 00:00:08,280 We've got our setup, so now let's talk about the API we're going to use and for this project we're 3 00:00:08,280 --> 00:00:18,810 going to use API by the name of Open Trivia DB and you can simply type open CD and be so open to Revere 4 00:00:19,030 --> 00:00:27,840 database and just follow the link that the API we're going to use and just navigate to API page. 5 00:00:28,200 --> 00:00:32,220 And here we have an option of constructing the URL. 6 00:00:32,880 --> 00:00:40,410 So what's really cool about this API is that you can construct the example API and of course we'll use 7 00:00:40,410 --> 00:00:42,360 that as our starting point. 8 00:00:42,690 --> 00:00:50,010 And I would strongly suggest doing the same thing because even though during our app, eventually we 9 00:00:50,010 --> 00:00:53,730 will construct this URL dynamically using these checkboxes. 10 00:00:53,940 --> 00:00:59,370 And you can clearly see that because we have similar questions to the ones that you can find in the 11 00:00:59,370 --> 00:00:59,910 API. 12 00:01:00,300 --> 00:01:05,270 But in fact, we'll start our application by working on the questions. 13 00:01:05,850 --> 00:01:09,220 So I would want to add that set up form at the very end. 14 00:01:09,720 --> 00:01:14,270 So essentially what I'm trying to say is we all need some data, we'll need some questions. 15 00:01:14,610 --> 00:01:17,190 So, of course, we can set up these questions and answers. 16 00:01:17,490 --> 00:01:22,860 And that's why I would strongly suggest navigating to the API and constructing this. 17 00:01:22,860 --> 00:01:24,390 You are with me now. 18 00:01:24,390 --> 00:01:31,280 It doesn't really matter what questions are you picking or categories, but I would suggest going the 19 00:01:31,350 --> 00:01:35,030 same background as me because it's just going to be easier to follow. 20 00:01:35,460 --> 00:01:37,020 So I'm going to go with a number of questions. 21 00:01:37,020 --> 00:01:44,250 I'm going to go with sports because even though I'll fail in all of them, I think sports is somewhat 22 00:01:44,250 --> 00:01:45,030 easier for me. 23 00:01:45,510 --> 00:01:47,030 Then I'm going to go with difficulty. 24 00:01:47,040 --> 00:01:49,410 I'm just going to go easy as far as the type. 25 00:01:49,410 --> 00:01:53,700 I'm going to go with multiple choice and we don't really care about the encoding. 26 00:01:53,700 --> 00:01:57,830 So just go with default and I'm going to generate the URL. 27 00:01:58,900 --> 00:02:05,770 And just copy and paste and open up a new tab and try it out, whether it works and what you should 28 00:02:05,770 --> 00:02:13,480 see is an object and the object, of course, we have or is key and it is an array. 29 00:02:13,660 --> 00:02:16,900 And there I have my 10 questions again. 30 00:02:16,900 --> 00:02:23,200 Later we'll set it up that you can have a hundred questions or 50 or whatever in this case, or just 31 00:02:23,200 --> 00:02:24,960 go with default then. 32 00:02:25,390 --> 00:02:27,760 And here you can see that in the object. 33 00:02:27,760 --> 00:02:28,600 I have a category. 34 00:02:29,020 --> 00:02:29,800 I have type. 35 00:02:29,890 --> 00:02:31,660 So what is the type of the question? 36 00:02:31,930 --> 00:02:37,380 And in this case, of course, all of them are going to be multiple because that's what I chose. 37 00:02:37,720 --> 00:02:42,470 And we also have the difficulty, of course, which is easy question. 38 00:02:42,970 --> 00:02:44,410 So that's the actual question. 39 00:02:44,650 --> 00:02:49,720 And what is the correct answer, plus the incorrect answers in the array. 40 00:02:50,050 --> 00:02:51,570 So that should be the starting point. 41 00:02:51,850 --> 00:03:00,190 And what I would suggest is taking this whole YORO that navigate back to the project in the context 42 00:03:00,430 --> 00:03:02,440 and notice here where I have the URL. 43 00:03:02,890 --> 00:03:09,310 Well, let's just call this temp URL because again, eventually, yes, we'll construct it ourselves. 44 00:03:09,640 --> 00:03:13,800 But for the time being, we need those questions with those answers. 45 00:03:14,350 --> 00:03:21,610 So we need some data to work with and then eventually set up our form that generates that you are all 46 00:03:21,610 --> 00:03:22,040 for us. 47 00:03:22,390 --> 00:03:29,740 So grab the URL, copy paste, set up some kind of horrible markers that is temporary, you R-AL and 48 00:03:29,740 --> 00:03:32,920 paste this value and once you're done with that. 49 00:03:33,820 --> 00:03:37,370 Then, of course, we can continue with our application.