07-28-2016 09:38 AM - edited 03-01-2019 04:30 AM
Hi
This example is based on Adam's, very useful and helpful, Postman collection here:
apic-em-samples-aradford/tools/postman at master · CiscoDevNet/apic-em-samples-aradford · GitHub
In the attached image I am trying to create a location, with the POST /location request. In this example I have a geographicalLocation value of "-34/150". I have also tried other values with varying numbers of decimal points, and also a format with a "," instead of a "/".
I have yet to find a value for geographicalLocation that works. The second image attached shows the error I am getting (note that the attempt with a comma separator gave a format error message).
So, what is an example of a geographicalLocation that does work with the 1.2 GA release please?
Many thanks
Nathan
Solved! Go to Solution.
07-28-2016 02:37 PM
This bug has been reported a few weeks ago, should be fixed in the future release.
07-28-2016 11:51 AM
Try "geographicalAddress": "37.3230/122.0322".
Quiz: where is this location :-)
I think it doesn't take minus sign ?
07-28-2016 11:56 AM
Quizzes are easier with Google :-). It looks like Cupertino, but that should be "37.3230/-122.0322". It's actually
Weihai, Shandong, China.
07-28-2016 12:07 PM
FYI, this works for Wollongong:
{
"locationName":"Wollongong",
"geographicalAddress":"-34.416/150.883"
}
07-28-2016 12:14 PM
This one did not work for me.
It looks like minus signs are an issue here.
Regards
Nathan
07-28-2016 12:15 PM
Not for me
{ "locationName":"Wollongong", "geographicalAddress":"-34.416/150.883" }
{ "response": { "version": 1469733244499, "startTime": 1469733244499, "endTime": 1469733244695, "progress": "Adding location has failed.", "errorCode": "Inventory collection error", "serviceType": "Inventory service", "rootId": "5dee9441-023a-4ea3-b098-4c4a9de99546", "isError": true, "failureReason": "Coordinates in geographicalAddress are invalid", "id": "5dee9441-023a-4ea3-b098-4c4a9de99546" }, "version": "1.0" }
07-28-2016 12:19 PM
Yeah, when I looked at the task, it failed with the negative coordinate. This looks like a bug as I can't imagine what an alternate acceptable syntax would be for S and W.
07-28-2016 02:37 PM
This bug has been reported a few weeks ago, should be fixed in the future release.
07-28-2016 12:07 PM
Then can we get the right format for N vs S, E vs W ? Looks like it doesn't take "-" sign.
07-28-2016 12:13 PM
Yeah, looks like the negative sign does break it. I get a valid task ID, but it's an error. I don't know what another valid syntax might be. The negative sign is typical for South and West.
07-28-2016 12:12 PM
Thanks guys.
Addresses with positive numbers seem to work.
Negative numbers don’t.
That works for some portion of the planet, but not all …
Regards
Nathan
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide