Pay Protocol Documentation
website·Indexed 31 days ago
https://doc.payprotocol.networkA decentralized non-custodial digital asset payment platform. Documentation covers merchant onboarding, API integration for payments and subscriptions, e-commerce plugins for WooCommerce, Shopline, and Ueeshop, and the Signer tool (v1.4.0) for performing offline signatures on EVM and TVM chains.
What's inside Pay Protocol
- Auto-refund is a feature that automatically returns eligible funds to user addresses. Because this process involves on-chain operations, it incurs Gas Fees. The platform allows for the configuration of refund fees to align with specific business requirements. The implementation process typically involves prepaid account setup, strategy configuration, and the definition of the refund creation workflow.
Overview of Auto-refund functionality
Auto-refund is a feature that automatically returns eligible funds to user addresses. Because this process involves on-chain operations, it incurs Gas Fees. The platform allows for the configuration of refund fees to align with specific business requirements.Overview of built-in cross-chain swap capabilities
The admin console provides built-in cross-chain swap functionality to transfer assets between major blockchains without external bridge integration. It supports USDT and other mainstream stablecoins and native coins across TRON (TRC20), Ethereum (ERC20), and BSC (BEP20). Funds are sourced from the Hot Wallet (Finance) account, and fees are integrated into the real-time swap rate. Settlement typically occurs within minutes, depending on on-chain congestion.Overview of the Pay Protocol payment process
The Pay Protocol payment flow allows merchants to generate payment requests that users can fulfill via payment links or wallet addresses. The system automatically confirms the payment and notifies the merchant via a callback.
Workflow:
- Merchant calls
createPaymentOrder. - Merchant receives a payment link or sub-contract address.
- User completes the payment.
- Pay Protocol sends an asynchronous callback to the merchant's
notifyUrl. - Merchant confirms the order status.
- Merchant calls
Overview of Auto-refund functionality
Auto-refund is a feature that automatically returns eligible funds to user addresses. Because this process involves on-chain operations, it incurs Gas Fees. The platform allows for the configuration of refund fees to align with specific business requirements. The implementation involves prepaid account setup, strategy configuration, and a defined refund creation workflow.Overview of Pay Protocol Subscription Flow
Pay Protocol allows merchants to create subscription plans in the admin console and generate dedicated subscription links for users via the API. The general workflow is:
- Create a subscription plan in the Admin Console.
- Call the
createSubscribeOrderAPI to generate a subscription link. - Redirect the user to the subscription page for wallet signing and authorization.
- Periodically query chargeable subscriptions and use the Signer service to initiate billing.
- Handle subscription events via callbacks.
Overview of Pay Protocol Web3 Payment Gateway
Pay Protocol is a decentralized, non-custodial Web3 digital encryption asset payment gateway. It utilizes assembly-level smart contracts to provide a secure, open-source solution for crypto asset payments and custody. Key technical advantages include:
- Decentralized Service: 24/7 uninterrupted blockchain contract solutions with cold/hot isolation and multi-permission management.
- On-chain Confirmation: All transactions are recorded on the blockchain using the log function to minimize GAS consumption while ensuring full data recovery.
- Security: Eliminates the need for third-party custody fund pools or MPC private key fragmentation, relying instead on the security of the underlying public blockchain.
Overview of the PayProtocol Signer
The Signer is a tool used to perform offline signatures for multiple withdrawal transactions. By signing transactions offline, developers can accelerate the process of publishing transactions to the blockchain.Overview of Pay Protocol architecture and security
Pay Protocol is a non-custodial digital asset payment protocol that uses on-chain smart contracts and multi-signature technology to manage merchant funds. Unlike custodial models, the platform does not hold user private keys or merchant assets; funds are stored in customized smart contracts for each merchant. Security is maintained through signer isolation (private keys stored locally), guardian validation for risk control, and open-source contracts audited by ExVul.Deploy and use the Signer for batch payouts
The Signer is a server deployed within a merchant's internal network. It executes customer asset distribution scripts by calling the Hot Wallet private key locally. This architecture enables secure batch payouts while minimizing the risk of exposing private keys to the external network.Understand the Guardian security component
The Guardian is a security service component deployed in the backend or on an independent server. It provides secondary validation and permission review for on-chain payout requests or critical multi-signature operations originating from a merchant system.
Its core mechanism involves independently generating a signature using the same parameters as the merchant system and comparing the two. On-chain execution is only permitted if the signatures match and permissions are valid, preventing data tampering, forged signatures, and unauthorized operations.
Manage wallet addresses using Tag Address
Tag Address allows merchants to categorize and manage wallet addresses. By specifying a
tagIdwhen creating a payment order, the system automatically assigns a receiving address from the corresponding tagged address pool based on the following allocation rules:- Reuse: If an available address exists under the specified tag, the system prioritizes reusing it.
- Automatic Creation: If all addresses under the tag are occupied, the system automatically creates a new address.
- Automatic Assignment: Any newly created address is automatically assigned to the same tag.
This mechanism is designed for scenarios requiring address categorization, reuse, and automatic expansion when managing a large volume of receiving addresses.