[OSM-dev] Problem with XAPI and ref based search

Grégory Bataille gbataille.dev at gmail.com
Sat Nov 30 13:20:03 UTC 2013


Cool. Everything fits now. I was missing the syntax. Thanks for your
answers. I have what I need to progress further!

On Saturday, November 30, 2013, Paul Norman wrote:

> The dev API is an entirely separate API with its own data.
>
>
>
> As XAPI is an extension to the standard API, it does does support the
> standard object by ID calls, e.g.
> http://jxapi.openstreetmap.org/xapi/api/0.6/relation/2202120
>
>
>
>
>
> *From:* gregory.bataille at gmail.com <javascript:_e({}, 'cvml',
> 'gregory.bataille at gmail.com');> [mailto:gregory.bataille at gmail.com<javascript:_e({}, 'cvml', 'gregory.bataille at gmail.com');>]
> *On Behalf Of *Grégory Bataille
> *Sent:* Friday, November 29, 2013 11:51 PM
> *To:* Paul Norman
> *Cc:* dev at openstreetmap.org <javascript:_e({}, 'cvml',
> 'dev at openstreetmap.org');>
> *Subject:* Re: [OSM-dev] Problem with XAPI and ref based search
>
>
>
> oh god. I must have missed some combination when I had this idea. so what
> happens is that the data behind the dev OSM API seems partial. so when I
> started with overpass to do a complex query, the then OSM base API did not
> find the elements by id! the Prod API does though.
>
> I don't think the XAPI layer can do a search by ID (at least I haven't
> found one).
>
>
>
> but not I can finally tie things together. Thanks for putting me back on
> track!
>
>
>
> Cheers
>
>
>
> On Sat, Nov 30, 2013 at 8:26 AM, Grégory Bataille <gbataille.dev at gmail.com>
> wrote:
>
> that's exactly what I had suspected at some point, but I did not make it
> work then either, let me retry that once I'm fully awaken and I'll get back
> to you. Thanks for the quick answer.
>
>
>
> On Sat, Nov 30, 2013 at 4:16 AM, Paul Norman <penorman at mac.com> wrote:
>
> Ref is a reference to an object ID, not a ref tag. Instead of
> /api/0.6/relation[ref=2202120] you want /api/0.6/relation/2202120.
>
>
>
> I’m not 100% sure if the overpass compatibility layer will correctly
> handle the latter syntax.
>
>
>
> *From:* Grégory Bataille [mailto:gbataille.dev at gmail.com]
> *Sent:* Friday, November 29, 2013 4:42 AM
> *To:* dev at openstreetmap.org
> *Subject:* [OSM-dev] Problem with XAPI and ref based search
>
>
>
> hello everybody,
>
>
>
> I have been trying to use OSM data for a while. basically, first, I'd like
> to get the admin boundaries of France.
>
> I start by asking XAPI to give me the France admin_level 2 object like so:
>
>
> http://www.overpass-api.de/api/xapi?relation[boundary=administrative][admin_level=2][name=France]
>
>
>
> this returns me the object, which contains among other things:
>
> <member type="relation" ref="79981" role="outer"></member>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/dev/attachments/20131130/4620d06b/attachment.html>


More information about the dev mailing list