Skip to content

Instantly share code, notes, and snippets.

@reizist
Created April 21, 2023 01:01
Show Gist options
  • Save reizist/f1069bd3675b484d2b0b8138f4ce2296 to your computer and use it in GitHub Desktop.
Save reizist/f1069bd3675b484d2b0b8138f4ce2296 to your computer and use it in GitHub Desktop.
AmazonProductAPIメモ(JAN=>ASINを試みた)
from amazon.paapi import AmazonAPI
import sys
if __name__ == "__main__":
amazon = AmazonAPI("ACCESS_KEY", "SECRET_KEY", "AFF_TAG","JP")
try:
products = amazon.get_items(item_ids=["4971633002005"], item_id_type="EAN")
except Exception as e:
print(e)
sys.exit(e)
print(products[0].asin)
@reizist
Copy link
Author

reizist commented Apr 21, 2023

(ApiException)
Reason: {"__type":"com.amazon.paapi5#TooManyRequestsException","Errors":[{"Code":"TooManyRequests","Message":"The request was denied due to request throttling. Please verify the number of requests made per second to the Amazon Product Advertising API."}]}

直近30日のアフィ実績ないとだめ

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment