【问题标题】:Ruby HTTPI gem for Amazon Product API returns SignatureDoesNotMatch用于 Amazon 产品 API 的 Ruby HTTPI gem 返回 SignatureDoesNotMatch
【发布时间】:2014-07-26 17:49:56
【问题描述】:

我一直在为使用 HTTPI.get(url) 的亚马逊产品 API 调试 ASIN gem 它工作正常,直到最近,HTTPI.get(url) 请求返回以下错误:

HTTPI GET request to webservices.amazon.com (excon)
got response='<?xml version="1.0"?>
<ItemSearchErrorResponse xmlns="http://ecs.amazonaws.com/doc/2011-08-01/"><Error>
<Code>SignatureDoesNotMatch</Code>
<Message>The request signature we calculated does not match the signature you provided. Check your AWS Secret Access Key and signing method. Consult the service documentation for details.</Message></Error>
<RequestId>b73cc1c9-a682-453f-a8c8-1fcc5d1f3767</RequestId></ItemSearchErrorResponse>'

我的 httpi gem 是 v2.2.4 我也尝试使用 HTTParty.get(url) 效果很好

这可能是什么原因造成的?

【问题讨论】:

    标签: ruby-on-rails-3.2 httparty amazon-product-api httpi


    【解决方案1】:

    结果证明这是一个 HTTPI 版本控制问题。

    HTTPI 2.0.0 正常工作,但最新版本 2.2.4 有这个问题

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-05-04
      • 1970-01-01
      • 1970-01-01
      • 2012-01-12
      • 2023-04-07
      相关资源
      最近更新 更多