Difference between revisions of "USGS Data Fetching"
Jump to navigation
Jump to search
(Created page with "== USGS Data Fetching == We use URLs of the following format to fetch USGS data: <pre> https://waterservices.usgs.gov/nwis/iv/?format=json&indent=on¶meterCd=00060,00065&...") |
|||
| Line 6: | Line 6: | ||
https://waterservices.usgs.gov/nwis/iv/?format=json&indent=on¶meterCd=00060,00065&siteStatus=all&sites=12141300&period=PT22M29.5308163S | https://waterservices.usgs.gov/nwis/iv/?format=json&indent=on¶meterCd=00060,00065&siteStatus=all&sites=12141300&period=PT22M29.5308163S | ||
</pre> | </pre> | ||
| + | |||
| + | This is provided by the "Instantaneous Values" service, documented here: https://waterservices.usgs.gov/docs/instantaneous-values/instantaneous-values-details/ | ||
The important pieces of the URL: | The important pieces of the URL: | ||
Revision as of 16:05, 29 May 2025
USGS Data Fetching
We use URLs of the following format to fetch USGS data:
https://waterservices.usgs.gov/nwis/iv/?format=json&indent=on¶meterCd=00060,00065&siteStatus=all&sites=12141300&period=PT22M29.5308163S
This is provided by the "Instantaneous Values" service, documented here: https://waterservices.usgs.gov/docs/instantaneous-values/instantaneous-values-details/
The important pieces of the URL:
- parameterCd=00060,00065 -- This indicates that we want parameters 00060 and 00065, which are water height and discharge
- sites=12141300 -- This is which gauge we want to look at
- period=PT22M29.5308163S -- This is the time range we want to fetch data for; basically it will be an encoded version of "since the last time we asked".