0

Is there a way I could retrieve the the Json Object that has the complete Nest Device List and their attributes?

I'm using firebase as suggested on the API documentation and I can listen to temperature changes made on the thermostat. The reason I need the Json is to set temperature through an android application I'm building.

This is the URL I'm using "https://developer-api.nest.com/"

Cœur
  • 37,241
  • 25
  • 195
  • 267
Mr.Noob
  • 1,005
  • 3
  • 24
  • 58

1 Answers1

1

Since you are developing for Android, the easiest way to get access is by using the Firebase Client.

Once you have that setup, read the Nest documentation about working with the thermostat data model.

David W. Keith
  • 2,246
  • 17
  • 20
  • Thanks david. I did have a look at it. What i don't understand is how i could set the temperature using the firebase. Do I need to have the json object retrieved for that or can i just update the values using firebase client – Mr.Noob Jul 16 '14 at 16:52
  • I managed to use REST and get the json object but then again I thought there is a more elegant way of getting it. one thing I noticed was everytime we make an authenticate with the firebase object it returns the data model inside a valueChangedEventListener. This may be one way of doing it I guess rather than using REST and FIREBASE together – Mr.Noob Jul 17 '14 at 12:30
  • You should use either REST or Firebase, not both. When you make a connection to Firebase you will get the current values for the subscribed data feeds (which is a good thing, as you would want to display the current setpoint before allowing the user to change it) Once the connection has been made you can send any valid value for a setpoint to the API. – David W. Keith Jul 18 '14 at 05:45
  • Yeah I'm doing that now. I'm retrieving the values once the connection is made using firebase. Thanks – Mr.Noob Jul 18 '14 at 06:19