{"info":{"contact":{"email":"support@cointracker.com"},"description":"Experimental validation of a simple x402-paid API; not a product offering.","title":"CoinTracker x402 Weather Test","version":"v1","x-guidance":"Call GET /v1/weather/forecast with latitude and longitude. The endpoint returns an x402 v2 payment challenge; pay the exact USDC amount on Base mainnet and retry with PAYMENT-SIGNATURE."},"openapi":"3.1.0","paths":{"/health":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object"}}},"description":"Successful response"}},"security":[],"summary":"Weather API health check"}},"/openapi.json":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object"}}},"description":"Successful response"}},"security":[],"summary":"Weather API OpenAPI document"}},"/ready":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object"}}},"description":"Successful response"}},"security":[],"summary":"Weather API readiness check"}},"/v1/services":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object"}}},"description":"Successful response"}},"security":[],"summary":"List weather API services"}},"/v1/weather/forecast":{"get":{"description":"Return a normalized National Weather Service forecast for a United States coordinate. Use query parameters as the canonical invocation. Each coordinate must be supplied in either the query string or JSON body; query parameters take precedence over same-named JSON fields.","operationId":"getWeatherForecast","parameters":[{"description":"Latitude in decimal degrees. Supply both coordinates across the query string and/or JSON body.","in":"query","name":"latitude","required":false,"schema":{"maximum":90,"minimum":-90,"type":"number"}},{"description":"Longitude in decimal degrees. Supply both coordinates across the query string and/or JSON body.","in":"query","name":"longitude","required":false,"schema":{"maximum":180,"minimum":-180,"type":"number"}}],"requestBody":{"content":{"application/json":{"example":{"latitude":37.7749,"longitude":-122.4194},"schema":{"properties":{"latitude":{"maximum":90,"minimum":-90,"type":"number"},"longitude":{"maximum":180,"minimum":-180,"type":"number"}},"type":"object"}}},"description":"Best-effort alternative for clients that support GET request bodies; code generators may omit it. Use query parameters as the canonical invocation.","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"properties":{"coordinates":{"properties":{"latitude":{"maximum":90,"minimum":-90,"type":"number"},"longitude":{"maximum":180,"minimum":-180,"type":"number"}},"required":["latitude","longitude"],"type":"object"},"experimental":{"type":"boolean"},"fetchedAt":{"format":"date-time","type":"string"},"location":{"properties":{"city":{"type":["string","null"]},"state":{"type":["string","null"]}},"required":["city","state"],"type":"object"},"periods":{"items":{"properties":{"detailedForecast":{"type":["string","null"]},"endTime":{"format":"date-time","type":["string","null"]},"icon":{"format":"uri","type":["string","null"]},"isDaytime":{"type":["boolean","null"]},"name":{"type":["string","null"]},"probabilityOfPrecipitationPercent":{"type":["number","null"]},"shortForecast":{"type":["string","null"]},"startTime":{"format":"date-time","type":["string","null"]},"temperature":{"type":["number","null"]},"temperatureTrend":{"type":["string","null"]},"temperatureUnit":{"type":["string","null"]},"windDirection":{"type":["string","null"]},"windSpeed":{"type":["string","null"]}},"type":"object"},"type":"array"},"service":{"const":"x402-weather-test","type":"string"},"source":{"const":"National Weather Service","type":"string"},"updated":{"format":"date-time","type":["string","null"]}},"required":["service","experimental","source","fetchedAt","coordinates","location","periods"],"type":"object"}}},"description":"Successful forecast response"},"400":{"description":"Invalid latitude or longitude"},"402":{"description":"Payment Required"},"502":{"description":"National Weather Service returned an invalid response"},"503":{"description":"National Weather Service is unavailable"}},"summary":"National Weather Service forecast","x-payment-info":{"price":{"amount":"0.01","currency":"USD","mode":"fixed"},"protocols":[{"x402":{}}]}}}}}
