diff --git a/endpoints/vans.get.py b/endpoints/vans.get.py new file mode 100644 index 0000000..46d6219 --- /dev/null +++ b/endpoints/vans.get.py @@ -0,0 +1,13 @@ +from fastapi import APIRouter, Depends, status +from typing import List +from helpers.car_helpers import get_german_cars + +router = APIRouter() + +@router.get("/vans", status_code=200, response_model=List[CarSchema]) +async def get_german_cars( + db: Session = Depends(get_db) +): + """Get list of German cars""" + cars = get_german_cars(db) + return cars \ No newline at end of file