Skip to content
This repository was archived by the owner on Apr 2, 2025. It is now read-only.

Commit 0e0fd58

Browse files
author
Phil Varner
committed
add product_id field to Opportunity and Order Properties
1 parent e1f5d79 commit 0e0fd58

File tree

3 files changed

+3
-0
lines changed

3 files changed

+3
-0
lines changed

src/stapi_fastapi/models/opportunity.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
# Copied and modified from https://github.com/stac-utils/stac-pydantic/blob/main/stac_pydantic/item.py#L11
1313
class OpportunityPropertiesBase(BaseModel):
14+
product_id: str
1415
datetime: DatetimeInterval
1516
model_config = ConfigDict(extra="allow")
1617

src/stapi_fastapi/models/order.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010

1111
class OrderProperties(BaseModel):
12+
product_id: str
1213
datetime: DatetimeInterval
1314
model_config = ConfigDict(extra="allow")
1415

tests/conftest.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,7 @@ def mock_test_spotlight_opportunities() -> list[Opportunity]:
137137
coordinates=Position2D(longitude=0.0, latitude=0.0),
138138
),
139139
properties=TestSpotlightProperties(
140+
product_id="xyz123",
140141
datetime=(start, end),
141142
off_nadir=20,
142143
),

0 commit comments

Comments
 (0)