How do I get XML output from JXAPI?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

How do I get XML output from JXAPI?

brycenesbitt
I'm reading http://wiki.openstreetmap.org/wiki/Jxapi which kind of implies I should
expect XML from jxapi.  But what I get back is JSON formatted data.  How can I get XML?

(I'm using
wget "<a href="http://jxapi.openstreetmap.org/xapi/api/0.6/way[amenity=foo]">http://jxapi.openstreetmap.org/xapi/api/0.6/way[amenity=foo]"
)

_______________________________________________
talk mailing list
[hidden email]
https://lists.openstreetmap.org/listinfo/talk
Reply | Threaded
Open this post in threaded view
|

Re: How do I get XML output from JXAPI?

Ian Dees
brycenesbitt wrote
I'm reading http://wiki.openstreetmap.org/wiki/Jxapi which kind of implies I should expect XML from jxapi.  But what I get back is JSON formatted data.  How can I get XML?

(I'm using wget "http://jxapi.openstreetmap.org/xapi/api/0.6/way[amenity=foo]")
You should. A change I made recently screwed up the order of json/xml responses. Paul created a bug here for this and I'll probably fix it today:

https://github.com/iandees/pyxapi/issues/4

In the meantime, if you add a --header="Accept: text/xml" flag to your wget you'll probably get XML back.