Appstore API供应商编号无效

2024-10-03 02:33:22 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在尝试在Appstore上使用API。我正在使用python连接,得到了无效的供应商编号错误。你知道吗

payload = {'filter[frequency]':'DAILY', 'filter[reportSubType]': 'SUMMARY', 'filter[reportDate]':'2019-03-01', 'filter[vendorNumber]': '12345678', 'filter[reportType]': 'SALES' }

以下是请求电话:

r = requests.get('https://api.appstoreconnect.apple.com/v1/salesReports', headers={'Authorization': 'Bearer {}'.format(token)}, params=payload)

以下是平台返回的错误:

{
  "errors" : [ {
    "id" : "285874b4-16fb-4109-b810-ffa2973be714",
    "status" : "400",
    "code" : "PARAMETER_ERROR.INVALID",
    "title" : "A parameter has an invalid value",
    "detail" : "Invalid vendor number specified. Try again.",
    "source" : {
      "parameter" : "filter[vendorNumber]"
    }
  } ]
}

平台不喜欢供应商编号。有没有其他人对这个问题感兴趣,并且能想出解决这个问题的办法? 谢谢


Tags: apiparameter错误平台summaryfilter供应商编号