noaa-tides
Library to fetch NOAA tide and currents data from their CO-OPS API.
The CO-OPS API is a single endpoint that supports multiple products with different response formats that can be requested with different combinations of query parameters. This library was built to provide a type-safe interface for building requests and deserializing responses into dedicated structs for each product.
Currently Supported Products
This library currently supports the following products:
- predictions: includes predicted tide heights for specified stations and date ranges. Supports
various options for datum, time zones, intervals and units. Returns a vector of tide predictions with
dateime, height an optional tide type if the
Interval::HighLowparameter is used.
Example Usage
Below is an example using the predictions product to fetch hourly tide predictions for the San
Francisco Golden Gate station for the month of January 2026. More examples can be found in the
examples/ directory.
use ;
use NaiveDate;
async