Logo Lanfrica

MatoloJr/shamba-weather

Domain:

agriculture

Record type:

software
Creator:
Mat
Host:
A Shamba Weather Farm Weather & Canopy Health Dashboard # Shamba Weather Farm Weather & Canopy Health Dashboard A small full-stack app built on the WeatherAI developer API, designed around what a non-technical farmer actually needs to decide, not around raw API numbers. It gives a Kenyan smallholder (or anyone) three things in one dashboard: 1. **This week's advice** a plain-language headline ("Good week for planting", "Hold off on planting"), spray-day guidance and risk flags (heavy rain, dry spell, frost, strong wind) generated from the forecast no meteorology knowledge required. The raw 7-day forecast is still there, tucked into a collapsible "Detailed forecast" section for anyone who wants it. 2. **Canopy Health Check** upload a drone/aerial/satellite photo of a farm plot and get back a tree count, canopy coverage %, per-tree health breakdown, an annotated overlay image and a plain-language summary of whether the trees need attention. 3. **PDF report** a two-part downloadable report: page 1 is the same plain-language summary in print form (handy to hand to someone without a smartphone), page 2 is the full technical/statistical detail for an agronomist or extension officer. Location is set either by tapping **"Use my location"** (browser geolocation, falling back to IP-based detection if permission is denied) or by entering coordinates manually no place-name search, to keep the API surface small and predictable. It was built as a technical assessment to demonstrate consuming a third-party REST API cleanly: an Express backend that keeps the API key server-side and a small vanilla-JS frontend with no build step. ## Why a backend at all? The WeatherAI API key is a secret. If the frontend called `api.weather-ai.co` directly, the key would sit in the browser's network tab for anyone to copy and burn through your monthly quota. Instead, the browser talks to *this* server and this server is the only thing that ever attaches the `Authorization: Bearer wai_...` header. ## Architecture ``` Browser (public/index.html + a …