0

API REST POST Group Data: "data missing required value"
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

API REST POST Group Data: "data missing required value"

by INDOOR_GPK on Wed May 29, 2019 4:48 am

Hi there!

I'm using io.dafruit through the HTTP REST API.

A have 2 projects, on working fine and the second not working. Both are using ESP32 board and push data through httpClient.

I'm using this kind of entrypoint : https://io.adafruit.com/api/v2/<username>/groups/<group>/data to push data in one request instead send each feed by simple request

In each project i have put the "application/json" and "X-AIO-Key" headers

So first project works i send 4 feeds:
Code: Select all | TOGGLE FULL SIZE
{"feeds":[{"key":"moisture","value":3390},{"key":"pid-output","value":0},{"key":"setpoint","value":2575},{"key":"watering-duration","value":9200}]}

through
https://io.adafruit.com/api/v2/SOIL_GPK/groups/water-regul/data

And it's working well.

second project send 9 feeds:
Code: Select all | TOGGLE FULL SIZE
{"feeds":[{"key":"ec","value":0},{"key":"ec-pump-duration","value":0},{"key":"ec-pump-state","value":false},{"key":"ph","value":0},{"key":"ph-pump-duration","value":0},{"key":"ph-pump-state","value":false},{"key":"water-pump-duration","value":0},{"key":"water-pump-state","value":false},{"key":"water-temperature","value":0}]}

through
https://io.adafruit.com/api/v2/INDOOR_GPK/groups/indoor/data
and getting
error saving data to INDOOR_GPK/groups/indoor, data missing required value


I can reproduce this issue on ESP32 board and through POSTMAN software

INDOOR_GPK
 
Posts: 1
Joined: Wed May 29, 2019 4:25 am

Please be positive and constructive with your questions and comments.