Device name as variable for webhook


#1

Hi all, I am finalising an application that will be deployed using Electrons powered via solar, so power and data minimisation are important. The implementation will have multiple Electrons sending a small payload every 10 minutes to a common web-service via particle publish.

I can use the coreid within the json to uniquely identify the source of the payload, but would prefer to use the device name as this is fewer bytes and more meaningful in the dashboard reporting supporting the implementation.

I could include Particle.subscribe("spark/", handler); Particle.publish("spark/device/name"); within the Electron code and and then send the device-name back as part of the data, however this incurs 2 additional cloud calls and a slightly larger payload.

Does anyone know of a means to derive this from within the webhook json or can inclusion of {{spark_core_name}} as a webhook variable be a future consideration.

Thanks, Dean


Device name as a webhook variable options
#2

Hey Dean, did you ever get a solution to this? I am looking to do the same thing.


#3

Me too!

EDIT:

Found answer here: