Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/albertyw/pyziptax
Python Module for the Zip-Tax.com API
https://github.com/albertyw/pyziptax
python python-3 tax
Last synced: 3 months ago
JSON representation
Python Module for the Zip-Tax.com API
- Host: GitHub
- URL: https://github.com/albertyw/pyziptax
- Owner: albertyw
- License: apache-2.0
- Archived: true
- Created: 2014-01-15T01:03:06.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2018-05-21T03:23:04.000Z (over 6 years ago)
- Last Synced: 2024-09-25T19:29:08.063Z (3 months ago)
- Topics: python, python-3, tax
- Language: Python
- Size: 22.5 KB
- Stars: 1
- Watchers: 5
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.rst
- Changelog: CHANGELOG.rst
- License: LICENSE
Awesome Lists containing this project
README
pyziptax
========|Latest Version| |Python Version| |License|
|Codeship Status for albertyw/pyziptax| |Dependency Status| |Code
Climate|Python API for Zip-Tax.com
Installation
------------``pip install pyziptax``
Usage Example
-------------.. code:: python
import pyziptax
# Single Tax Rate
pyziptax.api_key = ZIPTAX_KEY
rate = pyziptax.get_rate('10001', 'New York', 'NY')
# import decimal
# rate == decimal.Decimal('8.875')# Multiple Tax Rates
pyziptax.api_key = ZIPTAX_KEY
rate = pyziptax.get_rate('94304', multiple_rates=True)
# rate == {u'LOCKHEED': Decimal('8.250'), u'PALO ALTO': Decimal('8.750')}ZipTaxClient Parameters
------------------------ ``ZIPTAX_KEY`` - API key you received when you registered on
Zip-Tax.com
- ``zip_code`` - The only required parameter
- ``city`` - Optional
- ``state`` - Optional
- ``multiple_rates`` - If ``True``, returns a dictionary of city names
to tax rates; If ``False``, returns just the tax rate, but raises a
ZipTaxFailure if multiple rates were returned.Development
-----------Pull requests welcome!
.. code:: shell
# Set up repository for development
pip install tox
python setup.py install# Run tests
toxTo update PyPI:
.. code:: shell
pip install twine
python setup.py sdist bdist_wheel
twine upload dist/*.. |Latest Version| image:: https://img.shields.io/pypi/v/pyziptax.svg
:target: https://pypi.python.org/pypi/pyziptax/
.. |Python Version| image:: https://img.shields.io/pypi/pyversions/pyziptax.svg
.. |License| image:: https://img.shields.io/pypi/l/pyziptax.svg
:target: https://pypi.python.org/pypi/pyziptax/
.. |Codeship Status for albertyw/pyziptax| image:: https://codeship.com/projects/ac619bb0-acba-0132-14f9-4e5346bb67f3/status?branch=master
:target: https://codeship.com/projects/68576
.. |Dependency Status| image:: https://pyup.io/repos/github/albertyw/pyziptax/shield.svg
:target: https://pyup.io/repos/github/albertyw/pyziptax/
.. |Code Climate| image:: https://codeclimate.com/github/albertyw/pyziptax/badges/gpa.svg
:target: https://codeclimate.com/github/albertyw/pyziptax