Skip to main content

A brief description of your package

Project description

Using the Demo

以下是一个使用 hupipay_sdk 的示例代码,展示了如何使用虎皮椒支付SDK进行支付操作:

import json
import time

from hupipay_sdk import hupi_pay

def test_hupi_pay_sdk(fee):
    """
    使用虎皮椒支付SDK进行支付测试。
    
    :param fee: 支付金额(单位:元)
    """
    # 初始化Hupi实例并发起支付请求
    r = hupi_pay.Hupi(
        appid='201906124557',
        appsecret='35e717b331196138a1340e6c4da0b508',
        notify_url='https://demo.cc/paynotify',
        return_url='https://demo.cc/payreturn',
        callback='https://demo.cc',
        headers='https://demo.cc',
        payment_api='https://go.vrmrgame.com/payment/do.html'
    ).Pay(total_fee=fee)

    # 将支付结果转换为格式化的JSON字符串,中文字符不转义
    r = json.dumps(r, indent=4, ensure_ascii=False)
    print(r)

if __name__ == '__main__':
    test_hupi_pay_sdk(fee=0.01)

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

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

Source Distribution

hupi_pay_sdk-0.1.tar.gz (15.5 kB view details)

Uploaded Source

Built Distribution

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

hupi_pay_sdk-0.1-py3-none-any.whl (15.6 kB view details)

Uploaded Python 3

File details

Details for the file hupi_pay_sdk-0.1.tar.gz.

File metadata

  • Download URL: hupi_pay_sdk-0.1.tar.gz
  • Upload date:
  • Size: 15.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.9.13

File hashes

Hashes for hupi_pay_sdk-0.1.tar.gz
Algorithm Hash digest
SHA256 9a76c6dd01cd42fd2889ec8114657bce076fcef6b799647a5503377bb8332fef
MD5 cdb2edce25bf53af72ea3ba1fdf3e5c7
BLAKE2b-256 57f1d249df53da74ee35245f20f9087f18a5e8e0e043d85c5af32e58696e95ff

See more details on using hashes here.

File details

Details for the file hupi_pay_sdk-0.1-py3-none-any.whl.

File metadata

  • Download URL: hupi_pay_sdk-0.1-py3-none-any.whl
  • Upload date:
  • Size: 15.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.9.13

File hashes

Hashes for hupi_pay_sdk-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 86797849a3d4b7c100544edea6427af9a4b4a179dee5236afc775b7ab21a070a
MD5 84e189199c585c683ebec974b166ebdd
BLAKE2b-256 2e216c8cf338c19f56fbbe021bd8c8c65c366a0dcf716460744f9e15cb68bd9f

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