代码之家  ›  专栏  ›  技术社区  ›  david

从Foursquare搜索api获取单独的街道编号和街道名称?

  •  1
  • david  · 技术社区  · 8 年前

    我正在使用Foursquare的场地搜索API,一切都按预期工作。但是响应不包含街道编号和街道地址的单独字段。它包含一个名为“address”的字段,它同时包含这两个字段,如下面的示例所示

    "location": {
      "address": "180 Orchard St",
      "crossStreet": "btwn Houston & Stanton St",
      "lat": 40.72173744277209,
      "lng": -73.98800687282996,
      "labeledLatLngs": [
        {
          "label": "display",
          "lat": 40.72173744277209,
          "lng": -73.98800687282996
        }
      ],
      "distance": 8,
      "postalCode": "10002",
      "cc": "US",
      "city": "New York",
      "state": "NY",
      "country": "United States",
      "formattedAddress": [
        "180 Orchard St (btwn Houston & Stanton St)",
        "New York, NY 10002",
        "United States"
      ]
    

    0 回复  |  直到 8 年前
    推荐文章