DTA Generator
Generator library for Swiss DTA (“Datenträgeraustauschverfahren”) electronic payment records.
Features
Support for transaction types 826, 827, 836 and 890
Implements various integrity checks according to record description manual
Supports decimal and date input values
Getting started
Generate a DTA file containing one transaction of type 826:
from datetime import date
from decimal import Decimal
from dta import DTA
from dta.records import DTAHeader, DTARecord826, DTARecord890
dta = DTA()
header = DTAHeader()
header.sequence_nr = 1
header.sender_id = 'ABCDE'
header.client_clearing_nr = '248'
header.creation_date = date(2013, 4, 23)
header.processing_date = date(2013, 5, 10)
record = DTARecord826(header)
record.reference = '002013-0058'
record.liability_account = '248 110079.01Z'
record.currency = 'CHF'
record.amount = Decimal('114.35')
record.client_address1 = 'LEUCHTER OPEN SOURCE SOLUTIONS'
record.client_address3 = 'WINKELRIEDSTRASSE 45'
record.client_address4 = '6003 LUZERN'
record.recipient_account = '010723327'
record.recipient_address1 = 'TESTLIEFERANT'
record.recipient_address3 = 'TESTSTRASSE 10'
record.recipient_address4 = '6005 LUZERN'
record.esr_reference = '182171015574297'
dta.records.append(record)
header = DTAHeader()
header.sequence_nr = 2
header.sender_id = 'ABCDE'
header.client_clearing_nr = '248'
header.creation_date = date(2013, 4, 23)
record = DTARecord890(header)
record.amount = Decimal('114.35')
dta.records.append(record)
with open('demo.leu', 'w') as f:
f.write(dta.generate())
Metadata
Release files for python-dta 0.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 |
|---|---|---|---|---|
| python-dta-0.2.tar.gz | 18.8 kB | Without provenance | Details for python-dta-0.2.tar.gz |
Release files / python-dta-0.2.tar.gz
| Download URL | python-dta-0.2.tar.gz |
|---|---|
| Size | 18.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ba0b7364778d214d4a9a3afffe8b2b5113f7594772a44923010b9980a3b99fbc
|
|
BLAKE2b-256 checksum How to use checksums |
3c658fe26cb2d21bcdd04e427f42aa29d5c1667a252a357658707df32ed4bb57
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for python-dta 0.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.