【发布时间】:2021-08-20 22:13:03
【问题描述】:
Here are the seemingly clear instructions from Amazon.
只需发送以下内容:sellingPartnerId、developerId 和 mwsAuthToken
我用httparty 这样做:
query = {
sellingPartnerId: "A3Kxxxxx",
developerId: "753xxxx",
mwsAuthToken: "amzn.mws.8abxxxxx-xxxx-xxxx-xxxx-xxxxxx",
}
然后
send = HTTParty.get("https://sellingpartnerapi-na.amazon.com/authorization/v1/authorizationCode",
query: query
)
这会返回以下错误:
{"errors"=>
[{"message"=>"Access to requested resource is denied.",
"code"=>"MissingAuthenticationToken"}]}
我已经调整了每次看到的调用。我已阅读以下文章: This This
在 github 上为这个 API 翻阅了 695 个问题,但仍然没有运气。我已经将我的查询调整为这个,也没有运气:
query = {
grant_type: "client_credentials",
sellingPartnerId: "A3K98Oxxxxxx",
developerId: "753xxxxxxxx",
mwsAuthToken: "amzn.mws.8abxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx",
client_id: "amzn1.application-oa2-client.xxxxxxxxxxxxxxxxxxxxxxxx",
client_secret: "a473e76XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
scope: "sellingpartnerapi::migration"
}
我试过的都没有用。有什么建议吗?有没有人成功地将他们的 MWS 迁移到 SP-API 凭证?
【问题讨论】:
标签: amazon-web-services amazon-mws amz-sp-api