Skip to main content

Accept Binance QR code, Bitcoin, USDT, USDC Pay directly into your wallet โ€” no merchant account, no KYC, 10-minute Python integration

Project description

๐Ÿช™ Binance & Crypto Payment Gateway for Python

Accept Bitcoin, USDT, USDC, ETH, and BNB payments directly into your wallet โ€” no middleman, no merchant account, no KYC required.

Powered by PayerURL โ€” the direct-to-wallet crypto payment processor for Python developers.

PyPI Version PyPI Downloads Python Versions License GitHub Stars

๐Ÿ”ด LIVE DEMO | ๐Ÿ”‘ Get API Key | ๐Ÿ’ฌ Telegram Support


โœ… Why Developers Choose This Package

Feature Detail
๐Ÿฆ No merchant account needed Payments go directly to your crypto wallet
๐ŸŒ 169+ fiat currencies USD, EUR, GBP, CAD and more โ€” converted at live rates
โšก 10-minute integration Simple API, clear docs, copy-paste code
๐Ÿ”’ No KYC for withdrawals Basic accounts withdraw without identity verification
๐Ÿ“ฑ Binance QR Code payments Customers scan and pay without leaving your app
๐Ÿ’ธ Zero hidden fees No network surcharges or platform fees
๐Ÿ› ๏ธ Django, Flask & FastAPI ready Works with any Python web framework

๐Ÿ“ฆ Installation

pip install binance-and-crypto-payment

๐Ÿ”‘ Get Your API Key (Free)

  1. Sign up at dash.payerurl.com
  2. Go to Dashboard โ†’ Get API Credentials
  3. Copy your Public Key and Secret Key

๐Ÿ‘‰ Registration is free and takes under 2 minutes. No credit card required.


๐Ÿš€ Quick Start

from binance_and_crypto_payment import CryptoPaymentClient
import time

client = CryptoPaymentClient(
    public_key="YOUR_PUBLIC_KEY",   # from dash.payerurl.com
    secret_key="YOUR_SECRET_KEY"    # from dash.payerurl.com
)

response = client.payment(
    invoice_id=f"PYP-{int(time.time())}",
    amount=10.00,
    currency="USD",
    items=[{"name": "Product", "qty": "1", "price": "10.00"}],
    data={
        "first_name": "John",
        "last_name": "Doe",
        "email": "john@example.com",
        "redirect_url": "https://yoursite.com/payment/success",  # redirect after payment
        "notify_url":   "https://yoursite.com/payment/notify",   # webhook: receives payment result
        "cancel_url":   "https://yoursite.com/payment/cancel",   # redirect if customer cancels
    }
)

print(response)
# {'status': True, 'redirect_to': 'https://api-v2.payerurl.com/web-payment-option/PYP...'}

# Redirect the customer to the payment page
payment_url = response["redirect_to"]

Replace yoursite.com with your actual domain. All three URLs must be publicly accessible endpoints on your server.


๐ŸŒ Supported Cryptocurrencies & Networks

Currency Networks
USDT TRC20 (Tron), ERC20 (Ethereum), BEP20 (BSC)
USDC ERC20 (Ethereum), BEP20 (BSC)
Bitcoin (BTC) Bitcoin Network
Ethereum (ETH) ERC20
BNB BEP20 (BSC)
Binance Pay Binance QR Code

๐Ÿ”— Django Integration

# views.py
from django.shortcuts import redirect
from django.views import View
from binance_and_crypto_payment import CryptoPaymentClient
import time

class CheckoutView(View):
    def post(self, request):
        client = CryptoPaymentClient(
            public_key="YOUR_PUBLIC_KEY",
            secret_key="YOUR_SECRET_KEY"
        )

        response = client.payment(
            invoice_id=f"PYP-{int(time.time())}",
            amount=float(request.POST.get("amount", 10.00)),
            currency="USD",
            items=[{
                "name":  request.POST.get("product", "Order"),
                "qty":   "1",
                "price": request.POST.get("amount", "10.00"),
            }],
            data={
                "first_name": request.user.first_name,
                "last_name":  request.user.last_name,
                "email":      request.user.email,
                "redirect_url": request.build_absolute_uri("/payment/success/"),
                "notify_url":   request.build_absolute_uri("/payment/notify/"),
                "cancel_url":   request.build_absolute_uri("/payment/cancel/"),
            }
        )

        return redirect(response["redirect_to"])
# urls.py
from django.urls import path
from .views import CheckoutView

urlpatterns = [
    path("checkout/", CheckoutView.as_view(), name="checkout"),
]

๐Ÿ”— Flask Integration

# app.py
from flask import Flask, request, redirect
from binance_and_crypto_payment import CryptoPaymentClient
import time

app = Flask(__name__)

client = CryptoPaymentClient(
    public_key="YOUR_PUBLIC_KEY",
    secret_key="YOUR_SECRET_KEY"
)

@app.route("/pay", methods=["POST"])
def pay():
    response = client.payment(
        invoice_id=f"PYP-{int(time.time())}",
        amount=float(request.form["amount"]),
        currency="USD",
        items=[{
            "name":  request.form.get("product", "Order"),
            "qty":   "1",
            "price": request.form["amount"],
        }],
        data={
            "first_name": request.form["first_name"],
            "last_name":  request.form["last_name"],
            "email":      request.form["email"],
            "redirect_url": "https://yoursite.com/payment/success",
            "notify_url":   "https://yoursite.com/payment/notify",
            "cancel_url":   "https://yoursite.com/payment/cancel",
        }
    )
    return redirect(response["redirect_to"])

๐Ÿ”— FastAPI Integration

# main.py
from fastapi import FastAPI, Form
from fastapi.responses import RedirectResponse
from binance_and_crypto_payment import CryptoPaymentClient
import time

app = FastAPI()

client = CryptoPaymentClient(
    public_key="YOUR_PUBLIC_KEY",
    secret_key="YOUR_SECRET_KEY"
)

@app.post("/pay")
async def pay(
    amount: float = Form(...),
    first_name: str = Form(...),
    last_name: str = Form(...),
    email: str = Form(...),
):
    response = client.payment(
        invoice_id=f"PYP-{int(time.time())}",
        amount=amount,
        currency="USD",
        items=[{"name": "Order", "qty": "1", "price": str(amount)}],
        data={
            "first_name": first_name,
            "last_name":  last_name,
            "email":      email,
            "redirect_url": "https://yoursite.com/payment/success",
            "notify_url":   "https://yoursite.com/payment/notify",
            "cancel_url":   "https://yoursite.com/payment/cancel",
        }
    )
    return RedirectResponse(url=response["redirect_to"])

๐Ÿ”” Handling Webhooks (notify_url)

When a payment is completed, PayerURL sends a POST request to your notify_url. Here is how to handle it:

# Django webhook handler โ€” views.py
import json
import hmac
import hashlib
from django.http import JsonResponse
from django.views.decorators.csrf import csrf_exempt

@csrf_exempt
def payment_notify(request):
    if request.method != "POST":
        return JsonResponse({"error": "Method not allowed"}, status=405)

    data = request.POST  # or json.loads(request.body) if JSON

    order_id    = data.get("order_id")
    status_code = data.get("status_code")
    txn_id      = data.get("transaction_id")

    if str(status_code) == "200":
        # Payment confirmed โ€” update your order status here
        # Order.objects.filter(id=order_id).update(status="paid")
        return JsonResponse({"status": 2040, "message": "Order updated"})

    return JsonResponse({"status": 2050, "message": "Pending"})
# Flask webhook handler
from flask import Flask, request, jsonify

@app.route("/payment/notify", methods=["POST"])
def payment_notify():
    data        = request.form
    order_id    = data.get("order_id")
    status_code = data.get("status_code")
    txn_id      = data.get("transaction_id")

    if str(status_code) == "200":
        # Payment confirmed โ€” update your database here
        return jsonify({"status": 2040, "message": "Order updated"})

    return jsonify({"status": 2050, "message": "Pending"})

Webhook Payload Fields

Field Description
order_id Your original invoice ID
transaction_id Blockchain transaction hash
status_code 200 = completed, 20000 = cancelled
confirm_rcv_amnt Amount received in fiat
confirm_rcv_amnt_curr Fiat currency (e.g. USD)
coin_rcv_amnt Amount received in crypto
coin_rcv_amnt_curr Crypto symbol (e.g. USDT)
txn_time Transaction timestamp

๐Ÿ“ฒ How the Binance QR Payment Works

  1. Your app calls the API and gets a payment URL
  2. Customer is redirected to a secure checkout page
  3. Customer scans the QR code with their Binance app
  4. Payment is confirmed and funds land directly in your wallet
  5. Your notify_url receives a webhook with the order status

No bank accounts. No intermediaries. No waiting.


๐Ÿ›ก๏ธ Security & Privacy

  • โœ… Payments go directly to your wallet โ€” PayerURL never holds your funds
  • โœ… No mandatory KYC for basic accounts
  • โœ… HMAC-SHA256 signature verification on all API calls
  • โœ… MIT licensed โ€” fully open source, audit it yourself
  • โœ… No personal identity verification required to get started

๐ŸŒ Supported Fiat Currencies (169+)

USD, EUR, GBP, CAD, AUD, JPY, SGD, AED, INR, BRL, MXN, NGN, PKR, BDT, and 150+ more.

All fiat amounts are automatically converted to the equivalent crypto amount at live market rates.


๐Ÿ“Š Full Payment Flow

Your App  โ”€โ”€โ–บ  PayerURL API  โ”€โ”€โ–บ  Checkout Page  โ”€โ”€โ–บ  Customer Pays
                                                              โ”‚
Your Wallet  โ—„โ”€โ”€  Funds (instant)  โ—„โ”€โ”€  Blockchain Confirmed โ”˜
                                                              โ”‚
              Your notify_url  โ—„โ”€โ”€  Webhook (status update) โ”€โ”˜

๐Ÿ†š Compared to Other Solutions

PayerURL (This Package) Stripe / PayPal Coinbase Commerce
No merchant account โœ… โŒ โœ…
Direct to your wallet โœ… โŒ Partial
No KYC required โœ… (Basic) โŒ โŒ
Binance QR support โœ… โŒ โŒ
Python SDK โœ… โœ… โœ…
Django / Flask / FastAPI โœ… โœ… โŒ
169+ fiat currencies โœ… Partial โŒ
Zero platform fees โœ… โŒ โŒ
Webhook support โœ… โœ… โœ…

โ“ FAQ

Do I need a Binance account? Yes, to accept Binance QR payments. For USDT/BTC/ETH/USDC, you only need the corresponding wallet address configured in your PayerURL dashboard.

Is there a transaction fee? No platform fees from PayerURL. Standard blockchain network fees may apply depending on the coin and network.

Can I use this without KYC? Yes. Basic accounts can receive and withdraw crypto without mandatory identity verification.

What should my notify_url return? Return a JSON response with {"status": 2040, "message": "Order updated"} on success. PayerURL expects a 200 HTTP status code.

Does this work with Django REST Framework / FastAPI? Yes โ€” it is a pure Python client that works with any Python web framework.

What Python versions are supported? Python 3.8 and above (3.8, 3.9, 3.10, 3.11, 3.12, 3.13).


๐Ÿ“ฌ Support

Channel Link
๐Ÿ’ฌ Telegram t.me/Payerurl
๐ŸŒ Website payerurl.com
๐Ÿ“Š Dashboard dash.payerurl.com
๐Ÿ”ด Live Demo python.payerurl.com

๐Ÿ“„ License

MIT License โ€” free for personal and commercial use.


๐Ÿ”‘ Keywords

crypto bitcoin ethereum binance coinbase usdt usdc bnb tron payment payment-gateway crypto-payment-gateway cryptocurrency-payment bitcoin-payment binance-pay binance-api accept-crypto crypto-checkout django-payment flask-payment fastapi-payment usdt-trc20 usdt-erc20 no-kyc-payment instant-settlement crypto-webhook direct-to-wallet credit-card-to-crypto

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

binance_and_crypto_payment-0.1.23.tar.gz (12.9 kB view details)

Uploaded Source

Built Distribution

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

binance_and_crypto_payment-0.1.23-py3-none-any.whl (10.3 kB view details)

Uploaded Python 3

File details

Details for the file binance_and_crypto_payment-0.1.23.tar.gz.

File metadata

File hashes

Hashes for binance_and_crypto_payment-0.1.23.tar.gz
Algorithm Hash digest
SHA256 7cf8430244e1909c37a52866405fc7d1b1abc499f037edc550eafabc2b5c422b
MD5 d6d2a66b1b5c46f385484225cc4f1ac7
BLAKE2b-256 907e11f57fbf4a157730f815732b3fc85bc76240f27e305e56c74555bf1acc3a

See more details on using hashes here.

File details

Details for the file binance_and_crypto_payment-0.1.23-py3-none-any.whl.

File metadata

File hashes

Hashes for binance_and_crypto_payment-0.1.23-py3-none-any.whl
Algorithm Hash digest
SHA256 fcc6c5f13b6e45547fb12692625613e468b29d6fc3ab6266ae43400a2f34a6e3
MD5 1ec2e7566864935a38c5c42ee41fb0f0
BLAKE2b-256 34134c557e4efc31f9e3b19218473908715e74682a50fc881580c1157f360356

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