Tool for easy working with https://portal5.cbr.ru API
Project description
cbr-client
Клиент для работы с api ЦБ РФ
Описание АПИ - https://cbr.ru/lk_uio/guide/rest_api/
Установка
pip install cbr-client
Зависимости
Использование
from cbr_client import Client
client = Client(url='https://portal5test.cbr.ru/back/rapi2',
login='test',
password='test',
user_agent='test app')
files = [
('report.zip.enc', 'encrypted report content'),
('report.zip.enc.1.sig', 'operator signature'),
('report.zip.enc.2.sig', 'client signature')
]
# отправка отчета на портал ЦБ
msg = client.create_message(files, '1-ПИ')
client.upload(msg)
client.finalize_message(msg)
# получение квитанций
receipts = client.get_receipts(msg_id=msg.oid)
for rcpt in receipts:
client.download(rcpt)
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
cbr-client-0.1.5.tar.gz
(4.9 kB
view hashes)
Built Distribution
Close
Hashes for cbr_client-0.1.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a00f778376bf4f654cd2e35868e94152b5c4123ee7b35c70baf6e6eee29b365a |
|
MD5 | 464655bf67152718cd41ba9dd9041c5c |
|
BLAKE2b-256 | 0d888849cc70f5a70ddff154ef444aaf41efa570315cc732e221a28ec76e42b2 |