Skip to main content

Centaurus

Overview

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

Centaurus Logo

Features

  • UPI payment support
  • INR currency support
  • Secure payment processing
  • Instant payment notifications
  • Customizable success and failure callbacks
  • UTR (Unique Transaction Reference) verification

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

All UPI payment apps supported:

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

Payment Verification

When completing a payment, users will need to enter their Payment Reference Number (UTR).

warning

You can find the UTR in your UPI app's transaction history or payment confirmation screen.

The UTR serves as a unique identifier for the transaction and is essential for payment verification.

Implementation

Payment Payload Structure

const payload = {
amount: number, // Payment amount in INR
currency: "INR", // Fixed as INR for Centaurus
currencyType: "centaurus", // 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 createCentaurusPayment() {
try {
const paymentPayload = {
amount: 1000, // Amount in INR
currency: "INR",
currencyType: "centaurus",
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);

// Redirect to UPI payment page
window.location.href = payment.paymentLink;
} catch (error) {
console.error("Payment creation failed:", error);
}
}

Testing

  1. Use test API keys for development
  2. Test UPI payment flows
  3. Verify callback handling for both success and failure scenarios

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": "centaurus",
"isKycOptional": true,
"customerEmail": "customer@example.com",
"successCallback": "http://domain.com/success",
"failureCallback": "http://domain.com/failure"
}'

Test UPI IDs

For testing payments in the development environment, you can use the following test UPI ID:

Test UPI ID: test@banksy

Security Considerations

  • Always use HTTPS for API calls
  • Validate all input parameters
  • Store sensitive data securely
  • Implement proper authentication for callback endpoints
  • Monitor transactions for suspicious activity

Best Practices

  1. Amount Validation

    • Ensure the amount is a positive number
    • Validate against minimum and maximum transaction limits
    • Handle INR amounts appropriately (no decimal points)
  2. Payment Verification

    • Always verify payments using UTR
    • Implement proper UTR validation
    • Store UTR numbers for future reference
    • Handle invalid UTR scenarios appropriately
  3. Callback URLs

    • Use HTTPS for callback URLs
    • Implement proper validation in callback endpoints
    • Handle both success and failure scenarios gracefully
  4. Error Handling

    • Implement comprehensive error handling
    • Log all payment attempts and responses
    • Provide clear error messages to users

Support

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