OxaPay
With the OxaPay merchant web service, Bots.Business enables you to seamlessly accept crypto payments from your customers and facilitate hassle-free crypto payouts.
This integration empowers you to provide efficient, secure, and quick transactions, all without the need for extensive KYC procedures
Getting Started
To get started with the Bots.business integration with OxaPay, follow these steps:
1. Generate an OxaPay account and obtain your API key by referring to the OxaPay Getting Started Guide.
2. Set your generated API keys with the following sample codes:
For testing purposes, you can use 'sandbox' as the merchant key to access the OxaPay merchant web service in a sandbox environment.
Try Out the Sample Bot
Experience the convenience of OxaPay integration by trying our sample bot. Install and test the demo bot using the OxapayLibSampleBot library.
Visit Store > Crypto > OxapayLibSampleBot to get started.
Calling API Methods
You can interact with the OxaPay API by using the `apiCall` method. This method accepts three parameters:
- `url`: Specify OxaPay endpoints, such as '/merchants/request' or '/api/send' (refer to the OxaPay documentation for a full list of endpoints).
- `fields`: Provide an object containing input parameters relevant to the chosen endpoint. Refer to the API documentation for specific details.
- `onSuccess`: Define your custom logic to handle the output of the method.
Available URLs
Here is a list of commonly used OxaPay endpoints:
- `/merchants/request`: Request crypto payments.
- `/merchants/request/whitelabel`: Request crypto payments with white-label options.
- `/merchants/request/staticaddress`: Request crypto payments with static addresses.
- `/merchants/revoke/staticaddress`: Revoke static addresses.
- `/merchants/inquiry`: Make inquiries about crypto payments.
- `/merchants/list`: Listof your crypto payments.
- `/merchants/allowedcoins`: Get a list of your allowed cryptocurrencies.
- `/merchants/rate`: Check exchange rates.
- `/api/send`: Send crypto payments.
- `/api/list`: List of your pauout transactions.
- `/api/balance`: Check your account balance.
- `/api/currencies`: Get a list of supported cryptocurrencies by OxaPay.
- `/api/networks`: List of supported networks.
- `/monitor`: Monitor OxaPay service availability.
Feel free to explore these endpoints to build powerful crypto payment solutions with Bots.business and OxaPay.
Examples
Explore practical examples of integrating Bots.business with OxaPay.
Creating White-Label Payment
- Execute the command `/paytrx` to create a white-label payment.
- Provide necessary options such as amount, currency, payCurrency, lifeTime, orderId, and onCallback.
- The `onCreatePaymentWithTRX` command handles the output, generating a QR code and providing payment details.
Command /paytrx
command /onCreatePaymentWithTRX
Payment Callback
- When payment status changes, the `/onCallbackPayment` command processes the status and notifies users accordingly.
command /onCallbackPayment
Creating Payout
- Use the command /transfer
to initiate a payout.
- Specify options like amount, currency, address, and onCallback
.
- The onTransfer
command captures the result, notifying users about the payout status.
commend /transfer
command /onTransfer
Payout Callback
The /onCallbackPayout
command reacts to payout status changes and keeps users informed.
command /onCallbackPayout
Last updated