Endpoint: planets
GEThttps://swapi.mimo.dev/api/planets/Kamino
Request
GETplanets
1fetch("https://swapi.mimo.dev/api/planets/Kamino")
2 .then((res) => res.json())
3 .then((json) => console.log(json))
4 .catch((error) => console.error(error))
Response
response.json
1{
2 "name": "Kamino",
3 "rotation_period": "27",
4 "orbital_period": "463",
5 "diameter": "19720",
6 "climate": "temperate",
7 "gravity": "1 standard",
8 "terrain": "ocean",
9 "surface_water": "100",
10 "population": "1000000000",
11 "residents": [
12 "https://swapi.mimo.dev/api/people/22/",
13 "https://swapi.mimo.dev/api/people/72/",
14 "https://swapi.mimo.dev/api/people/73/"
15 ],
16 "films": [
17 "https://swapi.mimo.dev/api/films/5/"
18 ],
19 "created": "2014-12-10T12:45:06.577000Z",
20 "edited": "2014-12-20T20:58:18.434000Z",
21 "url": "https://swapi.mimo.dev/api/planets/10/"
22}