drought.weeks_in_drought
mock data$0.001 / callCounties by Weeks in Drought
Find US counties that experienced at least N weeks of drought at or above a specified drought severity level during a given time period, using data from the USDA/NOAA US Drought Monitor. Filter by state (or all states), drought level (D0–D4), minimum weeks threshold, and whether to count consecutive or total (non-consecutive) weeks. Returns a list of matching counties with their FIPS codes, state, and week counts. Useful for identifying persistent drought-affected regions, prioritizing disaster relief, analyzing multi-year drought patterns, and supporting agricultural or water resource planning.
Input schema
Two-letter US state abbreviation to filter results to one state (e.g. "NE", "TX", "CA"). Leave empty to return counties from all states.
End date for the analysis period in YYYY-MM-DD format (e.g. "2023-01-01"). Maximum range is 1 year from start_date.
Minimum number of weeks that a county must have been at or above the drought_level threshold to be included in results (e.g. 4 for counties with at least 4 weeks of drought).
Start date for the analysis period in YYYY-MM-DD format (e.g. "2022-01-01"). Maximum range is 1 year from start_date.
If true, counts only consecutive weeks in drought; if false or omitted (default), counts all weeks (consecutive + non-consecutive) spent at or above the threshold.
Minimum drought severity level to count: 0=D0 Abnormally Dry, 1=D1 Moderate Drought, 2=D2 Severe Drought, 3=D3 Extreme Drought, 4=D4 Exceptional Drought.
Call via REST
curl -X POST https://unifyapi.pro/api/call/drought.weeks_in_drought \
-H "Authorization: Bearer uak_live_..." \
-H "Content-Type: application/json" \
-d '{"state":"<state>","end_date":"<end_date>","min_weeks":0,"start_date":"<start_date>","consecutive":"<consecutive>","drought_level":0}'