Architecture

Inverter ──RS485──▶ Eybond WiFi stick ──WiFi──▶ ShineMonitor cloud
                                                     ▲
                                  signed HTTPS, your login, server-side
                                                     │
Browser ──HTTPS + session cookie──▶ Helio (Next.js, your Vercel project)
  • No central server. Each person deploys their own copy, and it talks to ShineMonitor with their own login.
  • No database. Every number is fetched on demand and cached in memory per server instance: 60 seconds for generation, 10 minutes for alarms, an hour for weather. A cleaning date or location you set on the dashboard stays in that browser.
  • ShineMonitor signing follows their documented scheme: log in with sign = SHA1(salt + SHA1(password) + action), then sign each request with SHA1(salt + secret + token + action). Tokens are cached and refreshed automatically.
  • Plant discovery. Helio asks ShineMonitor for the account's plants (queryPlants) rather than trusting a configured id, because the id shown on shinemonitor.com can differ from the API id.

ShineMonitor calls used

auth, queryPlants, queryPlantInfo, queryPlantActiveOuputPowerCurrent, queryPlantEnergyDay, queryPlantEnergyTotal, queryPlantEnergyMonthPerDay, queryPlantEnergyYearPerMonth, queryPlantActiveOuputPowerOneDay, queryPlantDeviceStatus, queryCollectorInfo, queryDeviceLastData, queryDeviceDataOneDayPaging, queryDeviceWarning.

Other services

Open-Meteo for daily sunshine and rain (shortwave_radiation_sum, precipitation_sum), cached for an hour. It receives only coordinates rounded to 2 decimals. WEATHER=off disables it. For the optional daily alert, Telegram: through the Helio Solar bot's stateless relay at helio.rishishah.in/api/telegram/send, or the Telegram Bot API directly with your own bot. Vercel Cron (vercel.json) calls /api/cron/daily once a day.

Stack

Next.js 15 (App Router) · React 19 · TypeScript · Tailwind CSS v4 · UI primitives from Watermelon UI (shadcn/ui) · Recharts · Geist.

Project structure

app/
  page.tsx                dashboard
  demo/page.tsx           public demo with sample data
  login/page.tsx          sign-in
  api/solar/…             live data (session required)
  api/demo/…              sample data (public)
  not-found.tsx           animated 404
  api/auth/…              login / logout
components/
  dashboard.tsx           the dashboard (live and demo)
  charts.tsx              power curve, grid voltage, bar charts, sparkline
  health-card.tsx         system health, cleaning advice, today's estimate, location, export dialog
  inverter-card.tsx       live inverter readings, grid check, alarms, WiFi stick
  alerts-card.tsx         daily alert status, preview and test
  brand.tsx               logo and footer credit
  ui/…                    Watermelon UI / shadcn primitives
lib/
  shinemonitor.ts         ShineMonitor client, data shaping, sample data
  inverter.ts             device readings, grid events, alarms, datalogger
  health.ts               health, cleaning and estimate maths; Open-Meteo
  handlers.ts             shared live/demo handlers for health, inverter, export, alerts
  alerts.ts               daily alert text and Telegram delivery
  csv.ts                  CSV writer
  auth.ts                 signed sessions
  guard.ts                per-route session check
  config.ts               every environment-driven setting
  links.ts                project / repo links
middleware.ts             route protection
scripts/test-login.mjs    check ShineMonitor credentials from a terminal
docs/                     these docs

Local development

git clone https://github.com/byrishi/helio.git && cd helio
npm install
npm run dev                  # http://localhost:3000/demo works with no setup
cp .env.example .env.local   # fill in to use your real data
npm run test:login           # checks your ShineMonitor login
npm run build                # type-checks and builds

Something wrong or unclear? Edit this page on GitHub