Result Formats
Currently, two result formats are supported: xml and json.
XML
Example XML Error Response
No Format |
---|
<response><header><locale country="" language="en"/><timestamp>2009-05-15T15:40:30.031-04:00</timestamp><criteria><command><fmt>xml</fmt><include-provisional>false</include-provisional><hotspot>true</hotspot><rtype>loc</rtype><back>14</back><max-results>10000</max-results><detail>simple</detail></command></criteria><errors><error><error-msg>Please specify a region code</error-msg><error-code>error.data.rcodes_required</error-code></error></errors></header><result/></response>
|
JSON
Example JSON Error Response
The response will be an HTTP 400 error code, detailing the problems encountered in a simple JSON array:
No Format |
---|
[{"errorMsg":"Latitude out of range",
"errorCode":"error.data.lat_out_of_range"},
{"errorMsg":"Longitude out of range",
"errorCode":"error.data.lng_out_of_range"}]
|
Special Conditions and Error Handling
...