{"name":"BKKx 3D Atlas API","version":1,"home":"https://atlas.nonarkara.org","about":"https://atlas.nonarkara.org/#about","paper":"https://atlas.nonarkara.org/labs/paper","endpoints":[{"path":"/api","method":"GET","description":"This catalog."},{"path":"/api/traffic","method":"GET","description":"Live iTIC/Longdo expressway traffic GeoJSON (proxied).","cacheSeconds":90},{"path":"/api/cctv","method":"GET","description":"Public iTIC/Longdo road cameras for Bangkok metro (HLS/JPEG).","cacheSeconds":300},{"path":"/api/flood-sensors","method":"GET","description":"Water-level gauges in the Bangkok metro, each judged by FloodDash (band, action, freshness).","cacheSeconds":60},{"path":"/api/flood/bkk","method":"GET","description":"FloodDash relay for Bangkok: city verdict, judged gauges, waterway status, BMA DDS canal gates and road reports. Not an official warning — DDPM 1784.","cacheSeconds":60},{"path":"/api/water/bkk/rain-stations","method":"GET","description":"ThaiWater v3 Bangkok provincial rain gauge network (133 stations with rain_24h + rain_1h).","cacheSeconds":300},{"path":"/api/water/bkk/kpi","method":"GET","description":"BKK observed rainfall totals (24h/3d/7d) and this week's temperature extremes with period start and station. Relay fetchedAt is fetch time, not observation time. No forecast in this endpoint.","cacheSeconds":300},{"path":"/api/water/bkk/incidents","method":"GET","description":"BKK incident heat — city-events + news-events + BMA DDS road reports + flood-sensors in prepare/evacuate bands, aggregated for flood-preset heat map.","cacheSeconds":120},{"path":"/api/water/bkk/canal-gates","method":"GET","description":"BMA Drainage bulletin: 10 Bangkok canal-gate stations with current water level vs critical level.","cacheSeconds":300},{"path":"/api/water/bkk/roads-flooded","method":"GET","description":"BMA DDS dated road reports for Bangkok: 66 road segments with depth, lanes, status (reported / cleared / unrecorded).","cacheSeconds":300},{"path":"/api/water/bkk/roads-xref","method":"GET","description":"Honest cross-reference: BMA DDS + Traffy + iTIC road reports cross-checked against FloodDash gauges (within 250 m). Pattern stolen from JK World (world.tehx.dyndns.info/flood).","cacheSeconds":300},{"path":"/api/presence","method":"GET","description":"Anonymous online counter — how many atlas tabs are open right now and today's peak. Pattern stolen from JK World presence.js.","cacheSeconds":0},{"path":"/api/presence/ping","method":"POST","description":"Heartbeat — register this tab as online for 5 minutes. Send the session id back as `x-atlas-session` on the next ping.","cacheSeconds":0},{"path":"/api/snap/<id>","method":"GET","description":"Maholan community-CCTV snapshot proxy (CCD origin: cctv.maholan.net/api/snap/<id>). Adds Access-Control-Allow-Origin so the atlas popup can render the JPEG inline; mirrors Maholan's cache-control and passes through X-Image-Time for age display. Returns an honest inline-SVG placeholder when upstream is down — never a broken-image glyph.","cacheSeconds":14400},{"path":"/api/water/bkk/emergency-points","method":"GET","description":"FloodDash confirmed emergency points for Bangkok + 30 km halo (news-anchored flood-affected locations with depth + impact).","cacheSeconds":120},{"path":"/api/water/bkk/dams","method":"GET","description":"FloodDash major dams (Bhumibol, Sirikit, Pasak, Kwae Noi) — storage %, inflow, release. Filtered to Chao Phraya + nearby basins.","cacheSeconds":300},{"path":"/api/water/bkk/alerts","method":"GET","description":"FloodDash active flood alerts (thaiwater_wl level changes + flash-flood precursors) — Bangkok + Chao Phraya upstream provinces.","cacheSeconds":120},{"path":"/api/water/bkk/sources-health","method":"GET","description":"FloodDash ingest health for 40 upstream feeds (BMA DDS, HII, ThaiWater, RID, GISTDA, PCD, Air4Thai, …) — last-run, failures, status.","cacheSeconds":120},{"path":"/api/water/bkk/news-watch","method":"GET","description":"FloodDash curated Thai flood-news feed (gnews_flood: Google News flood filter + Bangkok Post / Khaosod / Thai PBS / Reuters). Severity derived from title keywords.","cacheSeconds":120},{"path":"/api/water/bkk/maholan-cctv","method":"GET","description":"Maholan community CCTV aggregator (cctv.maholan.net) — 2,355 cameras across Thailand, filtered to BKK + 30 km halo. Includes YouTube + HLS + MJPEG + snapshot streams.","cacheSeconds":300},{"path":"/api/civic-pois","method":"GET","description":"BMA open-data civic amenities from D1.","query":["category?","district?","limit?"]},{"path":"/api/civic-pois/analysis","method":"GET","description":"Amenity counts aggregated by district for choropleths."},{"path":"/api/risk","method":"GET","description":"Point risk: schematic flood envelope × live PM2.5.","query":["lng","lat"],"example":"/api/risk?lng=100.5321&lat=13.7367","cacheSeconds":300},{"path":"/api/atlas/areas","method":"GET","description":"16 curated atlas areas (AI-readable mirror)."},{"path":"/api/atlas/districts","method":"GET","description":"50 khet + merged land-price summary."},{"path":"/api/atlas/at-this-point","method":"GET","description":"District + land + flood + nearest transit at a point.","query":["lng","lat"]},{"path":"/api/atlas/transit","method":"GET","description":"Nearest rail segments, scheduled boat corridors and passenger piers.","query":["lng","lat","radius?","limit?"]},{"path":"/api/atlas/buildings","method":"GET","description":"PMTiles pointers for 478K buildings."},{"path":"/api/atlas/scoreboard","method":"GET","description":"Single-object live health / inventory."},{"path":"/api/weather/google","method":"GET","description":"Legacy URL for Open-Meteo model weather and hourly rain forecasts. Road and electrical safety remain unknown.","query":["lng?","lat?"],"cacheSeconds":180},{"path":"/api/predict/timesfm","method":"GET","description":"Explicit unavailable status: no TimesFM inference service is connected. No river arrival times or flood depths are calculated.","query":["station?","hours?"],"cacheSeconds":60},{"path":"/bkk-buildings.pmtiles","method":"GET","description":"478,027 OSM buildings — HTTP Range from R2."},{"path":"/bkk-buildings-rattanakosin.pmtiles","method":"GET","description":"Rattanakosin detail buildings PMTiles (zoom 14–18)."}],"staticGeojson":["/bkk-areas.json","/bkk-rail.geojson","/bkk-water-transit.geojson","/bkk-khlongs.geojson","/bkk-buildings-rattanakosin.geojson","/bkk-traffic-sample.geojson","/bkk-flood-envelope.geojson","/bkk-civic-pois.geojson"],"note":"Civic demo layers are honest about provenance. Flood envelopes are schematic, not official DDPM/BMA extents. UI About drawer: /#about."}