我使用 Here Geocoder Api。访问下面的行:
当我访问旧帐户时,我没有任何问题,我收到了整个列表,但是,当使用几天前创建的新帐户时,我收到禁止的信息,返回:
{
"details": "invalid credentials for ",
"additionalData": [],
"type": "PermissionError",
"subtype": "InvalidCredentials"
}
我需要做什么才能让它发挥作用?
{
"Response": {
"MetaInfo": {
"Timestamp": "2023-10-27T12:45:45.778+0000"
},
"View": [
{
"_type": "SearchResultsViewType",
"ViewId": 0,
"Result": [
{
"Relevance": 1,
"MatchLevel": "houseNumber",
"MatchQuality": {
"District": 1,
"Street": [
1
],
"HouseNumber": 1
},
"MatchType": "pointAddress",
"Location": {
"LocationId": "NT_D36pwaEH49v0rDK8QaWiIC_0UD",
"LocationType": "address",
"DisplayPosition": {
"Latitude": -22.9509,
"Longitude": -43.18727
},
"NavigationPosition": [
{
"Latitude": -22.95093,
"Longitude": -43.18742
}
],
"MapView": {
"TopLeft": {
"Latitude": -22.9497758,
"Longitude": -43.1884908
},
"BottomRight": {
"Latitude": -22.9520242,
"Longitude": -43.1860492
}
},
"Address": {
"Label": "Rua Dezenove de Fevereiro, 45, Botafogo, Rio de Janeiro - RJ, 22280-030, Brasil",
"Country": "BRA",
"State": "RJ",
"City": "Rio de Janeiro",
"District": "Botafogo",
"Street": "Rua Dezenove de Fevereiro",
"HouseNumber": "45",
"PostalCode": "22280-030",
"AdditionalData": [
{
"value": "Brasil",
"key": "CountryName"
},
{
"value": "Rio de Janeiro",
"key": "StateName"
}
]
}
}
}
]
}
]
}
}
我认为地理编码 api 将逐步淘汰,您应该使用地理编码和搜索 api。 https://www.here.com/docs/category/geocoding-search-v7