Zoom
1
2
{
3
4
5
6
"_id": "652cc6cd83c0aab446fd6a06",
"username": "Tom Cruise",
"text": "Hi, everyone!",
"createAt": "2023-10-16T05:14:53.257Z"
7
},
8
{
9
10
11
12
"_id": "652cc74483c0aab446fd6a09",
"username": "Scarlett Johansson",
"text": "Perfect self-study topic. Thank you!",
"createAt": "2023-10-16T05:16:52.418Z"
13
},
14
{
15
16
17
18
"_id": "652d0ef49ed9c1135a182070",
"username": "Lionel Messi",
"text": "Great topic. Thank.",
"createAt": "2023-10-16T10:22:44.381Z"
19
},
20
{
21
"_id": "652d55f19ed9c1135a182073",
22
"username": "Cristian Ronaldo",
23
24
"text": "Thanks a lot. This is a beneficial content",
"createAt": "2023-10-16T15:25:37.866Z"
25
}
26 ]
Figure 2 - The result of API at /tutorial/652c1cd546a765d027fb163c/comments using GET method
1.3. (2 points)
The API at url:
http://localhost:9999/tutorials/create, using POST method to create a new Tutorial. Save the list of images to the Images collection. At the same time, each image object stores information, including_id, URL, and caption, into the Tutorial you want to add. See more