Skip to main content
Help the Python Software Foundation raise $60,000 USD by December 31st!  Building the PSF Q4 Fundraiser

OFD providers interface

Project description

pyofd is a Python package for receipts query from OFD providers. It is inspired by bobby_boy project.


Install via pip:

$ pip install pyofd

Install from source:

$ git clone git://
$ cd pyofd
$ python install


Here is basic usage example.

import pyofd, datetime

receipt = pyofd.OFDReceipt(
    fpd='FPD', total='total', rn_kkt='RN_KKT', fn='FN',
    fd='FD', inn='INN',
result = receipt.load_receipt()

OFDReceipt class might be constructed only with arguments known from receipt data, but omitting arguments might narrow the list of OFD providers to be checked against, because different providers require different subset of data to validate receipt


For some basic examples read unit tests in test directory. More complicated examples can be found within examples directory.

  • Load receipt by known attributes and save items into tab-delimited file.
  • Load receipt by known attributes and export it to MS Excel (r) .xlsx file. If official receipt check application credentials are provided in PYOFD_NALOGRU_LOGIN and PYOFD_NALOGRU_PASSWORD environment variables, receipt lookup via NalogRu provider is also performed. Excel file is filled with formulas and conditional formatting suitable for my personal receipt handling needs - column F is for partial refund and columns G to Z - for receipt entries categorization with autocounting subtotal across categories.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pyofd, version 0.1.6
Filename, size File type Python version Upload date Hashes
Filename, size pyofd-0.1.6.tar.gz (15.9 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page