How to Set Up Epusdt with DuJiaoKa for USDT Payments Using aaPanel

·

Setting up a private, secure, and cost-effective USDT payment gateway is essential for online businesses accepting cryptocurrency. This guide walks you through integrating Epusdt with DuJiaoKa (Dujiaoka) using aaPanel, enabling seamless TRC20-based USDT transactions without third-party fees or compliance hurdles.

Epusdt (Easy Payment USDT) is an open-source, self-hosted payment middleware built in Go, supporting high-performance, asynchronous USDT transaction processing via HTTP API. When combined with DuJiaoKa — a popular digital goods payment system — it creates a powerful, private payment stack fully under your control.


Why Use Epusdt for USDT Payments?

Epusdt offers several advantages for developers and site operators:

Core keywords: Epusdt, USDT payment, DuJiaoKa, aaPanel, TRC20, self-hosted payment, crypto payment integration, Telegram bot payment


Prerequisites

Before starting, ensure your server environment includes:

👉 Learn how to securely manage crypto payments with automated tools.


Step 1: Create a New Site in aaPanel

Log into your aaPanel dashboard and:

  1. Go to Websites > Add Site
  2. Enter your payment domain (e.g., upay.yoursite.com)
  3. Disable PHP and FTP — this site will serve static content only
  4. Enable MySQL — create a new database for Epusdt
  5. Check "Auto SSL" to enable HTTPS automatically
🔒 Always use HTTPS for payment interfaces to protect transaction data.

Step 2: Import the Epusdt Database

Epusdt requires a MySQL schema to store transactions, settings, and logs.

Option A: Manual SQL Import

  1. Download the latest SQL file from the official repository:
    https://github.com/assimon/epusdt/blob/master/sql/
  2. In aaPanel, go to Databases > phpMyAdmin
  3. Select the database created earlier
  4. Click Import, upload the .sql file, and execute

Option B: Command Line (Advanced)

mysql -u your_user -p your_database < v0.0.1.sql

Ensure you're using the correct database credentials.


Step 3: Deploy and Configure Epusdt

1. Upload Epusdt Binary

Download the appropriate release for your system (Linux x86/ARM):

wget https://github.com/assimon/epusdt/releases/download/v0.0.3/epusdt_0.0.3_Linux_x86_64.tar.gz
tar -xzf epusdt_0.0.3_Linux_x86_64.tar.gz

Upload the extracted files to your website root (e.g., /www/wwwroot/upay.yoursite.com).

2. Configure Environment File

Rename .env.example to .env:

mv .env.example .env

Edit .env with your settings:

app_name=epusdt
app_uri=https://upay.yoursite.com
app_debug=false
http_listen=:8000
static_path=/static
runtime_root_path=/runtime
log_save_path=/logs

# MySQL Settings
mysql_host=127.0.0.1
mysql_port=3306
mysql_user=your_db_user
mysql_passwd=your_db_password
mysql_database=your_db_name

# Redis Settings
redis_host=127.0.0.1
redis_port=6379
redis_db=5

# Telegram Bot
tg_bot_token=your_telegram_bot_token
tg_manage=your_telegram_user_id
tg_proxy=  # Leave empty if server is outside China

# Security & Payments
api_auth_token=your_secure_api_token  # Used in DuJiaoKa integration
order_expiration_time=20
forced_usdt_rate=  # Optional: fix exchange rate

⚠️ Do not modify unfamiliar fields unless you understand their function.


Step 4: Set Up Reverse Proxy in aaPanel

Since Epusdt runs on port 8000, we’ll use Nginx to proxy requests from HTTPS (port 443) to the local service.

In aaPanel:

  1. Go to Websites > Manage > Reverse Proxy
  2. Add new proxy:

    • Proxy Name: epusdt
    • Target URL: http://127.0.0.1:8000
  3. Save and clear cache if needed

Now your payment interface is accessible via https://upay.yoursite.com.


Step 5: Grant Execution Permissions

On Linux, binaries require execute permissions:

cd /www/wwwroot/upay.yoursite.com
chmod +x epusdt

This allows the system to run the Epusdt binary.


Step 6: Configure Supervisor for Auto-Restart

To keep Epusdt running continuously:

  1. Open Supervisor Manager in aaPanel
  2. Add a new process:

    • Name: epusdt
    • Command: /www/wwwroot/upay.yoursite.com/epusdt http start
    • Autostart: ✔️ Enabled
    • Autorestart: ✔️ Enabled
  3. Save and start the process

Supervisor will now monitor and restart Epusdt if it crashes.


Step 7: Test the Installation

Open Telegram and message your bot. If properly configured, the bot should respond with status updates or commands.

Check logs at /logs/ for errors during startup.

👉 Discover how top platforms handle secure crypto transactions at scale.


Step 8: Enable SSL (If Not Already Done)

Although aaPanel auto-generates SSL certificates via Let's Encrypt, ensure:

if ($server_port = 80) {
    return 301 https://$server_name$request_uri;
}

This ensures all traffic is encrypted.


Frequently Asked Questions (FAQ)

Q1: Can I use Epusdt without DuJiaoKa?

Yes. Epusdt provides a standalone HTTP API (/api/v1/order/create-transaction) that can be integrated into any custom system or e-commerce platform.

Q2: What if my Telegram bot doesn’t respond?

Verify:

Q3: How do I update Epusdt to a newer version?

  1. Stop the Supervisor process
  2. Backup your .env and database
  3. Replace the binary with the new version
  4. Restart Supervisor

Always check release notes before upgrading.

Q4: Is TRC20 the only supported network?

Currently, yes. Epusdt is designed specifically for TRC20-USDT due to its low transaction fees and fast confirmation times.

Q5: Can I run Epusdt on Windows?

Yes, but it’s not recommended for production. Use the .exe file directly; no chmod needed.

Q6: Why does DuJiaoKa use 127.0.0.1 instead of the domain?

When both systems are on the same server, using http://127.0.0.1:8000 avoids DNS resolution delays and external exposure risks.


Integrate with DuJiaoKa

In your DuJiaoKa admin panel:

  1. Go to Payment Settings > Add Payment Method
  2. Select Epusdt
  3. Fill in:

    • Merchant ID: Your api_auth_token
    • Key: Leave empty
    • API URL: http://127.0.0.1:8000/api/v1/order/create-transaction

Save and test a transaction.


Customize the Payment Page Title

Edit the frontend title shown during checkout:

nano /www/wwwroot/upay.yoursite.com/static/index.html

Find and modify the <title> tag:

<title>My Store - Pay with USDT</title>

Refresh the page to see changes.


Final Notes & Best Practices

👉 Explore advanced tools for managing crypto revenue streams efficiently.


By following this guide, you've successfully deployed a private, scalable USDT payment solution using Epusdt, aaPanel, and DuJiaoKa — all under your full control, with no middlemen or fees.

This setup is ideal for digital stores, subscription services, or any platform accepting cryptocurrency payments securely and independently.