Example Collections
The examples in this repository serve two important purposes:
- Reference Collections for Monty API
- Collection Documentation Validation
Reference Collections for Monty API
The example collections in this repository serve as reference implementations for the Monty API. They demonstrate:
- Proper STAC collection structure for various data sources
- Correct implementation of the Monty extension
- Valid use of field values and data types
- Relationships between different types of data (events, hazards, impacts)
Collection Types
Each data source has its own set of collections:
-
Events Collections
- Define disaster events from various sources
- Example: Reference Events Collection
- Used for event correlation and data integration
-
Hazards Collections
- Contain hazard-specific data
- Example: GDACS Hazards Collection
- Define severity, intensity, and other hazard characteristics
-
Impacts Collections
- Document the effects of hazards
- Example: IDMC GIDD Impacts Collection
- Track casualties, displacement, and other impact metrics
Collection Documentation Validation
The example collections play a crucial role in the CI/CD workflow:
-
Schema Validation
- Examples are validated against the JSON Schema
- Ensures compliance with the STAC specification
- Verifies Monty extension requirements
-
Documentation Testing
- Examples are used to test documentation accuracy
- Verify that documentation reflects actual implementation
- Ensure examples are in sync with schema changes
-
Integration Testing
- Used to test the Monty API's ability to:
- Parse different collection types
- Handle various data structures
- Maintain relationships between items
- Used to test the Monty API's ability to:
CI/CD Process
The validation process in the CI/CD workflow:
graph TD
A[Push to Repository] --> B[Validate JSON Schema]
B --> C[Test Example Collections]
C --> D[Check Documentation]
D --> E[Generate API Documentation]
E --> F[Deploy if All Tests Pass]
B -- Fail --> G[Report Schema Errors]
C -- Fail --> H[Report Collection Errors]
D -- Fail --> I[Report Doc Inconsistencies]