Module to interact with Mouser's Search API
Project description
PyMouser
Installation
Install the package with pip.
pip install --user pymouser
Usage:
import pymouser
# Initialize the package with your API key
mouser = pymouser.MouserAPI('your-search-key')
# Search by Part-Number
err, res = mouser.search_by_PN('your-part-number')
# Check for errors or print the returned results
if err:
print("Error during request:")
print(err)
else:
if res['NumberOfResult'] == 0:
print("No results matched the part number")
else:
for match in res['Parts']:
print("Match for PartNumber .... %s" % match['MouserPartNumber'])
print("Description ............. %s" % match['Description'])
print("Link to datasheet ....... %s" % match['DataSheetUrl'])
print("Link to product page .... %s" % match['ProductDetailUrl'])
print("")
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
pymouser-0.8.tar.gz
(2.7 kB
view details)
Built Distribution
File details
Details for the file pymouser-0.8.tar.gz
.
File metadata
- Download URL: pymouser-0.8.tar.gz
- Upload date:
- Size: 2.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d182bf0b2c32e1818c267b9bd05faaf158d2661ff3f21a0c2444df46a2254ade |
|
MD5 | 41c17e10960534207b1d20afd66aa11d |
|
BLAKE2b-256 | 8ff1114e333d55ead708e3dba0e54cad6c6874f9414635d7decdcd0c515aa4a4 |
File details
Details for the file pymouser-0.8-py3-none-any.whl
.
File metadata
- Download URL: pymouser-0.8-py3-none-any.whl
- Upload date:
- Size: 3.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0825c90ad1cc99735140dad1d8b7d7578bd3e273b72ef56f0d08c0acb211c72d |
|
MD5 | ab5f962ee0327734b2d0a062e19b6359 |
|
BLAKE2b-256 | 08075588a6c22db801233394e096d5901728ac44d4dacd6e1ca161733c8ee584 |