/vehicles/16

homecaret-rightvehiclescaret-right

16

API Endpoint:

Request:

fetch("https://swapi.info/api/vehicles/16")
    .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": "TIE bomber",
  "model": "TIE/sa bomber",
  "manufacturer": "Sienar Fleet Systems",
  "cost_in_credits": "unknown",
  "length": "7.8",
  "max_atmosphering_speed": "850",
  "crew": "1",
  "passengers": "0",
  "cargo_capacity": "none",
  "consumables": "2 days",
  "vehicle_class": "space/planetary bomber",
  "pilots": [],
  "films": [
    "https://swapi.info/api/films/2",
    "https://swapi.info/api/films/3"
  ],
  "created": "2014-12-15T12:33:15.838000Z",
  "edited": "2014-12-20T21:30:21.675000Z",
  "url": "https://swapi.info/api/vehicles/16"
}
eye-open
Good