views:

206

answers:

1

I'm having some problems trying to do an ItemSearch on the Blended index using the Amazon Product API.

According to the documentation, Blended requests cannot specify the MerchantId parameter - and indeed, if I try to include it I get an error telling me so. However, when I don't include it, I get an error telling me that my request is missing a required parameter combination and that a valid combination includes MerchantId... what the hell?

The failing requests are being sent as part of batches with other requests that are succeeding. I'm using REST to send my requests, so here's an example:

http://ecs.amazonaws.com/onca/xml?AWSAccessKeyId=-------------&
ItemSearch.1.Keywords=Mates%20of%20State&
ItemSearch.1.MerchantId=Amazon&
ItemSearch.1.SearchIndex=DVD&
ItemSearch.2.Keywords=teaching%20Lily%20various%20computer%20related%20skills&
ItemSearch.2.SearchIndex=Blended&
ItemSearch.Shared.Availability=Available&
ItemSearch.Shared.Condition=All&
ItemSearch.Shared.ResponseGroup=Small%2CSalesRank%2CImages%2COfferSummary%2CSimilarities&
Operation=ItemSearch%2CSimilarityLookup&
Service=AWSECommerceService&
SimilarityLookup.1.ItemId=B000FNNHZ2&
SimilarityLookup.2.ItemId=B000EQ5UPU&
SimilarityLookup.Shared.Availability=Available&
SimilarityLookup.Shared.Condition=All&
SimilarityLookup.Shared.MerchantId=Amazon&
SimilarityLookup.Shared.ResponseGroup=Small%2CSalesRank%2CImages%2COfferSummary&
Timestamp=2010-04-02T17%3A18%3A05Z&
Signature=----------------

Here's the XML response:

<Items xmlns="http://webservices.amazon.com/AWSECommerceService/2005-10-05"&gt;
  <Request>
    <IsValid>False</IsValid>
    <ItemSearchRequest>
      <Availability>Available</Availability>
      <Condition>All</Condition>
      <Keywords>teaching Lily various computer related skills</Keywords>
      <ResponseGroup>Similarities</ResponseGroup>
      <ResponseGroup>SalesRank</ResponseGroup>
      <ResponseGroup>OfferSummary</ResponseGroup>
      <ResponseGroup>Small</ResponseGroup>
      <ResponseGroup>Images</ResponseGroup>
      <SearchIndex>Blended</SearchIndex>
    </ItemSearchRequest>
    <Errors>
      <Error>
        <Code>AWS.MissingParameterCombination</Code>
        <Message>Your request is missing a required parameter combination. Required parameter combinations include MerchantId, Availability.</Message>
      </Error>
    </Errors>
  </Request>
</Items>

Any ideas as to what I'm doing wrong?

A: 

I seem to have solved this by removing both the Availability and Condition parameters. I'd ideally prefer to be able to filter by availability, but at least it's working.

Daniel Schaffer