IEM Provided JSON-P Webservices
This page is an attempt to document the various JSON-P web services the IEM uses to drive its various applications. These services are provided without warranty and may be disabled without warning if "bad things happen". We do try our best to keep them running, so please Contact Us if you have difficulties.
These services support JSONP,
which is a technique that allows the deliver of data from a cross-domain origin.
The technique involves placing or injecting <script> tags into your webpage
and specifying a javascript function to callback. For example,
<script type="text/javascript"> function gotData(data){ console.log(data); } </script> <script type="text/javascript" src="https://mesonet.agron.iastate.edu/json/example.php?callback=gotData">
This <script> tag above that requests data from this server will return
javascript that looks like:
gotData({"Name": "daryl", "Profession": "nerd", "Age": 99});
But first, perhaps there are better alternatives
The following is a list of other web service providers. They all do a better job than this website does. Some of these are commercial and this listing should not be implied as an endorsement. Of course, you can just search google for Weather API :)
Okay, so you are all set for documentation on what services are available!
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/usdm.py?date={date}&callback=gotData
Description: The US Drought Monitor valid for the given date. You do not need to specify the exact date on which the Drought Monitor was issued. The service will compute the date on which the Drought Monitor was issued given the provided date. Not specifying a date will provide the current Drought Monitor. Archive begins on Jan 2000.
Method GET Parameters:
date | Date (optional) |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/api/1/usdm_bypoint.json?sdate={sdate}&edate={edate}&lon={lon}&lat={lat}&callback=gotData
Description: The US Drought Monitor query by latitude and longitude point. The start and end dates are optional and default to period of record data. The archive begins on Jan 2000.
Returns JSON Table Schema This service uses JSON Table Schema for returned content.
Method GET Parameters:
sdate | Start Date (optional) |
---|---|
edate | End Date (optional) |
lon | East Longitude (deg) |
lat | North Latitude (deg) |
URI Pattern:
http://mesonet.agron.iastate.edu/json/current.py?station={station}&network={network}&callback=gotData
Description: The most recent observation for an IEM tracked site.
Method GET Parameters:
station | Station Identifier |
---|---|
network | Network Identifier |
URI Pattern:
http://mesonet.agron.iastate.edu/json/prism/{lon}/{lat}/{date_or_daterange}?callback=gotData
Description: Produces a daily time series for a grid cell that covers the specified latitude and longitude (negative E values). Credit: PRISM Climate Group, Oregon State University, created 4 Feb 2004.
Method GET Parameters:
lat | Latitude (deg N) |
---|---|
lon | Longitude (deg E) |
date_or_daterange | YYYYmmdd or YYYYmmdd-YYYYmmdd (inclusive) |
URI Pattern:
http://mesonet.agron.iastate.edu/json/stage4/{lon}/{lat}/{utc_date}?callback=gotData
Description: This service provides a grid point sampling of the NCEP Stage IV product. The date provided the service is a UTC date. Note that the hourly stage IV data does not receive the level of QC that the 6, 12, and 24 hour summaries do.
Method GET Parameters:
lat | Latitude (deg N) |
---|---|
lon | Longitude (deg E) |
utc_date | YYYY-mm-dd |
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/lsr.php?year={year}&wfo={wfo}&eventid={eventid}&phenomena={phenomena}&significance={significance}&callback=gotData
Description: Produces the storm reports that spatially and temporally coincide with a given Storm Based Warning. This only works for warnings that had polygons associated with them and not other VTEC products.
Method GET Parameters:
wfo | 3 character NWS Office |
---|---|
year | Year of VTEC Issuance |
phenomena | 2 character VTEC Phenomena Code |
significance | 1 character VTEC Significance Code |
eventid | VTEC Event ID |
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/lsr.php?sts={sts}&ets={ets}&wfos={wfos}&callback=gotData
Description: Produces the storm reports for a given office or offices valid for a specified period (inclusive).
Method GET Parameters:
wfo | 3 character NWS Office (comma seperated for multiple, leave blank for all) |
---|---|
sts | UTC Start Timestamp YYYYmmddHHMM |
ets | UTC End Timestamp YYYYmmddHHMM |
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/nexrad_attr.geojson?callback=gotData
Description: A GeoJSON summary of current NEXRAD Storm Attributes
Method GET Parameters:
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/nexrad_attr.geojson?valid={valid}&callback=gotData
Description: A GeoJSON summary of archived NEXRAD Storm Attributes. For the supplied UTC timestamp, the closest scan time within a 20 minute window is found for each RADAR. That scan time is returned.
Method GET Parameters:
valid | ISO-8601 timestamp YYYY-mm-ddTHH:MM:SSZ |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/networks.geojson?callback=gotData
Description: A GeoJSON listing of IEM labelled networks.
Method GET Parameters:
URI Pattern:
http://mesonet.agron.iastate.edu/json/ibw_tags.py?year={year}&wfo={wfo}&callback=gotData
Description: Produces a listing of Impact Warning Tags used in Severe Thunderstorm, Tornado, Marine, and Flash Flood Warnings warnings by NWS Forecast Office and Year.
Method GET Parameters:
wfo | 3 character NWS Office |
---|---|
year | Year of interest |
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/winter_roads.geojson?callback=gotData
Description: This service provides the most recent Iowa Winter Road Conditions.
Method GET Parameters:
URI Pattern:
http://mesonet.agron.iastate.edu/json/climodat_stclimo.py?station={station}&syear={syear}&eyear={eyear}&callback=gotData
Description: Produces a listing of daily climatology for an IEM tracked long term climodat site in the midwestern US.
Method GET Parameters:
station | 6 character station identifier |
---|---|
syear | Inclusive start year of the period of interest |
eyear | Exclusive end year of the period of interest |
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/climodat_dayclimo.py?network={network}&day={day}&month={month}&syear={syear}&eyear={eyear}&callback=gotData
Description: Produces a listing of climatology for a single state for a single day.
Method GET Parameters:
network | state network identifier |
---|---|
month | Numeric month of interest (1-12) |
day | Numeric day of interest (1-31) |
syear | Inclusive start year of the period of interest |
eyear | Exclusive end year of the period of interest |
URI Pattern:
http://mesonet.agron.iastate.edu/json/vtec_max_etn.py?year={year}&callback=gotData
Description: Produces a listing of the maximum eventid used for each NWS Forecast Office, VTEC Phenomena and VTEC Significance.
Method GET Parameters:
year | YYYY year |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/vtec_event.py?wfo={wfo}&year={year}&phenomena={phenomena}&etn={etn}&significance={significance}&callback=gotData
Description: Produces GeoJSON for a given VTEC Event.
Method GET Parameters:
wfo | 3 or 4 character WFO identifier |
---|---|
year | YYYY year |
etn | VTEC Event ID |
phenomena | 2 Character VTEC Phenomena Code |
significance | 1 Character VTEC Significance Code |
sbw | 1 or 0, flag to return Storm Based Polygon(1) or Counties |
lsrs | 1 or 0, flag to return local storm reports |
URI Pattern:
http://mesonet.agron.iastate.edu/json/vtec_event.py?wfo={wfo}&year={year}&phenomena={phenomena}&etn={etn}&significance={significance}&callback=gotData
Description: Produces metadata on a given VTEC Event.
Method GET Parameters:
wfo | 3 or 4 character WFO identifier |
---|---|
year | YYYY year |
etn | VTEC Event ID |
phenomena | 2 Character VTEC Phenomena Code |
significance | 1 Character VTEC Significance Code |
URI Pattern:
http://mesonet.agron.iastate.edu/json/vtec_events.py?wfo={wfo}&year={year}&callback=gotData
Description: Produces a listing of VTEC Events (watch, warning,advisories) by year by weather forecast office. You can optionally pass a
phenomena=XX
and
significance=X
to the service to only return that VTEC event
type for the given WFO and year. Additionally, there is a one-off feature
flag of combo=1
, which has the service return and Tornado,
Severe Thunderstorm, and Flash Flood Watches/Warnings in chronological order.Method GET Parameters:
wfo | 3 character WFO identifier |
---|---|
year | YYYY year |
URI Pattern:
http://mesonet.agron.iastate.edu/json/vtec_events_bystate.py?state={state}&year={year}&callback=gotData
Description: Produces a listing of VTEC Events (watch, warning, advisories) by year by state.
Method GET Parameters:
state | 2 character State identifier |
---|---|
year | YYYY year |
URI Pattern:
http://mesonet.agron.iastate.edu/json/vtec_events_bywfo.py?wfo={wfo}&start={start}&end={end}&callback=gotData
Description: Produces a listing of VTEC Events (watch, warning, advisories) by wfo with UGC information enumerated.
Method GET Parameters:
wfo | 3 character WFO identifier |
---|---|
start | ISO Start Datetime UTC (YYYY-MM-DDTHH:MM) |
end | ISO End Datetime UTC (YYYY-MM-DDTHH:MM) |
URI Pattern:
http://mesonet.agron.iastate.edu/json/nwstext_search.py?sts={sts}&ets={ets}&awipsid={awipsid}&callback=gotData
Description: Search of NWS Issued Text Products by a time period (in UTC) and an AWIPS ID (sometime called AFOS PIL). If you specify the AWIPS ID to be only three characters, the interruptation is to search of that base product identifier from any issuance center. For example, setting LSR would return all LSRXXX products.
Method GET Parameters:
sts | YYYY-mm-ddTHH:MMZ Inclusive start period (UTC) |
---|---|
ets | YYYY-mm-ddTHH:MMZ end time period (UTC) |
awipsid | 6 character or less AWIPS ID / AFOS PIL. |
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/cli.py?dt={dt}&fmt={fmt}&callback=gotData
Description: Provides a GeoJSON response summarizing all of the atomic processed data from the NWS issued CLI reports. These reports contain daily temperature, precipitation, and snow data from the primary climate sites.
Method GET Parameters:
dt | YYYY-mm-dd Date you want data for (optional) |
---|---|
fmt | Return format (optional) geojson (default) or csv |
URI Pattern:
http://mesonet.agron.iastate.edu/json/cli.py?station={station}&year={year}&fmt={fmt}&callback=gotData
Description: Provides a JSON response summarizing all of the atomic processed data from the NWS issued CLI reports for a single station and given year. You can optionally set
fmt=csv
to get a CSV
response.Method GET Parameters:
year | YYYY desired |
---|---|
station | ICAO 4-character station identifier |
fmt | Return format (optional) json (default) or csv |
URI Pattern:
http://mesonet.agron.iastate.edu/json/tms.json?callback=gotData
Description: Provides metadata about the currently available Tile Map Services provided by the IEM. This is useful to determine how to call back to the Tile Map Services.
Method GET Parameters:
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/sbw.geojson?ts={ts}&callback=gotData
Description: Provides a geojson format of current National Weather Service storm based warnings. There is a 15 second caching done by the server to ease load. The generation_time attribute is set on the output to diagnose when the file is valid. You can provide a timestamp to provide archived warnings back to 2002 or so. The polygons returned are the actualy ones valid at the given timestamp or realtime, so any polygon updates done with warning event are included here. There should only be one polygon per warning event.
Method GET Parameters:
ts | ISO-8601 Timestamp YYYY-mm-ddTHH:MI:SSZ (optional) |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/sbw.php?sts={sts}&ets={ets}&callback=gotData
Description: This service returns a GeoJSON of storm based warnings over a UTC time period of your coice. The start time is inclusive and the end time exclusive. The time domain denotes the issuance time of the storm based warning, so actual events returned could span over the end timestamp. The polygons returned are just the issuance and not any polygons with subsequent product updates.
Method GET Parameters:
sts | UTC Start Time YYYYmmddHMI |
---|---|
ets | UTC End Time YYYYmmddHMI |
URI Pattern:
http://mesonet.agron.iastate.edu/json/sbw_by_point.py?lon={longitude}&lat={latitude}&callback=gotData
Description: Provides a listing of storm based (polygon) warnings based on the provided latitude and longitude pair for warnings dating back to 1 Jan 2005.
Method GET Parameters:
lat | Latitude in degrees |
---|---|
lon | Longitude in (degrees east) |
URI Pattern:
http://mesonet.agron.iastate.edu/json/sbw_by_point.py?lon={longitude}&lat={latitude}&valid={valid}&callback=gotData
Description: Provides a listing of storm based (polygon) warnings based on the provided latitude and longitude pair for warnings dating back to 1 Jan 2005. You also provide an ISO-9660
valid
parameter to get any storm based warnings active
at the given UTC time and location.Method GET Parameters:
lat | Latitude in degrees |
---|---|
lon | Longitude in (degrees east) |
valid | UTC ISO-9660 timestamp |
URI Pattern:
http://mesonet.agron.iastate.edu/json/vtec_events_bypoint.py?lon={longitude}&lat={latitude}&sdate={sdate}&edate={edate}&callback=gotData
Description: Provides a listing of VTEC events that were valid for a given latitude and longitude point.
Method GET Parameters:
lat | Latitude in degrees |
---|---|
lon | Longitude in (degrees east) |
sdate | YYYY-mm-dd Start Date (UTC) |
edate | YYYY-mm-dd End Date (UTC) |
fmt | (optional) Format to download as: json (default) or xlsx |
URI Pattern:
http://mesonet.agron.iastate.edu/json/spcmcd.py?lon={longitude}&lat={latitude}&callback=gotData
Description: Provides a listing of Mesoscale Convective Discussions (MCD)s dating back to October 2008.
Method GET Parameters:
lat | Latitude in degrees |
---|---|
lon | Longitude in (degrees east) |
URI Pattern:
http://mesonet.agron.iastate.edu/json/spcoutlook.py?lon={longitude}&lat={latitude}&last={last}&day={day}&cat={cat}&callback=gotData
Description: Provides a listing of convective outlooks dating back to March 2002.
Method GET Parameters:
lat | Latitude in degrees |
---|---|
lon | Longitude in (degrees east) |
last | (Optional) Include only the last number of outlooks for each category, 0 is all |
day | (Optional) Which outlook day to request, defaults to 1 |
cat | (Optional) Which outlook category to request, defaults to CATEGORICAL |
URI Pattern:
http://mesonet.agron.iastate.edu/json/spcoutlook.py?lon={longitude}&lat={latitude}&time={time}&day={day}&cat={cat}&callback=gotData
Description: Provides a listing of convective outlooks dating back to March 2002 for a given timestamp.
Method GET Parameters:
lat | Latitude in degrees |
---|---|
lon | Longitude in (degrees east) |
time | Return the outlook valid at that time. This time can be a generic 'now' or some ISO-ish timestamp in the format YYYY-mm-ddTHH:MMZ. |
day | (Optional) Which outlook day to request, defaults to 1 |
cat | (Optional) Which outlook category to request, defaults to CATEGORICAL |
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/sps.geojson?callback=gotData
Description: Provides a geojson format of current National Weather Service polygons that are included with some Special Weather Statements (SPS).
Method GET Parameters:
URI Pattern:
http://mesonet.agron.iastate.edu/json/vtec_events_byugc.py?ugc={ugc}&edate={edate}&sdate={sdate}&callback=gotData
Description: Provides a json response of archived warnings valid for the given UGC code and date interval (UTC time, end date exclusive). The date of product issuance is used for the date filtering.
Method GET Parameters:
ugc | Five character UGC identifier used by the NWS |
---|---|
sdate | YYYY/mm/dd Start Date (UTC) |
edate | YYYY/mm/dd End Date (UTC) |
fmt | (optional) Format to download as: json (default) or xlsx |
URI Pattern:
http://mesonet.agron.iastate.edu/json/spcwatch.py?ts={timestamp}&callback=gotData
Description: Provides a geojson format of SPC watches valid at given time or current time if no time specified.
Method GET Parameters:
timestamp | YYYYMMDDHHMI UTC Timestamp (optional) |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/json/spcwatch.py?lon={lon}&lat={lat}&callback=gotData
Description: Provides a geojson format of SPC watches valid for a give latitude and longitude pair. Note that these polygons are not the official watch boundaries.
Method GET Parameters:
lat | Latitude in degrees |
---|---|
lon | Longitude in (degrees east) |
URI Pattern:
http://mesonet.agron.iastate.edu/json/raob.py?ts={timestamp}&station={station}&callback=gotData
Description: When provided a station and timestamp, returns a single RAOB profile. When provided no station and a timestamp, returns all profiles in the database for that timestamp. When provided a pressure [mb], returns just that pressure level's data. Realtime data from this service is typically available within 2 hours of observation time. For some RAOB sites, the IEM has a special identifier that merges period of record data for a general location. For example, _OAX merges the long term data for KOMA, KOAX, and KOVN.
Method GET Parameters:
sid | 3 or 4 character site ID used in North America |
---|---|
timestamp | YYYYMMDDHHMI UTC Timestamp |
URI Pattern:
http://mesonet.agron.iastate.edu/json/dcp_vars.php?station={station}&callback=gotData
Description: Provides SHEF variables provided by this station.
Method GET Parameters:
station | National Weather Service Location Identifier (nwsli) |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/geojson/network.py?network={network}&callback=gotData
Description: The IEM bunches observation stations into networks. This service provides metadata for sites within a network. A listing of networks can be found on this page.
Method GET Parameters:
network | IEM Network Identifier |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/json/products.php?callback=gotData
Description: The IEM generates and archives a large number of products. This service provides some metadata details necessary to build programic URIs against this archive of data. This service drives the Timemachine application.
Method GET Parameters:
URI Pattern:
http://mesonet.agron.iastate.edu/json/goes.py?operation=list&start={start}&end={end}&bird={bird}&product={product}&callback=gotData
Description: This service returns a listing of available GOES scan times for a period of time. This service will default to the past four hours worth of data when start and end times are not specified.
Method GET Parameters:
operation | Currently always 'list' |
---|---|
start | ISO-8601 UTC Timestamp (optional) |
end | ISO-8601 UTC Timestamp (optional) |
bird | GOES EAST or GOES WEST |
product | GOES Channel IR, VIS, or WV |
URI Pattern:
http://mesonet.agron.iastate.edu/json/radar?operation=available&lat={lat}&lon={lon}&start={start}&callback=gotData
Description: This service returns an estimate of which NEXRAD RADARs have imagery available for the timestamp and latitude / longitude location you specify.
Method GET Parameters:
lat | Point location latitude (degrees north) |
---|---|
lon | Point location longitude (degrees east) |
start | ISO-8601 UTC Timestamp |
URI Pattern:
http://mesonet.agron.iastate.edu/json/ridge_current.py?product={product}&callback=gotData
Description: This service returns a listing of the most recent image for a given product from all collected RADAR sites.
Method GET Parameters:
product | Level III Product {N0B, N0S, N0U, N0Z, NET} |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/json/radar?operation=products&radar={radar}&start={start}&callback=gotData
Description: This service returns available NEXRAD level 3 products for a given RADAR and date.
Method GET Parameters:
radar | NEXRAD 3 character identifier |
---|---|
start | ISO-8601 UTC Timestamp |
URI Pattern:
http://mesonet.agron.iastate.edu/json/radar?operation=list&radar={radar}&product={product}&start={start}&end={end}&callback=gotData
Description: This service returns NEXRAD volume scan times for a given RADAR, level 3 product, and start/end timestamp.
Method GET Parameters:
radar | NEXRAD 3 character identifier |
---|---|
product | Three character level 3 NEXRAD product identifier. |
start | ISO-8601 UTC Timestamp |
end | ISO-8601 UTC Timestamp |
URI Pattern:
http://mesonet.agron.iastate.edu/json/state_ugc.php?state={state}&callback=gotData
Description: This service returns metadata for UGC codes used by the National Weather Service to issue warnings for in a given state.
Method GET Parameters:
state | Two character state identifier |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/json/nwstext.py?product_id={product_id}&callback=gotData
Description: This service returns the raw text of a NWS Text Product.
Method GET Parameters:
product_id | String that uniquely (not fully) indentifies a text product. |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/json/stations.php?date={date}&callback=gotData
Description: This service returns metadata for any IEM tracked station locations with changed metadata since the given date. This provides a programic mechanism to keep up with metadata updates done on a daily basis.
Method GET Parameters:
date | Request changes since this date |
---|
URI Pattern:
http://mesonet.agron.iastate.edu/json/webcams.php?network={network}&ts={ts}&callback=gotData
Description: This service returns metadata on available webcam imagery for a given network that collects webcams and a UTC timestamp.
Method GET Parameters:
network | IEM Webcam network (KCCI, KELO, KCRG, IDOT) |
---|---|
ts | UTC Timestamp that you want images for |
That is all for now. Enjoy!