No project description provided
Project description
ttk-epay-python-client
Welcome to Python Package Repository
for TTK ePay Payment Gateway
This package is developed by Charen Bahaeddine Hemmem (1hemmem) and is open to contributions from developers like you.
Requirements
TTK ePay requires Python 3.8 and above.
Installation
pip install ttk-epay
Usage
from ttk_epay import TtkEpay
from ttk_epay.models import Invoice, InvoiceDto
# Initialize the client
client = TtkEpay(base_url="https://pay.deploily.cloud/api/v1")
# ==============
# Invoice Management
# ==============
# Create an invoice
invoice_data = Invoice(
ID=123,
INVOICE_NUMBER=456,
NET_AMOUNT=100.0,
CLIENT_NAME="Client name",
CLIENT_MAIL="client@example.com"
)
created_invoice = client.create_invoice(invoice_data)
# Get paginated invoices
invoices = client.get_invoices(page_number=1, page_size=10)
# Get invoice by order ID
invoice = client.get_invoice_by_order_id("41")
# ==============
# Receipt Management
# ==============
# Get PDF receipt
pdf_response = client.get_pdf_recipt("8LmjDNjisi0A5EAAGBYM")
with open("receipt.pdf", "wb") as f:
f.write(pdf_response.content)
# Send receipt via email
result = client.send_pdf_recipt_mail("8LmjDNjisi0A5EAAGBYM", "client@example.com")
# ==============
# Payment Processing
# ==============
# Create a payment
payment_data = InvoiceDto(
INVOICE_NUMBER=456,
NET_AMOUNT=100.0,
CLIENT_NAME="John Doe"
)
payment = client.post_payement(payment_data)
# Check payment status
status = client.get_payment_status("8LmjDNjisi0A5EAAGBYM")
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file test_ttk_epay-0.1.6.tar.gz.
File metadata
- Download URL: test_ttk_epay-0.1.6.tar.gz
- Upload date:
- Size: 7.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ba79e93c8d1e42678bad2b63212bb2b6d6e2538290b0c292d0bf721b9448c427
|
|
| MD5 |
bcfe029d259e33a3364aee11eaac9f3e
|
|
| BLAKE2b-256 |
849ad965e92d782f5ebc45be9fe4ae23e17a274bde594d281fc65c33f7392dcb
|
Provenance
The following attestation bundles were made for test_ttk_epay-0.1.6.tar.gz:
Publisher:
publish.yml on deploily/ttk-epay-python-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
test_ttk_epay-0.1.6.tar.gz -
Subject digest:
ba79e93c8d1e42678bad2b63212bb2b6d6e2538290b0c292d0bf721b9448c427 - Sigstore transparency entry: 243145975
- Sigstore integration time:
-
Permalink:
deploily/ttk-epay-python-client@5a87845ef5d66acbf02d57cbaa68f456030708b4 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/deploily
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@5a87845ef5d66acbf02d57cbaa68f456030708b4 -
Trigger Event:
push
-
Statement type:
File details
Details for the file test_ttk_epay-0.1.6-py3-none-any.whl.
File metadata
- Download URL: test_ttk_epay-0.1.6-py3-none-any.whl
- Upload date:
- Size: 9.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0f24e010f7e50fd1ad07b142ba56674afb48c1dd4b825201d4e7c7bac8532e99
|
|
| MD5 |
9ae95bce300a72f5b50544ea36d94cf0
|
|
| BLAKE2b-256 |
01cff869c71fa7b72f9e3001005d2894a1669fd6861f94f0836b35fea18f9ccb
|
Provenance
The following attestation bundles were made for test_ttk_epay-0.1.6-py3-none-any.whl:
Publisher:
publish.yml on deploily/ttk-epay-python-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
test_ttk_epay-0.1.6-py3-none-any.whl -
Subject digest:
0f24e010f7e50fd1ad07b142ba56674afb48c1dd4b825201d4e7c7bac8532e99 - Sigstore transparency entry: 243145979
- Sigstore integration time:
-
Permalink:
deploily/ttk-epay-python-client@5a87845ef5d66acbf02d57cbaa68f456030708b4 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/deploily
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@5a87845ef5d66acbf02d57cbaa68f456030708b4 -
Trigger Event:
push
-
Statement type: