MBBank API for Python
An unofficial, lightweight Python API wrapper for the "Military Commercial Joint Stock Bank" (MBBank) personal accounts.
Features
- Login: Authenticate with your MBBank credentials.
- Balance: Check account balances.
- Transaction History: Retrieve transaction history for your accounts.
- Transfer: Perform money transfers to another account*.
- Async Support: Includes asynchronous capabilities for better performance.
Installation
From PyPI
pip install mbbank-lib
From Source (Development Version)
pip install git+https://github.com/thedtvn/MBBank
Requirements
- Python 3.x
- onnxruntime-gpu (Optional, for CUDA GPU support)
Quick Start
Here is a simple example of how to log in and fetch your account balance:
import mbbank
def main():
username = "YOUR_USERNAME"
password = "YOUR_PASSWORD"
try:
mb = mbbank.MBBank(username=username, password=password)
# Get balance information
balance_info = mb.getBalance()
if balance_info.acct_list:
print(f"Login successful! Found {len(balance_info.acct_list)} account(s).")
for acct in balance_info.acct_list:
print(f"Account: {acct.acctNo} - Balance: {acct.currentBalance} {acct.currency}")
else:
print("Login successful, but no accounts found.")
except Exception as e:
print(f"An error occurred: {e}")
if __name__ == "__main__":
main()
For more examples, check the examples directory or docs
Documentation
For detailed documentation and FAQ, visit: http://mbbank.rtfd.io/
Related Projects
License
This project is licensed under the MIT License. See the LICENSE file for details.
Disclaimer
This project is not affiliated with MBBank. Use it responsibly and at your own risk.
The author is not liable for any damage or loss resulting from the use of this library.
Always ensure you comply with MBBank's terms of service and security guidelines when using this API.
Legal
Any takedown requests or legal problems from MBBank can contact the author at:
- Email: mbbanklib-legal@thedt.id.vn
Metadata
Release files for mbbank-lib 0.3.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 | |
|---|---|---|---|
| mbbank_lib-0.3.2.tar.gz | 36.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| mbbank_lib-0.3.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 84.5 kB
Release files / mbbank_lib-0.3.2.tar.gz
| Download URL | mbbank_lib-0.3.2.tar.gz |
|---|---|
| Size | 36.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fccef876621167a1614e054911090984aeecbd161385c797371546693a8501af
|
|
BLAKE2b-256 checksum How to use checksums |
b337e8ddaca9ce88f1d88d171fa56bce84f4253d2a271e6ccc8f2a63dd037143
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / mbbank_lib-0.3.2-py3-none-any.whl
| Download URL | mbbank_lib-0.3.2-py3-none-any.whl |
|---|---|
| Size | 47.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5aca9f96a0c8dad2264d8f2a4d22c8617263df9a46d5f94d2e9f0a8397ac72e8
|
|
BLAKE2b-256 checksum How to use checksums |
f3a5157370770b816850323c39d1eaa80ecb7ba665b227a4921c5da6bbef37df
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|