Skip to main content

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


Download files

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

Source Distribution

test_ttk_epay-0.1.6.tar.gz (7.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

test_ttk_epay-0.1.6-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

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

Hashes for test_ttk_epay-0.1.6.tar.gz
Algorithm Hash digest
SHA256 ba79e93c8d1e42678bad2b63212bb2b6d6e2538290b0c292d0bf721b9448c427
MD5 bcfe029d259e33a3364aee11eaac9f3e
BLAKE2b-256 849ad965e92d782f5ebc45be9fe4ae23e17a274bde594d281fc65c33f7392dcb

See more details on using hashes here.

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

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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

Hashes for test_ttk_epay-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 0f24e010f7e50fd1ad07b142ba56674afb48c1dd4b825201d4e7c7bac8532e99
MD5 9ae95bce300a72f5b50544ea36d94cf0
BLAKE2b-256 01cff869c71fa7b72f9e3001005d2894a1669fd6861f94f0836b35fea18f9ccb

See more details on using hashes here.

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

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page