Skip to main content

Xenon

Overview

Xenon is a payment provider that enables businesses to accept UPI (Unified Payments Interface) payments in Indian Rupees (INR). It provides a robust and reliable integration for processing UPI transactions in India.

Xenon Logo

Features

  • UPI payment support
  • INR currency support
  • Real-time payment processing
  • Instant payment notifications
  • Configurable success and failure callbacks
  • UTR (Unique Transaction Reference) verification
  • High transaction success rates

Integration Requirements

  • Banksy API Key
  • Valid callback URLs for success and failure scenarios
  • Customer email for transaction notifications

Supported Currencies

Currencies
  • INR

Accepted Payment Methods

Supports all major UPI payment apps:

  • Google Pay
  • PhonePe
  • Paytm
  • BHIM
  • Other UPI-enabled apps

Payment Verification

For payment verification, users need to provide their UPI Payment Reference Number (UTR).

warning

The UTR can be found in your UPI app's transaction history or payment confirmation screen. This is required for payment verification.

Implementation

Payment Payload Structure

const payload = {
amount: number, // Payment amount in INR
currency: "INR", // Fixed as INR for Xenon
currencyType: "xenon", // Fixed value for UPI transactions
isKycOptional: boolean, // Whether KYC is required
customerEmail: string, // Customer's email address
successCallback: string, // URL for successful payments
failureCallback: string, // URL for failed payments
};

Example Implementation

import { Banksy } from "banksy-sdk";

// Initialize the Banksy SDK with your API key
const banksy = new Banksy("your-api-key");

async function createXenonPayment() {
try {
const paymentPayload = {
amount: 1000, // Amount in INR
currency: "INR",
currencyType: "xenon",
isKycOptional: true,
customerEmail: "customer@example.com",
successCallback: "https://your-domain.com/success",
failureCallback: "https://your-domain.com/failure",
};

const payment = await banksy.createPayment(paymentPayload);
console.log("Payment Created:", payment);
return payment;
} catch (error) {
console.error("Payment Creation Failed:", error);
throw error;
}
}

Best Practices

  1. Always verify the payment status using the UTR number
  2. Implement proper error handling
  3. Store the payment ID for future reference
  4. Validate callback responses for security
  5. Set appropriate payment timeouts

API Testing with cURL

curl --location 'https://sandbox-api.banksy.id/sdk/payment/create' \
--header 'Content-Type: application/json' \
--header 'X-AUTH: ck_test_************738139' \
--data-raw '{
"amount": 1000,
"currency": "INR",
"currencyType": "xenon",
"isKycOptional": true,
"customerEmail": "customer@example.com",
"successCallback": "http://domain.com/success",
"failureCallback": "http://domain.com/failure"
}'

Support

For technical support or integration assistance, please contact the Banksy support team through the official channels.