Vater
Python client providing convenient way to access polish VAT payers register API (version 1.3.0).
Installation
pip install vater
Usage
Scripts
>>> import vater
>>> client = vater.Client(base_url='https://wl-api.mf.gov.pl')
>>> client.search_nip(nip='0000000000')
(
Subject(
name='Beastie Boys',
nip='0000000000',
status_vat='Czynny',
regon='111111111',
pesel=None,
krs='0000000000',
residence_address=None,
working_address='Brooklyn',
representatives=[],
authorized_clerks=[],
partners=[
Company(
company_name='Mike D',
first_name='Michael',
last_name='Diamond',
nip=None,
pesel=None
)
],
registration_legal_date=datetime.date(2001, 1, 1),
registration_denial_basis=None,
registration_denial_date=None,
restoration_basis=None,
restoration_date=None,
removal_basis=None,
removal_date=None,
account_numbers=['00000000000000000000000000'],
has_virtual_accounts=False
),
'z5x71-85a8gl5'
)
If you want to get raw server json just set raw to True:
>>> client.search_nip(nip='0000000000', raw=True)
{
'result': {
'subject': {
'name': 'Eminem',
'nip': '0000000000',
'statusVat': 'Active',
'regon': '777777777',
'pesel': '77777777777',
'krs': '6969696969',
'residenceAddress': '8 mile',
'workingAddress': '8 mile',
'representatives': [
{
'companyName': 'Moby Dick Inc',
'firstName': 'sir Richard',
'lastName': 'Lion Heart',
'nip': '0000000000',
'pesel': '77777777777'
}
],
'authorizedClerks': [],
'partners': [],
'registrationLegalDate': '2001-01-01',
'registrationDenialBasis': 'Denial Basis',
'registrationDenialDate': '2002-02-02',
'restorationBasis': 'Restoration Basis',
'restorationDate': '2003-03-03',
'removalBasis': 'Removal Basis',
'removalDate': '2004-04-04',
'accountNumbers': ['00000000000000000000000000'],
'hasVirtualAccounts': False
},
'requestId': 'aa111-aa111aaa',
}
}
By default the data is fetched from today's date,
it can be changed by setting date argument:
>>> import datetime
>>> client.search_nip(nip='0000000000', date=datetime.date(2001, 1, 1))
String may also be passed as a date:
>>> client.search_nip(nip='0000000000', date='2001-01-01')
Keep in mind the API limits maximum number of requested subjects to 30.
CLI
| command |
|---|
vater search-nip [ACCOUNT] |
vater search-nip [ACCOUNTS] |
vater search-nip [NIP] |
vater search-nips [NIPS] |
vater search-nips [REGON] |
vater search-nips [REGONS] |
vater check-nip [NIP] [ACCOUNT] |
vater check-regon [REGON] [ACCOUNT] |
Each command allows to set --date parameter formatted as follows YYYY-MM-DD.
Default value is today's date.
Docs
Project docs may be found here: https://vater.readthedocs.io
Metadata
Release files for vater 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| vater-0.1.2.tar.gz | 14.1 kB | Without provenance | Details for vater-0.1.2.tar.gz |
Release files / vater-0.1.2.tar.gz
| Download URL | vater-0.1.2.tar.gz |
|---|---|
| Size | 14.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3446e171e4038f5a70788b556146fedafed7dc29c7c7a3b01782bb1b00a21c55
|
|
BLAKE2b-256 checksum How to use checksums |
092b0aeddfc1cc62e2dec8a8f93f74128deee125bce5794f1a6fb92923054e91
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3
|
Security for vater 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.