diff --git a/raster_api/runtime/src/app.py b/raster_api/runtime/src/app.py index b86b55e3..50df686b 100644 --- a/raster_api/runtime/src/app.py +++ b/raster_api/runtime/src/app.py @@ -23,6 +23,7 @@ from titiler.extensions import cogValidateExtension, cogViewerExtension from titiler.mosaic.errors import MOSAIC_STATUS_CODES from titiler.pgstac.db import close_db_connection, connect_to_db +from titiler.pgstac.dependencies import SearchIdParams from titiler.pgstac.extensions import searchInfoExtension from titiler.pgstac.factory import ( MosaicTilerFactory, @@ -73,11 +74,11 @@ async def lifespan(app: FastAPI): ############################################################################### mosaic = MosaicTilerFactory( router_prefix="/mosaic/{search_id}", - path_dependency=ItemPathParams, + path_dependency=SearchIdParams, optional_headers=optional_headers, environment_dependency=settings.get_gdal_config, process_dependency=PostProcessParams, - router=APIRouter(route_class=LoggerRouteHandler), + # router=APIRouter(route_class=LoggerRouteHandler), # add /statistics [POST] (default to False) add_statistics=True, # add /map viewer (default to False) @@ -123,7 +124,7 @@ async def lifespan(app: FastAPI): optional_headers=optional_headers, router_prefix="/stac", environment_dependency=settings.get_gdal_config, - router=APIRouter(route_class=LoggerRouteHandler), + # router=APIRouter(route_class=LoggerRouteHandler), extensions=[ stacViewerExtension(), ], @@ -140,7 +141,7 @@ async def lifespan(app: FastAPI): optional_headers=optional_headers, router_prefix="/stac-alt", environment_dependency=settings.get_gdal_config, - router=APIRouter(route_class=LoggerRouteHandler), + # router=APIRouter(route_class=LoggerRouteHandler), extensions=[ stacViewerExtension(), ], @@ -155,7 +156,7 @@ async def lifespan(app: FastAPI): router_prefix="/cog", optional_headers=optional_headers, environment_dependency=settings.get_gdal_config, - router=APIRouter(route_class=LoggerRouteHandler), + # router=APIRouter(route_class=LoggerRouteHandler), extensions=[ cogValidateExtension(), cogViewerExtension(),