Skip to main content

Merchant payment library for wallet API

Project description

Merchant Payment Lib

Python library for merchant payments via wallet API.

Installation

pip install tango-merpay-lib
from merchant_payment import MerchantPaymentService

service = MerchantPaymentService(
    url="https://api.example.com",
    addon_id="your_addon_id",
    country_id="CD",
    api_key="your_api_key"
)

data = {
    "currency": "CDF",
    "merchant_msisdn": "243999999999",
    "msisdn": "243999999999",
    "amount": "1000",
    "pin": "1234"
}

merchant_payment_response = service.do_payment(data)

merchant_payment_status = merchant_payment_response["mapping_response"]["mapping_code"]
merchant_payment_reference = merchant_payment_response["wallet_response"]["txnid"]
merchant_payment_message = merchant_payment_response["wallet_response"]["message"]

if merchant_payment_status != "SUCCESS":
    pass

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

tango_merpay_lib-1.0.0.tar.gz (2.3 kB view details)

Uploaded Source

Built Distribution

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

tango_merpay_lib-1.0.0-py3-none-any.whl (2.9 kB view details)

Uploaded Python 3

File details

Details for the file tango_merpay_lib-1.0.0.tar.gz.

File metadata

  • Download URL: tango_merpay_lib-1.0.0.tar.gz
  • Upload date:
  • Size: 2.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.6

File hashes

Hashes for tango_merpay_lib-1.0.0.tar.gz
Algorithm Hash digest
SHA256 724e8060fe270faf765d7d76f61253871c75df8d1ab000df0f8dde8e2b9cc526
MD5 d5521c30b173268cdf7ae6f794d6ec2c
BLAKE2b-256 4d98ba88952ef9d6f1aa8c712a41cf9a388d4ef8106251e778dc09839a6ca337

See more details on using hashes here.

File details

Details for the file tango_merpay_lib-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for tango_merpay_lib-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 41e2f6293b0d5853398a58ecbba34c06c69665af90a8b263139df48feb5fd0de
MD5 da6ac269913e069dfb1c369eb1963686
BLAKE2b-256 67e0ba79834de0a250e2ed985cda03bfacc38fbe8cf8ae32866888a10ce13462

See more details on using hashes here.

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