Skip to content

Commit 11e7a4e

Browse files
committed
delete collection from catalog
1 parent 455e362 commit 11e7a4e

File tree

6 files changed

+655
-133
lines changed

6 files changed

+655
-133
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,7 @@ This implementation follows the [STAC API Catalogs Extension](https://github.com
252252
- **GET `/catalogs/{catalog_id}/collections`**: Retrieve collections within a specific catalog
253253
- **POST `/catalogs/{catalog_id}/collections`**: Create a new collection within a specific catalog
254254
- **GET `/catalogs/{catalog_id}/collections/{collection_id}`**: Retrieve a specific collection within a catalog
255+
- **DELETE `/catalogs/{catalog_id}/collections/{collection_id}`**: Delete a collection from a catalog (removes parent_id if multiple parents exist, deletes collection if it's the only parent)
255256
- **GET `/catalogs/{catalog_id}/collections/{collection_id}/items`**: Retrieve items within a collection in a catalog context
256257
- **GET `/catalogs/{catalog_id}/collections/{collection_id}/items/{item_id}`**: Retrieve a specific item within a catalog context
257258

@@ -292,6 +293,11 @@ curl "http://localhost:8081/catalogs/earth-observation/collections/sentinel-2/it
292293
# Get specific item within a catalog
293294
curl "http://localhost:8081/catalogs/earth-observation/collections/sentinel-2/items/S2A_20231015_123456"
294295

296+
# Delete a collection from a catalog
297+
# If the collection has multiple parent catalogs, only removes this catalog from parent_ids
298+
# If this is the only parent catalog, deletes the collection entirely
299+
curl -X DELETE "http://localhost:8081/catalogs/earth-observation/collections/sentinel-2"
300+
295301
# Delete a catalog (collections remain intact)
296302
curl -X DELETE "http://localhost:8081/catalogs/earth-observation"
297303

0 commit comments

Comments
 (0)