GeoServices Directory

GeoServices is a full-stack map-based directory that helps users find nearby service shops based on their location. It uses PostGIS for geographic queries, GADM datasets for polygon hierarchies, and integrates with Denude IDP for authentication.

In Progress

Built With

  • .NET
  • Next.js
  • Denude IDP
The page initial load.
Click to zoom
Step 1: Main map interface.
Interactive map showing regional polygons.
Click to zoom
Step 2: Main map interface with rendered GeoJSON polygons for operational areas. Triggered after page state is loaded. It attempts to detect the approximate city location using IP-based geolocation via Next.js headers middleware—no browser API involved.
Filters and Sort options.
Click to zoom
Step 3: Users can filter by location and services within a chosen radius. Defaults apply when clicking "Detect My Location."
Filtered search results based on selected filters.
Click to zoom
Step 4: Results update instantly, sorted by distance and service status.
Add to cart.
Click to zoom
Step 5: Add to cart anonymously—items will merge with the account cart after login.
The cart.
Click to zoom
Step 6: Cart design blocks showing the merge, but take my word for it—it merges.
Merged cart after login.
Click to zoom
Step 7: Cart state persists anonymously and merges automatically after authentication.
Backend API documentation in Swagger.
Click to zoom
Step 8: The .NET API provides full geospatial filtering, aggregation, and service management.
Backend API documentation in Swagger.
Click to zoom
Step 9: The .NET API provides full geospatial filtering, aggregation, and service management.
Backend API documentation in Swagger.
Click to zoom
Step 10: The .NET API provides full geospatial filtering, aggregation, and service management.

Technical Breakdown

Built with .NET Minimal APIs and PostGIS. We use the `geography` type for clean, radius-based distance filtering. (`geometry` can offer minor improvements if you are exploring projections, but for this use case, `geography` is sufficient.)

  • Accurate distance filtering using ST_DWithin and meters.
  • Imported GADM L1–L3 data to represent country boundaries.
  • Built custom operational areas to fix overlaps — e.g., avoiding Giza and 6th of October clashing at the same level.
  • Map-level hierarchy allows clean nesting of regions and services.
  • Aggregator endpoint counts shops per polygon.