Is there a way to make a Cloud variable public?

Can I somehow access a cloud variable sent from a Photon public (so it can be accessed without an accesstoken).
The point is that I have a website that I would like to use to display the varible publicly…

Best Regards

Not that I’m aware of.
You could use PHP to obfuscate the access token to the server side I believe.

The reason why you need the access token to get the value of a Particle.variable() is that these values are not pushed to the cloud where they could be accessed publicly but you’d “instruct” the respective device to hand you the value there and then and for that you need access to the device.

1 Like

@ScruffR: So if i get it correctly…
When i request a variable from the cloud, the cloud forwards the request to the device. So would it be better to use an event with a repeated update and/or long enough TTL to make sure its always available instead?

Pushing via Particle.publish(PUBLIC) will open the way for public access, but as well only for subscribers currently watching, the TTL parameter has no meaning yet. The cloud won’t buffer the events for now.
For the time being if you want historic values, you’d need to use a 3rd party service.