Black Lives Matter - Action and Equality. ... Adafruit is open and shipping.
0

Rest api format conversion missing data
Moderators: adafruit_support_bill, adafruit

Forum rules
If you're posting code, please make sure your code does not include your Adafruit IO Active Key or WiFi network credentials.
Please be positive and constructive with your questions and comments.

Rest api format conversion missing data

by gatorson on Fri Jan 29, 2016 4:56 pm

I am successfully able to "get" data using the rest api. However when i change the format to xml from the default json my latitude and longitude no longer come thru.
Json has full data:
"id":119180387,
"value":"0",
"position":null,
"lat":26.094135,
"lon":-80.254913,
"ele":-13.5,
"feed_id":511148,
"group_id":null,
"expiration":null,
"completed_at":"2016-01-29T20:54:51.452Z",
"created_at":"2016-01-29T18:17:29.951Z",
"updated_at":"2016-01-29T20:54:51.452Z",
"created_epoch":1454091449.95177

Xml missing data
Response content:
<?xml version="1.0" encoding="UTF-8"?>
<stream>
<id type="integer">119181203</id>
<value>0</value>
<position type="integer" nil="true"/>
<expiration type="dateTime" nil="true"/>
<feed-id type="integer">511148</feed-id>
<created-at type="dateTime">2016-01-29T18:17:55Z</created-at>
<updated-at type="dateTime">2016-01-29T20:55:31Z</updated-at>
<completed-at type="dateTime">2016-01-29T20:55:31Z</completed-at>
<location-id type="integer">53241</location-id>
<group-id type="integer" nil="true"/>
</stream>

gatorson
 
Posts: 10
Joined: Fri Jan 29, 2016 4:51 pm

Re: Rest api format conversion missing data

by jwcooper on Mon Feb 08, 2016 6:44 pm

Looks like a bug. I'll create an issue in our tracker. Thank you!

jwcooper
 
Posts: 679
Joined: Tue May 01, 2012 9:08 pm

Please be positive and constructive with your questions and comments.