diff --git a/app/api/views.py b/app/api/views.py index 4f870f5..953056e 100644 --- a/app/api/views.py +++ b/app/api/views.py @@ -165,7 +165,7 @@ def post(self, request, *args, **kwargs): # Record the time when the request was received time_received = datetime.datetime.now(datetime.timezone.utc) - if sensor_data: + if sensors_data: return JsonResponse({"status": "success, but no sensor data found"}, status=200) try: diff --git a/tests/stag/api-device-initial-station-info.http b/tests/stag/api-device-initial-station-info.http index 76fc1ed..91b1d03 100644 --- a/tests/stag/api-device-initial-station-info.http +++ b/tests/stag/api-device-initial-station-info.http @@ -7,10 +7,10 @@ content-type: application/json { "station": { "time": "2025-01-07T11:23:23.439Z", - "device": "string", + "device": "initial_station_info_test", "firmware": "string", "model": 0, - "apikey": "initialStationInfoTest", + "apikey": "initial_station_info_test", "sensor_list": [ {