uclinux 栈位置
假设您输入了用户输入的地址,例如1600 Pennsylvania Avenue NW,华盛顿特区,美国 ,现在您需要有关它的更多信息。 也许您需要正确的国家/地区代码。 也许您需要纬度和经度。 也许您需要邮政编码。
positionstack是一个可以做到这一点的API 。
它也相反。 因此,假设您有经度和纬度,则可能想找出确切的位置。 您可以将这些坐标发送给API,然后您会收到其中的响应。
https://api.positionstack.com/v1/reverse
? access_key = YOUR_ACCESS_KEY
& query = 40.7638435,-73.9729691
{
"data": {
"results": [
{
"latitude": 40.763841,
"longitude": -73.972972,
"label": "Apple Store, Manhattan, New York, NY, USA",
"name": "Apple Store",
"type": "venue",
"distance": 0,
"number": "767",
"street": "5th Avenue",
"postal_code": "10153",
"confidence": 1,
"region": "New York",
"region_code": "NY",
"administrative_area": null,
"neighbourhood": "Midtown East",
"country": "United States",
"country_code": "US",
"map_url": "http://map.positionstack.com/40.763841,-73.972972",
}
]
}
}
该API是由该公司apilayer制作的 ,对于公司而言 ,这似乎是一个非常明智的想法。 他们为各种开发人员任务制作了真正特定的API 。
相关文章链接:https://positionstack.com/
uclinux 栈位置