Add Query Filters to Get All Spots
Closed this issue · 0 comments
FarhadK2022 commented
Return spots filtered by query parameters.
- Query parameters are accepted for
page
,size
,minLat
,maxLat
,
minLng
,maxLng
,minPrice
, andmaxPrice
- Default values are provided for the
page
andsize
parameters - Successful response includes only spots in the database that meet the
specified query parameters criteria. - Spot data returned includes the
id
,ownerId
,address
,city
,
state
,country
,lat
,lng
,name
,description
,price
,createdAt
,
updatedAt
, andpreviewImage
for each spot - Successful response includes the
page
andsize
of the returned payload - Error response with status 400 is given when query parameter validations
for thepage
,size
,minLat
,maxLat
,minLng
,maxLng
,minPrice
, or
maxPrice
are violated