Parse MT103 messages from the Swift payments network
Project description
Parse MT103 messages from the Swift payments network
What’s an MT103?
Banks don’t really deal with cash much any more. Instead, they push bits around the internet tracking where your money goes digitally. The network that handles much of that movement is called Swift, and the transfers are documented in a special format native to that network called MT103.
What’s this Do?
Unfortunately, MT103 isn’t a common standard for most software developers. It’s ugly & hard to read for humans and not at all easy to parse. This library attempts to fix that, so all you have to do is pass an MT103 string into it and you get back a native Python object with the properties you’re looking for.
from mt103 import MT103
mt103 = MT103("some-mt-103-string")
print("basic header: {}, bank op code: {}, complete message: {}".format(
mt103.basic_header,
mt103.text.bank_operation_code
mt103
))
Installation
It’s on PyPi, so just install it with pip.
$ pip install mt103
Changelog
1.0.0
Changed the nature of the .user_header attribute from a string to a UserHeader object. This new object has the same string representation (str(mt103.user_header)), but now also possesses new sub-attributes.
Added support for user header fields including bank_priority_code (bpc), message_user_reference (mur), service_type_identifier (sti), and unique_end_to_end_transaction_reference (uetr).
0.0.1
Initial release.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file mt103-1.0.0.tar.gz
.
File metadata
- Download URL: mt103-1.0.0.tar.gz
- Upload date:
- Size: 4.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.7.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15e1c3c3fab2bb3cf2c075eccbfb69d830b516e0056852567b82bfb32cc6ea08 |
|
MD5 | eed336fd6f791ee610754678a1bc7037 |
|
BLAKE2b-256 | b838261bf73b2b3def5496184a9348534b64629967e825d6fbc6dc7cfbffb0e5 |
File details
Details for the file mt103-1.0.0-py2.py3-none-any.whl
.
File metadata
- Download URL: mt103-1.0.0-py2.py3-none-any.whl
- Upload date:
- Size: 16.2 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.7.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 69f78933c25c18d8ad8e9148b0a1b910ca9c12ab6922e49411279d5ff56ad827 |
|
MD5 | 0bc7c9163579fcfcad074cb819e6c75e |
|
BLAKE2b-256 | 08bcf204a88d9505248d9876e79ddfeb05fc999ed3f6e1621ccb9e4bdad8221e |