{
  "service": "tideq",
  "description": "Tide predictions for a station, from the agency that publishes them, or computed from TICON-4 where none does.",
  "usage": ["GET /stations/noaa:9414290                       -- highs, lows and the curve, 00:00 UTC yesterday for 7 days", "GET /stations/noaa:9414290?start=2026-09-14&days=3 -- a window: a UTC date, and 1 to 31 days", "GET /stations/noaa:9414290?debug=1               -- uncached, straight from the agency", "GET /stations/ticon:brest-822-fra-uhslc_fd       -- a TICON-4 gauge, computed by tideq", "GET /37.81,-122.47                               -- the nearest station within 25 km, and its tides", "GET /37.81,-122.47?within=50                     -- a wider reach, 1 to 100 km; start and days work here too", "GET /stations?q=golden gate                      -- stations by name, best match first", "GET /stations?lat=37.81&lon=-122.47&within=100   -- stations nearest first, 1 to 500 km, limit 1 to 200"],
  "answer": {
    "extremes": "Every high and low in the window: type, heightInMeters, and at, the moment it happens.",
    "curve": "The height every 15 minutes, as { at, heightInMeters }. Null for a station its agency publishes no curve for; notes says why.",
    "datum": "Heights are above the station's datum, named in station.datum: MLLW for NOAA, chart datum for CHS, Z0 for TICON. Never moved onto another agency's datum.",
    "times": "UTC, ISO 8601. at is when the tide happens; fetchedAt when tideq got it from the agency, or computedAt when tideq computed it from TICON's constituents; start and end the window the answer covers, end exclusive.",
    "available": "false with a reason when the agency has nothing for the station in that window, or when no station is within reach of a coordinate. A 502 means the agency failed, and says nothing about the station.",
    "nearest": "/{lat},{lon} answers for the nearest station, with station.distanceKm and bearingInDegrees from the point, and nearby: up to 5 other stations within reach, so a client can offer a switch."
  },
  "sources": ["NOAA CO-OPS: US tide predictions, 3,499 stations, public domain", "CHS (Fisheries and Oceans Canada): Canadian tide predictions, 1,095 stations, Open Government Licence – Canada", "TICON-4 (Hart-Davis, Dettmering and Seitz 2025, CC BY 4.0): harmonic constituents for 4,357 gauges worldwide, computed into predictions by tideq; a gauge an agency already lists is left out"],
  "auth": "None. CORS is open, so a browser can call this directly.",
  "repository": "https://github.com/gshaw/almanac/tree/main/services/tideq"
}
