A Python class for EAN and ISBN name lookup and validation using the API on ean-search.org
Project description
EANSearch
A Python class for EAN and ISBN name lookup and validation using the API on https://www.ean-search.org
Compatible with Python 2.x and 3.x
from eansearch import EANSearch
# get a token from https://www.ean-search.org/ean-database-api.html
apiToken = "secret"
ean = "5099750442227" # Thriller
lookup = EANSearch(apiToken)
name = lookup.barcodeLookup(ean)
print(ean, " is ", name)
ok = lookup.verifyChecksum(ean)
print(ean, " is ", "OK" if ok else "Not OK")
eanList = eansearch.productSearch('iPod');
for product in eanList:
print(product["ean"], " is ", product["name"].encode("utf-8"))
eanList = eansearch.barcodePrefixSearch('4007249146');
for product in eanList:
print(product["ean"], " is ", product["name"].encode("utf-8"))
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
eansearch-1.0.4.tar.gz
(1.9 kB
view hashes)
Built Distribution
Close
Hashes for eansearch-1.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a5aab0c24f92af685c5f1e1a206996297b67de9943be9b75f68a7310b5d791ba |
|
MD5 | 02a7ad38bc08fade6b260099a481f689 |
|
BLAKE2b-256 | 326bc791eb9b2dec16b9da0b44afff0fd2b90d94ffbeeb914707456b36bdf01c |