This document describes the migration of area-related endpoints from the main backend to a separate microservice.
The following endpoints have been moved to a dedicated areas-service:
GET /health- Health check endpoint
POST /api/v3/create_or_update_area- Create or update an area (🔒 Bearer Token Required)GET /api/v3/get_areas- Get areas with optional filteringPOST /api/v3/update_consent- Update consent for an areaGET /api/v3/get_areas_count- Get count of areasDELETE /api/v3/delete_area- Delete an area and all related data (🔒 Bearer Token Required)
The areas-service now includes authentication middleware for protected endpoints. The following endpoints require a valid Bearer token:
POST /api/v3/create_or_update_areaDELETE /api/v3/delete_area
Add the following environment variable to configure the auth-service URL:
export AUTH_SERVICE_URL=http://auth-service:8080