LoRaWAN Integration
Connect any LoRaWAN sensor to HydroNode with a single HTTPS webhook. Works with The Things Network, ChirpStack, and Helium. No AWS account required.
One unified webhook endpoint
HydroNode exposes a single webhook URL that auto-detects whether the incoming uplink is from TTN (v3) or ChirpStack (v4/v3). There are no separate endpoints and no per-network configuration.
POST https://hydronode.texhfexlabs.de/api/webhook/lorawan/uplink/{webhookToken}wht_…) in the URL proves the request belongs to your account. Never expires unless you rotate it. Before you start
- 1A sensor exists in HydroNodeCreate the sensor via the dashboard or API first.
- 2The sensor is saved as OutdoorOpen General settings, select Outdoor, and save. A LoRaWAN binding creates a Station Interface automatically, and only outdoor sensors can be stations.
- 3The physical DevEUI is at hand16 hex characters printed on the device, e.g.
a840411b2182cd44. - 4You know your payload layoutWhich fPort carries which channels and at which byte offsets (configured in Step 4).
Register your device on the network server
This is the one step that differs between networks.
- Open console.thethings.network and select your application.
- Go to End devices → Add end device.
- Enter JoinEUI / AppEUI, DevEUI, and AppKey from the device firmware.
- Complete registration, then note the DevEUI and Application ID.
- Log in to your ChirpStack instance and open (or create) an Application.
- Ensure a Device profile matches your device's LoRaWAN version.
- Go to Devices → Add device and enter the DevEUI + profile.
- Under the device's Keys tab set the AppKey (OTAA) or session keys (ABP). Note the DevEUI and Application ID.
Bind the device to your sensor
Done entirely in the HydroNode web app. Open your sensor and go to its Settings page, then use the LoRaWAN Binding card.
- 1Confirm the sensor is OutdoorIf it is still Indoor, change it under General settings and save before continuing.
- 2Enter the DevEUIThe 16 lowercase hex characters from your device (and noted in Step 02).
- 3Enter the LoRaWAN Application ID (optional)The Application ID from TTN or ChirpStack. Only needed if several applications share a DevEUI range; otherwise leave it blank.
- 4Click Save LoRaWAN BindingHydroNode creates the Station Interface automatically, generates your personal Webhook URL, and shows it in the same connection card.
- 5Reveal and copy the Webhook URLClick the eye icon to reveal it, then Copy. You paste this into the network server in Step 04.
Point the network server at your URL
- Application → Integrations → Webhooks → Add webhook → Custom webhook.
- Webhook format: JSON.
- Base URL: paste the Webhook URL you copied in Step 03.
- Enable Uplink message. Leave everything else default. No headers needed.
- Save changes.
Only devices whose DevEUI is registered in HydroNode are processed; the rest get a silent 401.
- Application → Integrations → HTTP.
- Event endpoint URL(s): paste the Webhook URL you copied in Step 03.
- Headers: leave empty.
- Enabled events: select up (uplink) at minimum.
- Submit.
Non-uplink events (join, ack…) return 400 and are safely ignored by ChirpStack.
Configure fPort decoding
Each fPort carries a fixed set of channels packed into the payload bytes. You tell HydroNode how to decode them in the web app: on the same sensor Settings page, scroll to fPort Configurations. See Sensor Types for the supported types and encodings.
- 1Click Add fPortSet the fPort number (1–223) your firmware sends on, and an optional description.
- 2Add one channel per valuePick a Sensor Type (presets auto-fill bytes, encoding, scale, and unit), then adjust Bytes, Encoding (signed/unsigned), Scale Factor, Channel Name, and Unit if needed. Choose Custom for a type not in the list.
- 3Order the channelsChannels decode top to bottom, big-endian, with no gaps. Use the up/down arrows so the order matches the byte layout your device transmits.
- 4Click CreateRepeat for every fPort your device uses. Existing configs can be edited or deleted from the same list.
400 no-fport-config and routed to the dead-letter queue. Configure the fPort before sending live data.Native payload formats (auto-detected)
No transformation needed. HydroNode reads each network's native JSON.
{
"end_device_ids": {
"dev_eui": "a840411b2182cd44",
"application_ids": {
"application_id": "my-app"
}
},
"uplink_message": {
"f_port": 1,
"frm_payload": "AQH0AgBk",
"rx_metadata": [
{ "rssi": -85, "snr": 7.2 }
]
}
}{
"deviceInfo": {
"devEui": "a840411b2182cd44",
"applicationId": "abc123"
},
"fPort": 1,
"data": "AQH0AgBk",
"rxInfo": [
{ "rssi": -85, "snr": 7.2 }
]
}Confirm it works
Trigger a test uplink (TTN's Simulate uplink or a real transmission). On success, the server logs LoRaWAN uplink processed: network=… devEui=… fPort=… and the value appears under the sensor.
| Code | Meaning | What to do |
|---|---|---|
| 202 | Uplink received and queued | Nothing, success |
| 400 | no-fport-config | Configure the fPort (Step 05) |
| 400 | Missing payload / Invalid fPort | Join or MAC frame, safe to ignore |
| 400 | Payload error | Check the channel order in the fPort config |
| 401 | Unknown device / Unauthorized | Bind the DevEUI (Step 03) or check the token in the URL |
| 403 | Device not owned by token user | DevEUI belongs to another account |
| 500 | Internal error | Check HydroNode logs |
202 arrives and a value shows up on the sensor, the integration is live. Every other device in the same application that you register in HydroNode starts flowing automatically.