Guide

Log a temperature from Home Assistant

Got an outdoor sensor in Home Assistant? Push its reading to LawnDash every hour and the nightly summary will take the day’s high and low from your own backyard instead of the weather station.

1. Get your device token

In the app, open Profile → Weather Device Token. Treat it like a password — it’s all a request needs. You can reset it from the same place if it ever leaks.

Then switch Use weather provider off in GDD Settings. While the provider is on it stays authoritative and your readings are stored but not used for the summary.

2. Add a REST command

In configuration.yaml. Replace DEVICE_TOKEN_HERE with your token. sensorId and location are optional labels — put whatever helps you tell readings apart.

rest_command:
  my_lawndash_rest_command:
    url: https://api.lawndash.app/api/Device/temperatures
    method: POST
    headers:
      X-Device-Token: DEVICE_TOKEN_HERE
    content_type: application/json
    payload: '{"value": {{ inTemperature }}, "unit": "C", "sensorId": "1", "location": "1"}'

3. Add an automation

Every hour, read your sensor and call the command. Change sensor.my_outdoor_sensor_temperature to your entity. Create it in Settings → Automations and paste this in YAML mode, or drop it into automations.yaml.

alias: Log Temperature to LawnDash
description: ""
triggers:
  - trigger: time_pattern
    hours: /1
conditions: []
actions:
  - action: rest_command.my_lawndash_rest_command
    metadata: {}
    data:
      inTemperature: "{{ states('sensor.my_outdoor_sensor_temperature') | float(0) }}"
mode: single

Try it first

One reading from the command line, to make sure the token works before you automate it:

curl -X POST https://api.lawndash.app/api/Device/temperatures \
  -H "X-Device-Token: DEVICE_TOKEN_HERE" \
  -H "Content-Type: application/json" \
  -d '{"value": 21.5, "unit": "C", "sensorId": "1", "location": "1"}'

Good to know

  • unit can be C, F or K. Celsius is the default.
  • Hourly is plenty. The summary only needs the day’s max and min.
  • Your own readings carry no rainfall, so rain-based features (the 7-day rain gauge, auto-logged Rain days) need the weather provider.
  • The full request and response shapes are in the API reference under Device.