[OSM-dev] Structured error messages from API

Matthias Julius lists at julius-net.net
Thu Dec 10 16:16:10 GMT 2009

There are requests in JOSM's trac to improve the handling of API
errors.  To do that JOSM needs to get a better understanding on what
is wrong with the data.

Currently, JOSM is parsing the error strings the API is returning.
This is far from ideal because they are not structured, not documented
and might change without warning.

To improve things I would like to see the API extended to return meta
data about errors (error type, id of offending element, ...) in a
structured way.  There are a couple of ways to that (that came to my mind):

- change the Error header
- add home-made HTTP headers (X-Error-Type ...)
- add pseudo headers to the body
- return a XML document containing all the info

(see also http://trac.openstreetmap.org/ticket/2544)

What do you think?

How important is that to people on the receiving end (application

Any suggestions how the format should be?


More information about the dev mailing list