maxelpay-js

1.0.1 • Public • Published

Maxelpay Integration

DESCRIPTION

MaxelPay.com offers a simple and fast solution for accepting Ethereum, BNB, and various other cryptocurrencies. Seamlessly receive crypto payouts from fiat currencies like Euros or U.S. Dollars, all without worrying about exchange rate volatility. Our package connects you with a streamlined way to generate secure checkout links for cryptocurrency payments. With this, you can easily integrate cryptocurrency payment options into your website or web applications by leveraging API keys, secret keys, payloads, and environment settings.

Payments received from customers can be instantly converted to fiat, and you can receive payouts in Euros and U.S. Dollars directly to your MaxelPay wallet. Start accepting cryptocurrencies in no time!

Features

  • Set it and forget it: The gateway operates on autopilot.
  • Payment amount: Calculated using real-time exchange rates.
  • Simplicity for you, flexibility for your customers: On our invoices, a customer can choose to pay with the listed cryptocurrencies which you choose to accept at checkout, resulting in your payouts.
  • No setup
  • Generate Checkout Links: Create secure and dynamic checkout links for processing cryptocurrency payments.
  • API Key Integration: Utilize your API key and Secret key to authenticate requests and ensure secure transactions. You can get your API key and secret key at MaxelPay.
  • Flexible Payload Handling: Customize the payment request payload to include necessary transaction details.
  • Environment Support: Configure and switch between different environments (e.g., production, staging) to match your deployment needs. has context menu

INSTALLATION

  npm i maxelpay-js

HOW TO USE

ENV Keys

 Copy and paste given keys in your .env file. You can get api key and secret key from https://dashboard.maxelpay.com/developers

  maxelpay_api_key = '' // API Key
  maxelpay_secret_key = '' // Secret Key
  maxelpay_environment = 'stg' // update to 'prod' for live integration.
 

Example

const dotenv = require('dotenv'); // Require this package in back-end if you want to use env file.
const maxelpayCheckout = require('maxelpay-js');

dotenv.config(); //If we use in back-end and dotenv package is used we will use dotennv.config for env variables usuage

const payload = {
    "orderID": "113099", //unique id
    "amount": "100",
    "currency": "USD", // supported currencies - https://dashboard.maxelpay.com/documentation/integration
    "timestamp": "1717651675", //current unix timestamp
    "userEmail": "john@example.com",
    "userName": "John Doe",
    "redirectUrl": "https://example.com/checkout/order-received/113099/", // after order completion user will redirect to this url
    "websiteUrl": "https://example.com",
    "cancelUrl": "https://example.com/cancel", // after cancel order user will redirect to this url
    "siteName": "your site name",
    "webhookUrl": "https://example.com/validate_order_status" // mention webhook url to listed order statuses from maxelpay.
};

maxelpayCheckout(payload, process.env.maxelpay_api_key, process.env.maxelpay_secret_key, process.env.maxelpay_environment)
    .then(maxelcheckouturl => {
        console.log('url:', maxelcheckouturl);//user will get the url link
    })
    .catch(error => {
        console.error('Error:', error);
    });

Package Sidebar

Install

npm i maxelpay-js

Weekly Downloads

4

Version

1.0.1

License

ISC

Unpacked Size

8.63 kB

Total Files

5

Last publish

Collaborators

  • maxelpay