Backend Code Map¶
Public source repo:¶
API Gateway¶
| Concern | Source |
|---|---|
| Top-level Django route registry | nrm_app/urls.py |
| Swagger and ReDoc routes | nrm_app/urls.py |
Authentication¶
| Concern | Source |
|---|---|
| Auth mode decorator | utilities/auth_check_decorator.py |
Auth_free handling |
utilities/auth_check_decorator.py |
X-API-Key header handling |
utilities/auth_check_decorator.py |
| JWT bearer handling | utilities/auth_check_decorator.py |
Auth-Free Geography Discovery¶
| Concern | Source |
|---|---|
| Route list | geoadmin/urls.py |
get_states() |
geoadmin/api.py |
get_districts() |
geoadmin/api.py |
get_blocks() |
geoadmin/api.py |
Public Data APIs¶
| Concern | Source |
|---|---|
| Public API route list | public_api/urls.py |
| Admin lookup by lat/lon | public_api/api.py |
| MWS lookup by lat/lon | public_api/api.py |
| Tehsil JSON and MWS data | public_api/api.py |
| Generated layer URLs | public_api/api.py |
| Layer URL assembly logic | public_api/views.py |
| Report URL generation | public_api/views.py |
| MWS geometries via GeoServer | public_api/views.py |
| Village geometries via GeoServer | public_api/views.py |
Compute Submission Surface¶
| Concern | Source |
|---|---|
| Full compute route list | computing/urls.py |
| Workspace and boundary handlers | computing/api.py |
| Hydrology and LULC handlers | computing/api.py |
| SWB handler | computing/api.py |
| Terrain handlers | computing/api.py |
Publishing and Delivery¶
| Concern | Source |
|---|---|
| Zip and publish shapes to GeoServer | computing/utils.py |
| Convert KML to shapefile and publish | computing/utils.py |
| Sync feature collections to GeoServer | computing/utils.py |
Earth Engine Integration¶
| Concern | Source |
|---|---|
| GEE initialization from stored credentials | utilities/gee_utils.py |
| GCS configuration | utilities/gee_utils.py |
| Task polling | utilities/gee_utils.py |
| Asset path helpers | utilities/gee_utils.py |
Operator setup for the Django-side GEEAccount used by these helpers is documented in Google Earth Engine.
Installation¶
| Concern | Source |
|---|---|
| Installer CLI, step order, env generation, and rerun logic | installation/install.sh |
| Human-oriented install overview | installation/INSTALLATION.md |
| In-process backend validation | computing/misc/internal_api_initialisation_test.py |
| Public API smoke test and download helper | installation/public_api_client.py |