Creating White-Label Payment

This endpoint allows you to create white-labeled payments, providing a seamless payment experience while utilizing the OxaPay payment gateway behind the scenes. Rather than generating an Invoice, this method provides detailed payment information, including the payment address, currency, amount, expiration time, and more.

To enhance flexibility and user convenience, you can utilize URI formats, such as the Bitcoin Improvement Proposal (BIP-0021). This format allows you to generate a payment link with the crypto address embedded within it. By using the generated URI link, the payer can initiate the payment directly from their preferred wallet application.

Furthermore, you have the option to generate QR codes that contain the URI link. QR codes are easily scannable by wallet applications, allowing the payer to effortlessly open their wallet app and proceed with the payment by simply scanning the QR code. The simplest way to create a QR code is to use Google Chart Service.

Using URI formats and QR codes simplifies the payment process for the payer, as they can quickly open their wallet application with the specified address and amount pre-filled. This user-friendly approach enhances the convenience and efficiency of the payment experience.

POST https://api.oxapay.com/merchants/request/whitelabel

Request Body

{
  "result": integer, // Request result. More information about this number can be found in the Result Code table.
  "message": string, // The message containing the result of the request.
  "trackId": string, // The unique identifier of each payment session of the OxaPay payment gateway, which can be used to query the payment status and report requests (if the request is successful).
  "amount": long, // The requested payment amount.
  "currency": string, // The requested payment currency.
  "payAmount": long, // The actual payment amount.
  "payCurrency": string, // The actual payment currency.
  "network": string, // The blockchain network on which the cryptocurrency is expected to be received.
  "address": string, // The generated cryptocurrency address for the payment.
  "callbackUrl": string, // The specified callback to receive payment notifications
  "description": string, // The specified description
  "email": string, // The specified email
  "feePaidByPayer": decimal, // The specified feePaidByPayer
  "lifeTime": integer, // The specified lifeTime
  "orderId": string, // The specified orderId
  "underPaidCover": decimal, // The specified underPaidCover
  "rate": decimal, // The exchange rate of the specified cryptocurrency.
  "expiredAt": string, // The expiration time of payment to the address.
  "createdAt": string, // The created invoice time
  "QRCode": string // the QRCode image link for coin and amount
}

Please note that a successful request will return a result code 100. In case of any issues or validation problems, refer to the corresponding result codes for further details.

Example codes

curl -X POST https://api.oxapay.com/merchants/request/whitelabel \
  -d '{
    "merchant": "YOUR_MERCHANT_API_KEY",
    "amount": 100,
    "currency": "USD",
    "payCurrency": "TRX",
    "lifeTime": 90,
    "feePaidByPayer": 1,
    "underPaidCover": 10,
    "callbackUrl": "https://example.com/callback",
    "description": "Order #12345",
    "orderId": "12345",
    "email": "customer@example.com"
  }'

Last updated