Skip to contents

A tidy interface to the U.S. Geological Survey (USGS) National Imagery Management System (NIMS) API (https://api.waterdata.usgs.gov/docs/nims/overview/), which stores and serves images collected by stream-gage cameras at monitoring locations across the United States. Provides functions to discover cameras by NWIS site number or camera ID, list and filter available images by date and time, download images at multiple resolutions, and assemble downloaded frames into animated GIFs or MP4 videos. Integrates with the 'dataRetrieval' package (https://doi-usgs.github.io/dataRetrieval/) to enrich camera records with watershed metadata (drainage area, hydrologic unit code, state, county) and to retrieve co-located streamflow, stage, or water-quality time series — enabling direct comparison of visual stream conditions with measured observations. API authentication uses the 'API_USGS_PAT' environment variable shared with 'dataRetrieval', so a single key covers both packages.

flowcam wraps the USGS National Imagery Management System (NIMS) API, providing functions to discover cameras at USGS stream gages, list available images, build image URLs, and download images to disk.

Main functions

Authentication

An API key is optional but prevents rate limiting. Register at https://api.waterdata.usgs.gov/signup/ and store your key with set_usgs_api_key(). The key is read from the API_USGS_PAT environment variable, the same variable used by dataRetrieval.

Author

Maintainer: Connor Brown ConnorBrown1996@gmail.com (ORCID)

Authors: