0

我正在尝试通过 nodejs 模块为 ask-cli 获取一些指标。这是我的命令和错误:

ask smapi get-skill-metrics --skill-id amzn1.ask.skill.xxxxx --start-time 2020-10-14T12:45:00Z --end-time 2020-10-19T12:45:00Z --period PT1H --metric uniqueCustomers --stage live --skill-type custom --locale en-US > metrics.json 

[Error]: { "name": "AskSdkModelRuntime.DefaultApiClient Error" } 
4

1 回答 1

0

啊,是的,我的 VPN 阻止了请求。它现在可以工作,这是一个示例数据集。现在弄清楚这意味着什么:

Operation: getSkillMetricsV1
Payload:
{
  "skillId": "amzn1.ask.skill.xxxx-xx-xx-xx-xxxx",
  "startTime": "2020-10-14T12:45:00Z",
  "endTime": "2020-10-19T12:45:00Z",
  "period": "PT1H",
  "metric": "uniqueCustomers",
  "stage": "live",
  "skillType": "custom",
  "intent": null,
  "locale": "en-US",
  "maxResults": null,
  "nextToken": null
}

Response:
{
  "body": {
    "metric": "uniqueCustomers",
    "timestamps": [
      "2020-10-14T12:00:00Z",
      "2020-10-14T13:00:00Z",
      "2020-10-19T12:00:00Z"
    ],
    "values": [
      36,
      120,
      79,
      46 ]
  },
  "headers": [  ],

  "statusCode": 200
}
于 2020-10-19T17:24:16.470 回答