Endpoint
Method: GETPath:
/v1/earthquakes/monthAuthentication: Not required
Parameters
Four-digit year (YYYY format).Validation:
- Must be a valid number
- Must be between 1900 and current year + 1
- Returns 400 error if missing or invalid: “Both ‘year’ and ‘month’ parameters are required and must be numbers. Example: ?year=2025&month=03”
Month number from 1 to 12 (1 = January, 12 = December).Validation:
- Must be a valid number
- Must be between 1 and 12
- Returns 400 error if invalid: “The ‘month’ parameter must be between 1 and 12. Example: ?month=07 for July”
Page number for pagination. Must be a positive integer greater than 0.Validation:
- Must be > 0
- Returns 400 error if invalid
Number of results per page. Must be a positive integer greater than 0.Validation:
- Must be > 0
- Returns 400 error if invalid
Sort order for results. Prefix with
- for descending order.Allowed values:timeor-time(default: descending)magnitudeor-magnitudedepthor-depth
Comma-separated list of fields to include in response.Allowed values:
timemagnitudedepthplacecoordinates
Request Example
Response
Indicates if the request was successful
HTTP status code (200 for success)
HTTP status message (“OK” for success)
Human-readable message. Format: “Earthquake events for -”
Array of GeoJSON Feature objects containing earthquake data
Request metadata containing method, path, and timestamp
Total count of earthquakes in the specified month
Pagination details with page, totalPages, limit, and hasMore
Response Example
Error Responses
Missing Required Parameters
Invalid Month
Invalid Year
Invalid Pagination
Implementation Details
- Date Range Calculation: Start date is first day of month (
{year}-{month}-01), end date is first day of next month - Month Padding: Month is zero-padded to 2 digits (e.g., March = “03”)
- Sorting: Default sort is by time (most recent first:
-time) - Pagination: Manual pagination applied after fetching all events from INGV
- Data Source: INGV API with
orderby=timeandformat=geojson
Use Cases
- Monthly seismic activity reports
- Historical analysis and comparisons
- Year-over-year trend analysis
- Research and academic studies
Related Endpoints
- Recent Earthquakes - Year-to-date events
- By Date Range - Custom date range
- Last Week - Last 7 days