
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
just wrapping Amazon Simple Product API
$ pip install -r requirements.txt
Choose 2 regions for endpoints, primary and secondary. If specified book information was not found in primary region, instead of that, this module will automatically get the information from secondary region. Of course, you can't necessarily get the information you want.
set environment variable APIAccessKey, APISecretKey, AssocTag.
$ AMAZON_ACCESS_KEY = "APIAccessKey"
$ AMAZON_SECRET_KEY = "APISecretKey"
$ AMAZON_ASSOC_TAG = "AssocTag"
or create test_settings.py
$ vim test_settings.py
AMAZON_ACCESS_KEY = "APIAccessKey"
AMAZON_SECRET_KEY = "APISecretKey"
AMAZON_ASSOC_TAG = "AssocTag"
If you didn't do above both of the above settings, you should pass those variables when you instantiate AmazonBook class. In the case of you imported this module, you have got to pass variables to AmazonBook constructor.
You can set primary and secondary regions from ["US", "FR", "CN", "UK", "IN", "CA", "DE", "JP", "IT", "ES"]
in instantiation. (default regions are "JP" and "US")
>>> from amabako import AmazonBook, is_isbn_validate
>>> a = AmazonBook(access_key, secret_key, assoc_tag)
>>> isbn = "9784048816592"
>>> print is_isbn_validate(isbn)
False
>>> isbn = "9781433551666"
>>> print is_isbn_validate(isbn)
True
>>> book = a.lookup(isbn, IdType="ISBN", SearchIndex="Books")
>>> print book.title
Holy Bible: English Standard Version, Value Compact Bible, Trutone Turquoise, Emblem Design
>>> print book.large_image_url
http://ecx.images-amazon.com/images/I/412mbT1AvIL.jpg
>>> print book.get_attribute('Publisher')
Crossway Books
>>> print book.price_and_currency
('1531', 'JPY')
FAQs
get book information by ISBN in some regions
We found that amaboko demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.