x402 Protocol

Complete guide to making payments on 0fees using the revolutionary x402 gasless protocol.

Understanding x402 Protocol

What is x402?

The x402 protocol is 0fees' proprietary gasless payment system that enables:

  • Zero Gas Fees: No ETH or BNB required for transactions

  • 🚀 Instant Processing: Near-instantaneous payment confirmation

  • 🔒 Secure Transactions: Cryptographically secured payment verification

  • 💰 USDC Payments: Simple, stable payments using USDC tokens

How x402 Works

User Wallet → USDC Transfer → x402 Protocol → Instant Verification → Access Granted

1

Payment Initiation

User selects subscription plan.

2

Smart Contract Interaction

x402 protocol handles the transaction.

3

USDC Transfer

Payment processed via USDC on BSC.

4

Verification

Backend API confirms payment.

5

Access Activation

Subscription activated immediately.

Benefits of x402

  • No Gas Calculations: Never worry about gas prices again

  • Predictable Costs: Fixed USDC pricing

  • Universal Access: Works with any Web3 wallet

  • Instant Confirmation: No waiting for block confirmations

Payment Requirements

Essential Requirements

💳 USDC Balance

  • Sufficient USDC tokens in your wallet

  • Must be on Binance Smart Chain (BSC)

  • Check balance before initiating payment

🌐 Network Setup

  • Network: Binance Smart Chain

  • Chain ID: 56

  • RPC URL: https://bsc-dataseed.binance.org/

  • Currency: BNB (for network, but not needed for payments)

🔗 Wallet Connection

  • MetaMask or compatible Web3 wallet

  • Wallet connected to BSC network

  • Sufficient permissions granted to the application

USDC Contract Details

Contract Address: 0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d
Token Symbol: USDC
Decimals: 18
Network: Binance Smart Chain (BSC)

Step-by-Step Payment Process

1

Pre-Payment Setup

Verify Network Connection

✅ Check: Wallet connected to BSC
✅ Check: USDC balance sufficient
✅ Check: Network stability

Access Subscription Modal

  • Navigate to the subscription section

  • Click "Subscribe" or "Upgrade Plan"

  • Review available plans and pricing

2

Payment Execution

Select Your Plan Available Plans:

  • Basic Plan (30 days)

    • Price: [Current USDC Rate]

    • Features: Full trading access

    • Support: Standard

  • Pro Plan (if available)

    • Price: [Premium USDC Rate]

    • Features: Enhanced trading

    • Support: Priority

Initiate Payment

  • Click "Pay with USDC" button

  • Payment modal opens automatically

  • Review payment details carefully

Network Verification

  • System automatically detects your current network

  • Switches to BSC if needed

  • Prompts for network approval

Transaction Approval (MetaMask Popup Sequence)

  1. Network Switch Request (if needed) — Click "Switch Network"

  2. Transaction Approval

    • Review: Recipient address

    • Review: USDC amount

    • Review: Gas fee (minimal)

    • Click "Confirm"

Payment Processing

  • Transaction submitted to blockchain

  • x402 protocol processes payment

  • Real-time status updates displayed

3

Confirmation

Transaction Verification

  • Blockchain Confirmation

  • x402 Protocol Validation

  • Backend API Verification

  • Subscription Activation

Success Confirmation

  • ✅ Payment success message displayed

  • 🎉 Subscription immediately activated

  • 📧 Confirmation details saved locally

Supported Payment Methods

Primary Method: Direct USDC Transfer

MetaMask Integration

  • Automatic Detection: Platform detects MetaMask

  • Network Management: Auto-switches to BSC

  • Transaction Handling: Streamlined approval process

  • Error Recovery: Built-in retry mechanisms

Transaction Details

Transaction Structure (example)
{
  to: "0x742d35Cc6634C0532925a3b8D4C9db96C4b5Da5A", // Payment wallet
  value: "0", // No ETH/BNB required
  data: USDC_TRANSFER_DATA,
  gasLimit: "auto", // Handled by x402
  gasPrice: "auto"  // Optimized automatically
}

Alternative Methods (Future)

WalletConnect Support

  • Mobile wallet compatibility

  • QR code scanning

  • Cross-platform support

Hardware Wallet Integration

  • Ledger support planned

  • Trezor compatibility

  • Enhanced security options

Network Configuration

Binance Smart Chain Setup

If BSC is not configured in your wallet:

Automatic Configuration

The platform will prompt to add BSC with these parameters:

{
  "chainId": "0x38",
  "chainName": "Binance Smart Chain",
  "nativeCurrency": {
    "name": "BNB",
    "symbol": "BNB",
    "decimals": 18
  },
  "rpcUrls": ["https://bsc-dataseed.binance.org/"],
  "blockExplorerUrls": ["https://bscscan.com/"]
}

Manual Configuration

If automatic setup fails:

  1. Open MetaMask settings

  2. Navigate to "Networks"

  3. Click "Add Network"

  4. Enter the parameters above

  5. Save and switch to BSC

USDC Token Addition

Add USDC to your wallet for balance visibility:

Token Contract: 0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d
Token Symbol: USDC
Token Decimals: 18

Transaction Verification

Real-Time Status Tracking

Payment States

Payment Flow:
├── 🔄 Initiating...
├── 🌐 Network Check
├── 💰 Balance Verification
├── 📝 Transaction Pending
├── ⛓️ Blockchain Confirmation
├── 🔍 x402 Verification
└── ✅ Payment Complete

Status Indicators

  • Blue Spinner: Processing in progress

  • Yellow Warning: Action required (approve transaction)

  • Green Checkmark: Step completed successfully

  • Red X: Error occurred (see troubleshooting)

Blockchain Verification

Transaction Hash

  • Unique identifier for your payment

  • Used for blockchain verification

  • Stored locally for reference

  • Viewable on BSCScan

Confirmation Process

Confirmation Levels:
├── 0 Confirmations: Transaction submitted
├── 1 Confirmation: Included in block
├── 3 Confirmations: Standard safety
└── 6+ Confirmations: Maximum security

Backend Verification

API Validation

Verification Endpoint: https://api.0fees.trade/verify-payment
Process:
├── Transaction hash validation
├── Payment amount verification
├── Recipient address confirmation
├── Subscription plan activation
└── User access update

Troubleshooting Payments

Common Issues & Solutions

🚫 Insufficient USDC Balance

Problem: Not enough USDC tokens Solution:

  1. Check your USDC balance on BSC

  2. Purchase USDC from an exchange

  3. Transfer USDC to your BSC wallet

  4. Retry payment

🌐 Wrong Network

Problem: Wallet connected to wrong network Solution:

  1. Allow automatic network switch

  2. Or manually switch to BSC (Chain ID: 56)

  3. Refresh the page

  4. Retry payment

⛽ Transaction Failed

Problem: Blockchain transaction rejected Solution:

  1. Check network connectivity

  2. Increase gas price if needed

  3. Ensure sufficient BNB for gas (minimal amount)

  4. Retry transaction

🔄 Payment Stuck

Problem: Payment processing indefinitely Solution:

  1. Check transaction on BSCScan

  2. Wait for blockchain confirmation

  3. Contact support with transaction hash

  4. Do not retry until confirmed failed

💳 MetaMask Issues

Problem: MetaMask not responding Solution:

  1. Refresh browser page

  2. Restart MetaMask extension

  3. Clear browser cache

  4. Try incognito/private mode

Advanced Troubleshooting

Transaction Hash Lookup

BSCScan URL: https://bscscan.com/tx/[YOUR_TX_HASH] Check for:

  • Transaction Status (Success/Failed)

  • Block Confirmation

  • Gas Usage

  • Error Messages

RPC Issues

If BSC RPC is slow:

  • https://bsc-dataseed1.binance.org/

  • https://bsc-dataseed2.binance.org/

  • https://bsc-dataseed3.binance.org/

  • https://bsc-dataseed4.binance.org/

Browser Compatibility

Supported Browsers:

  • ✅ Chrome/Chromium 88+

  • ✅ Firefox 85+

  • ✅ Safari 14+

  • ✅ Edge 88+

  • ❌ Internet Explorer (not supported)

Security Best Practices

Before Payment

Verification Checklist

  • ✅ Verify you're on the official 0fees domain

  • ✅ Check SSL certificate (https://)

  • ✅ Confirm payment wallet address

  • ✅ Review transaction details carefully

  • ✅ Ensure sufficient but not excessive USDC balance

Wallet Security

  • 🔐 Never share private keys or seed phrases

  • 🛡️ Use hardware wallets for large amounts

  • 🔄 Keep wallet software updated

  • 📱 Enable 2FA where available

During Payment

Transaction Review

Always Verify:

  • Recipient Address: 0x742d35Cc6634C0532925a3b8D4C9db96C4b5Da5A

  • Token Contract: 0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d

  • Payment Amount: Matches selected plan

  • Network: Binance Smart Chain (56)

Red Flags

  • 🚨 Unexpected recipient addresses

  • 🚨 Requests for private keys

  • 🚨 Unusual token contracts

  • 🚨 Excessive gas fees

  • 🚨 Unsecured (http://) connections

After Payment

Record Keeping

  • 📝 Save transaction hash

  • 💾 Screenshot confirmation

  • 📧 Note subscription details

  • 🗓️ Mark renewal date

Account Security

  • 🔄 Monitor subscription status

  • 👀 Watch for unauthorized access

  • 📱 Enable account notifications

  • 🔐 Regular security reviews

Payment Support

Self-Service Resources

  • 📖 This payment guide

  • 🔧 Troubleshooting Guide

  • 💬 Community forums

  • 📺 Video tutorials

Direct Support

  • 📧 Email: [email protected]

  • 💬 Live chat (when available)

  • 🎫 Support ticket system

  • 📱 Community Discord

Emergency Contacts

For urgent payment issues:

  • 🚨 Critical payment failures

  • 💰 Missing subscription after payment

  • 🔒 Security concerns

  • 🐛 System-wide payment issues


Ready to make your payment? Follow the steps above and start trading with zero gas fees!

Need additional help? Check our Troubleshooting Guide or contact our support team.