/planets/13

homecaret-rightplanetscaret-right

13

API Endpoint:

Request:

fetch("https://swapi.info/api/planets/13")
    .then((res) => res.json()) // Parse the JSON content from the API to be consumed
    .then((json) => console.log(json)) // Log the JSON response to your console
    .catch((error) => console.error(error)) // Log the API error (if any) to your console

Result:

{
  "name": "Mustafar",
  "rotation_period": "36",
  "orbital_period": "412",
  "diameter": "4200",
  "climate": "hot",
  "gravity": "1 standard",
  "terrain": "volcanoes, lava rivers, mountains, caves",
  "surface_water": "0",
  "population": "20000",
  "residents": [],
  "films": [
    "https://swapi.info/api/films/6"
  ],
  "created": "2014-12-10T12:50:16.526000Z",
  "edited": "2014-12-20T20:58:18.440000Z",
  "url": "https://swapi.info/api/planets/13"
}
eye-open
Good