title: Amazon Product Advertising API (ItemSearch with ItemPage)
body: <p>I wrote the following code:</p>
  
  <pre><code>from hashlib import sha256
  from base64 import b64encode
  import hmac
  import urllib
  from time import strftime, gmtime
  
  url = 'http://ecs.amazonaws.com/onca/xml'
  AWSAccessKeyId = amazon_settings.amazon_access_key_id
  AssociateTag = amazon_settings.amazon_associate_tag
  Keywords = urllib.quote_plus('Potter')
  Operation = 'ItemSearch'
  SearchIndex = 'Books'
  Service = 'AWSECommerceService'
  Timestamp = urllib.quote_plus(strftime("%Y-%m-%dT%H:%M:%S.000Z", gmtime()))
  Version = '2011-08-01'
  
  sign_to = 'GET\necs.amazonaws.com\n/onca/xml\nAWSAccessKeyId=%s&amp;AssociateTag=%s&amp;Keywords=%s&amp;Operation=%s&amp;SearchIndex=%s&amp;Service=%s&amp;Timestamp=%s&amp;Version=%s' % (AWSAccessKeyId, AssociateTag, Keywords, Operation, SearchIndex, Service, Timestamp, Version)
  
  Signature = urllib.quote_plus(b64encode(hmac.new(str(amazon_settings.amazon_secret_access_key), str(sign_to), sha256).digest()))
  
  request = '%s?AWSAccessKeyId=%s&amp;AssociateTag=%s&amp;Keywords=%s&amp;Operation=%s&amp;SearchIndex=%s&amp;Service=%s&amp;Timestamp=%s&amp;Version=%s&amp;Signature=%s' % (url, AWSAccessKeyId, AssociateTag, Keywords, Operation, SearchIndex, Service, Timestamp, Version, Signature)
  
  print request
  </code></pre>
  
  <p>When i use this code all fine.
  But if i try add ItemPage param to sign_to variable and to request variable i get error SignatureDoesNotMatch.</p>
  
  <p>Help me please.</p>