# ------------------------------------------------------------
# Copyright © 2026/2027 Dr. Mohammad Alja'afreh. All rights reserved.
# PSUT IoT Engineering Learning Platform
# ------------------------------------------------------------
# ---- One point by hand: POST line protocol to /api/v2/write
curl -i -X POST "http://localhost:8086/api/v2/write?org=psut&bucket=greenhouse&precision=s" \
  -H "Authorization: Token $INFLUX_TOKEN" \
  -H "Content-Type: text/plain; charset=utf-8" \
  --data-binary "environment,node=pi-02,site=psut-greenhouse,zone=B humidity=61.0,soil_moisture=48.5,temperature=25.4 $(date +%s)"
# HTTP/1.1 204 No Content   ← stored (no body)
