Constructing a query using the graphical interface

This page provides an overview of how to construct a GUI request using the AQS API (Query Air Data).

Procedure

  1. Navigate to the web page with the GUI.
    You should see a page like this
    GUI_screenshot.jpg
  2. Enter the query parameters using the drop-downs or typing.

    Field Instructions Required?
    User Name Your user name Required
    Password Your password
    Query Type Select rawData to run an interactive (synchronous) query where you will wait for the results to be returned to your browser. Select rawDataNotify to submit a query (asynchronous) that will send you an email when complete. (The request ID for process tracking is returned immediately). Note, both queries have limits on the amount of data that can be returned, rawDataNotify has larger limits. Also, rawDataNotify will display the URL that was used to build the query, which you can edit and use again, bypassing the GUI. Required
    Output Format The format of the file returned by the query. The possible values are DMCSV, AQCSV, and AQS (follow links for descriptions) Optional. Will default to DMCSV if not provided.
    Parameter Class The classification (group) of parameters to select (e.g., Criteria, HAP, meteorological). Note, selecting an entry here will return all members of the class. It will also shorten the list below (parameter code) to just those in the class for easier selection. One of these must be selected.
    Parameter Code The AQS parameter code of the measurements you would like.
    Begin Date The beginning date of the measurements you would like. Required
    End Date The ending date of the measurements you would like. Required
    Min Latitude
    Max Latitude
    Min Longitude
    Max Longitude
    The bounding box of the area you would like data from. Use decimal values, west and south are negative. A geography selection is required. It can be: bounding box, state, state + county, state + county + site, cbsa, or csa
    State Code The FIPS state code of the measurements you would like. Selecting a state will enable you to select a county within the state in the next box.
    County Code The FIPS county code of the measurements you would like. Selecting a county will enable you to select a site within the county in the next box.
    Site The unique site of the measurements you would like.
    CBSA The core based statistical area of the measurements you would like.
    CSA The consolidated statistical area of the measurements you would like.
    Duration The sample duration (e.g., hourly or daily) of the measurements you would like. Note, this query by default returns samples and sub-daily averages, so if you only want hourly samples, select 1-Hour. Optional, returns all sample durations and sub-daily averages by default.
    FRM Only Check if you would like only federal reference method (FRM) and federal equivalent method (FEM) data. Optional
  3. Click the submit button.

Results

You will get a file of data or a request ID (and, later, an email), depending on the type of query requested. Note, if running a synchronous query, the file may take several minutes to return. Any data you request from a synchronous service (rawData) will be returned to you as a text (.txt) file. Any data you request from an asynchronous service (rawDataNotify) will be returned to you as a zipped file (.tgz extension). Any list or status requests will be returned as plain text with tabs between fields.

If there is a problem with what you have selected (missing or invalid value, query exceeds limits, etc.) then you will get an error message describing the problem. Note, returning to the GUI using the back button will return you to an unpopulated form (usually); the application cannot recall your request parameters.
Result files are not sorted in any way.


Query size limits

Time span is defined as the difference between your begin date and end date.
For time span < = 1 year
  • State: 1 allowed
  • County: 1 allowed
  • Site: 1 allowed
  • CBSA: 1 allowed
  • CSA: 1 allowed
  • Bounding Box: (maxlat - minlat) + (maxlon - minlon) < = 50.0 allowed
For 1 year < time span < = 5 years
  • State: 0 allowed
  • County: 1 allowed
  • Site: 1 allowed
  • CBSA: 1 allowed
  • CSA: 1 allowed
  • Bounding Box: (maxlat - minlat) + (maxlon - minlon) < = 9.0 allowed
For 5 years < time span < = 20 years
  • State: 0 allowed
  • County: 1 allowed
  • Site: 1 allowed
  • CBSA: 0 allowed
  • CSA: 0 allowed
  • Bounding Box: (maxlat - minlat) + (maxlon - minlon) < = 0.5 allowed