【问题标题】:Here Maps Calculate Matrix API returns "The request is missing the app_id and app_code parameters." error此处 Maps Calculate Matrix API 返回“请求缺少 app_id 和 app_code 参数。”错误
【发布时间】:2022-06-13 18:07:59
【问题描述】:

我正在尝试使用 API 密钥通过以下调用获取起点-终点矩阵的距离:

https://matrix.route.api.here.com/routing/7.2/calculatematrix.json?apiKey=[API Key Here]&start0=35.04672,-85.30947&start1=39.766998.49461&destination0=39.10344,-94.58311&destination1=39.76691,-86.14996&destination2=29.42458,-98.49461&mode=fastest;car;traffic:disabled

但它在响应详细信息中返回此错误:“请求缺少 app_id 和 app_code 参数。它们必须作为查询参数传递。如果您没有 app_id 和 app_code,请通过您的客户代表获取或http://developer.here.com/myapps."

但是这里的文档说我可以使用 ApiKey 或 App_code 和 App_id。 https://developer.here.com/documentation/routing/dev_guide/topics/resource-calculate-matrix.html

为什么它不能与 apiKey 一起使用?

【问题讨论】:

    标签: here-api distance-matrix


    【解决方案1】:

    您使用的基础 url 不正确,请将其替换为https://matrix.route.ls.hereapi.com/routing/7.2/calculatematrix.json 以与 API 密钥一起使用。

    https://matrix.route.api.here.com/routing/7.2/calculatematrix.json 将与 APPid 和 APPcode 一起使用。

    如需更多帮助,请参考https://developer.here.com/documentation/examples/rest/routing/one-to-many-matrix-routing的示例

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2019-03-13
      相关资源
      最近更新 更多