git clone https://github.com/graschik/hicaliber-test-task
cd hicaliber-test-taskCreate environment file:
cp .env.example .envAdd the following entry to your /etc/hosts file:
127.0.0.1 hicaliber-test
docker compose -f compose.dev.yaml up -dEnter the workspace container:
docker compose -f compose.dev.yaml exec workspace bashInstall dependencies:
composer install
npm install
npm run devRun migrations:
php artisan migrate
php artisan db:seed --class=HouseSeederApplication will be available at:
http://hicaliber-test:8002
Request
GET /api/v1/houses/search?filter[bedrooms]=4&filter[price_from]=0&filter[price_to]=513269&page[number]=2&page[size]=3Full URL example:
http://hicaliber-test:8002/api/v1/houses/search?filter[bedrooms]=4&filter[price_from]=0&filter[price_to]=513269&page[number]=2&page[size]=3
Response
{
"data": [
{
"id": 4,
"name": "The Aspen",
"bedrooms": 4,
"storeys": 2,
"bathrooms": 2,
"garages": 2,
"price": "384356.000",
"created_at": "2026-01-21T17:27:13.000000Z",
"updated_at": "2026-01-21T17:27:13.000000Z"
},
{
"id": 9,
"name": "The Geneva",
"bedrooms": 4,
"storeys": 2,
"bathrooms": 3,
"garages": 2,
"price": "390600.000",
"created_at": "2026-01-21T17:27:13.000000Z",
"updated_at": "2026-01-21T17:27:13.000000Z"
}
],
"meta": {
"total": 5,
"current_page": 2,
"page_size": 3,
"last_page": 2
}
}The project includes a simple Vue-based frontend for interacting with the API.
- View a paginated list of houses
- Filter houses by:
- Name (text search)
- Bedrooms
- Storeys
- Bathrooms
- Garages
- Price range (slider)
- Sort results by any column:
- Name
- Bedrooms
- Storeys
- Bathrooms
- Garages
- Price
- Change page size
- Navigate between pages
- Reset all filters to the initial state
All filtering, sorting, and pagination are handled server-side via the /api/v1/houses/search endpoint.
