[GIS] get center coordinates of a buiding(way)

coordinatesopenstreetmapoverpass-api

Using overpass-turbo I got data like this:

{
  "type": "way",
  "id": 292833530,
  "nodes": [
    2963934681,
    924717449,
    2963934682,
    2963934683,
    2963934684,
    2963934685,
    2963934686,
    2963934681
  ],
  "tags": {
    "addr:city": "Ivry-sur-Seine",
    "addr:housenumber": "134",
    "addr:postcode": "94200",
    "addr:street": "Avenue Danielle Casanova",
    "amenity": "post_office",
    "atm": "yes",
    "building": "yes",
    "change_machine": "yes",
    "moneo:loading": "yes",
    "name": "Ivry principal",
    "operator": "La Poste",
    "phone": "3631",
    "ref:FR:LaPoste": "17313A",
    "source": "data.gouv.fr:LaPoste - 01/2013",
    "stamping_machine": "yes",
    "wheelchair": "yes"
  }
}

Is there a way to get approxmatly the center of this building?
I use

http://api.openstreetmap.org/api/0.6/node/ + one of the node

to get coordinate for un point but I would like something more in the center of the building.

Best Answer

The following Overpass API Query will return the center of your building:

[out:json]; way(292833530); out center meta;