Endpoint: planets
GEThttps://swapi.mimo.dev/api/planets/Skako
Request
GETplanets
1fetch("https://swapi.mimo.dev/api/planets/Skako")
2 .then((res) => res.json())
3 .then((json) => console.log(json))
4 .catch((error) => console.error(error))
Response
response.json
1{
2 "name": "Skako",
3 "rotation_period": "27",
4 "orbital_period": "384",
5 "diameter": "unknown",
6 "climate": "temperate",
7 "gravity": "1",
8 "terrain": "urban, vines",
9 "surface_water": "unknown",
10 "population": "500000000000",
11 "residents": [
12 "https://swapi.mimo.dev/api/people/76/"
13 ],
14 "films": [],
15 "created": "2014-12-20T17:50:47.864000Z",
16 "edited": "2014-12-20T20:58:18.517000Z",
17 "url": "https://swapi.mimo.dev/api/planets/56/"
18}