Store details

29 views
Skip to first unread message

Shaun

unread,
Sep 25, 2009, 7:22:13 PM9/25/09
to Snooth API
When you do a request with the store id to return the store details
its not being returned in an array. It seems as though all the syntax
of the other returns have been returned as arrays.

like this
{"meta":{"results":1,"returned":1,"errmsg":"","status":1},"store":
[{"id":61254,"name":"Sousa's Wines & Liquors","num_ratings":0,"rating":
0,"address":"400 Moffett Blvd","city":"Mountain
View","state":"CA","country":"US","phone":"1-866-967-4946","url":"http:
\/\/www.sousawine.com\/"}]}

yet it seems like its being returned as
{"meta":{"results":1,"returned":1,"errmsg":"","status":1},"store":
{"id":61254,"name":"Sousa's Wines & Liquors","num_ratings":0,"rating":
0,"address":"400 Moffett Blvd","city":"Mountain
View","state":"CA","country":"US","phone":"1-866-967-4946","url":"http:
\/\/www.sousawine.com\/"}}

is this intentional?

I have previously used some javascript to do an ajax get then set the
response text to a var.
var r = transport.responseText.evalJSON(); then use
this.origArray.items = $A(r.store) to combine the store results to an
array thats been setup already.

It has worked for wine results wine details etc because they all have
[], I can even set var r to equal
{"meta":{"results":1,"returned":1,"errmsg":"","status":1},"store":
[{"id":61254,"name":"Sousa's Wines & Liquors","num_ratings":0,"rating":
0,"address":"400 Moffett Blvd","city":"Mountain
View","state":"CA","country":"US","phone":"1-866-967-4946","url":"http:
\/\/www.sousawine.com\/"}]}

and it will work

is there a reason the store details are different then how the others
are returned?

Thanks so much!

Shaun

unread,
Sep 27, 2009, 4:48:11 PM9/27/09
to Snooth API
Got it working another way.. no need to worry =P
Reply all
Reply to author
Forward
0 new messages