|  | 
| 1 | 1 | """Base clients.""" | 
| 2 | 2 | 
 | 
| 3 | 3 | import abc | 
| 4 |  | -from typing import Any, Dict, List, Optional, Union | 
|  | 4 | +from typing import Annotated, Any, Dict, List, Optional, Union | 
| 5 | 5 | from urllib.parse import urljoin | 
| 6 | 6 | 
 | 
| 7 | 7 | import attr | 
| 8 |  | -from fastapi import Request | 
|  | 8 | +from fastapi import Header, Request | 
| 9 | 9 | from geojson_pydantic.geometries import Geometry | 
| 10 | 10 | from stac_pydantic import Collection, Item, ItemCollection | 
| 11 | 11 | from stac_pydantic.links import Relations | 
| @@ -86,7 +86,7 @@ def patch_item( | 
| 86 | 86 |         collection_id: str, | 
| 87 | 87 |         item_id: str, | 
| 88 | 88 |         patch: Any, | 
| 89 |  | -        content_type: Optional[str], | 
|  | 89 | +        content_type: Annotated[Optional[str], Header()] = None, | 
| 90 | 90 |         **kwargs, | 
| 91 | 91 |     ) -> Optional[Union[stac.Item, Response]]: | 
| 92 | 92 |         """Update an item from a collection. | 
| @@ -161,7 +161,7 @@ def patch_collection( | 
| 161 | 161 |         self, | 
| 162 | 162 |         collection_id: str, | 
| 163 | 163 |         patch: Any, | 
| 164 |  | -        content_type: Optional[str], | 
|  | 164 | +        content_type: Annotated[Optional[str], Header()] = None, | 
| 165 | 165 |         **kwargs, | 
| 166 | 166 |     ) -> Optional[Union[stac.Collection, Response]]: | 
| 167 | 167 |         """Update a collection. | 
| @@ -243,7 +243,7 @@ async def patch_item( | 
| 243 | 243 |         collection_id: str, | 
| 244 | 244 |         item_id: str, | 
| 245 | 245 |         patch: Any, | 
| 246 |  | -        content_type: Optional[str], | 
|  | 246 | +        content_type: Annotated[Optional[str], Header()] = None, | 
| 247 | 247 |         **kwargs, | 
| 248 | 248 |     ) -> Optional[Union[stac.Item, Response]]: | 
| 249 | 249 |         """Update an item from a collection. | 
| @@ -318,7 +318,7 @@ async def patch_collection( | 
| 318 | 318 |         self, | 
| 319 | 319 |         collection_id: str, | 
| 320 | 320 |         patch: Any, | 
| 321 |  | -        content_type: Optional[str], | 
|  | 321 | +        content_type: Annotated[Optional[str], Header()] = None, | 
| 322 | 322 |         **kwargs, | 
| 323 | 323 |     ) -> Optional[Union[stac.Collection, Response]]: | 
| 324 | 324 |         """Update a collection. | 
|  | 
0 commit comments