Skip to content
1nodesPublic

About

A crypto payment gateway for Blesta, with non-custodial payments and direct-to-wallet support via XPUB.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

1nodes Blesta Gateway

Cryptocurrency payment gateway for Blesta powered by 1nodes.

Accept cryptocurrency payments through Blesta with automatic payment verification, webhook support, invoice status updates, and payment status checking.

Requirements

  • Blesta 6.x
  • PHP 8.1+
  • A 1nodes merchant account

Features

  • Cryptocurrency payments for Blesta
  • Automatic payment verification
  • Webhook support
  • Automatic invoice payment updates
  • Payment status checking after returning from checkout
  • HMAC-SHA256 webhook signature verification
  • Non-merchant gateway integration
  • Blesta Order System support
  • Automatic payment confirmation after webhook processing

Installation

The 1nodes Blesta integration consists of two required components:

  1. The 1nodes payment gateway
  2. The 1nodes payment status plugin

Both components must be installed.

1. Install the Gateway

Copy the following directory from this repository:

components/gateways/nonmerchant/one_nodes/

to your Blesta installation:

components/gateways/nonmerchant/one_nodes/

The gateway structure should look like:

components/
└── gateways/
    └── nonmerchant/
        └── one_nodes/
            ├── config.json
            ├── one_nodes.php
            ├── language/
            └── views/

2. Install the Plugin

Copy:

plugins/one_nodes/

to:

plugins/one_nodes/

The plugin structure should look like:

plugins/
└── one_nodes/
    ├── config.json
    ├── one_nodes_plugin.php
    └── views/
    └── controllers/
        └── onenodes.php

3. Enable the Plugin

Log in to the Blesta administrator panel.

Go to:

Settings → Company → Plugins

Find 1nodes and install/enable the plugin.

4. Enable the Gateway

Go to:

Settings → Company → Payment Gateways

Find 1nodes under the non-merchant gateways and install/enable it.

Configuration

Open the 1nodes gateway settings in Blesta.

Configure:

  • Merchant Key
  • Secret Key (Webhook)

Your credentials are available from your 1nodes merchant dashboard.

Merchant Key

The Merchant Key is used by Blesta to authenticate payment creation requests to the 1nodes API.

Secret Key

The Secret Key is used to verify webhook requests sent by 1nodes.

Keep both credentials private.

Payment Flow

When a customer selects 1nodes during checkout:

  1. Blesta creates the order and invoice.
  2. The 1nodes gateway creates a cryptocurrency payment.
  3. The customer is redirected to the 1nodes checkout page.
  4. The customer completes the cryptocurrency payment.
  5. 1nodes sends a signed webhook to Blesta.
  6. Blesta verifies the webhook signature.
  7. The invoice is marked as paid.
  8. The customer returns to Blesta.
  9. The 1nodes plugin checks the invoice payment status.
  10. The customer is shown the updated payment status.

Webhooks

1nodes uses webhooks to notify Blesta when a payment has been confirmed.

Webhook requests are authenticated using an HMAC-SHA256 signature.

The signature is calculated from the raw webhook request body using the configured Secret Key.

Blesta verifies the signature before processing the payment notification.

Payment Status Checking

After the customer returns from the 1nodes checkout page, the 1nodes plugin automatically checks the invoice status.

The status checker:

  • Waits for the webhook to update the invoice.
  • Checks the invoice payment status periodically.
  • Detects when the invoice has been paid.
  • Updates the customer when payment confirmation is available.

This allows the customer to remain on the checkout completion page while the webhook is being processed.

API

The gateway uses the 1nodes payment API to create cryptocurrency payments.

Create Payment

POST https://1nodes.com/wp-json/v1/api/create-payment

Authentication

Authorization: Bearer <Merchant Key>

Headers

Accept: application/json
Content-Type: application/json
Authorization: Bearer <Merchant Key>

The gateway sends payment information including:

  • Payment amount
  • Blesta order/invoice information
  • Callback URL
  • Return URL
  • Currency
  • Customer information
  • Woo/Blesta integration metadata where applicable

Directory Structure

The repository contains both required components:

.
├── components/
│   └── gateways/
│       └── nonmerchant/
│           └── one_nodes/
│               ├── config.json
│               ├── one_nodes.php
│               ├── language/
│               └── views/
│
└── plugins/
    └── one_nodes/
        ├── config.json
        ├── one_nodes_plugin.php
        └── views/
        └── controllers/
            └── onenodes.php

Gateway

components/gateways/nonmerchant/one_nodes/

The gateway is responsible for:

  • Gateway configuration
  • Payment creation
  • Communication with the 1nodes API
  • Redirecting customers to 1nodes
  • Receiving payment webhooks
  • Verifying webhook signatures
  • Marking invoices as paid

Plugin

plugins/one_nodes/

The plugin is responsible for:

  • Client-side payment status checking
  • Checking invoice payment status
  • Displaying the payment confirmation state after checkout

Both components work together and are required for the complete integration.

Security

The integration uses signed webhook requests to protect payment notifications.

Webhook signatures use:

HMAC-SHA256

Never share your:

  • Merchant Key
  • Secret Key
  • Wallet private keys
  • Wallet recovery phrase

Troubleshooting

Gateway Does Not Appear

Verify that the gateway exists at:

components/gateways/nonmerchant/one_nodes/

Then go to:

Settings → Company → Payment Gateways

and verify that the 1nodes gateway is available and enabled.

Payment Status Does Not Update

Make sure both components are installed:

components/gateways/nonmerchant/one_nodes/

and:

plugins/one_nodes/

Also verify:

  • The webhook URL is reachable.
  • The Secret Key is correct.
  • The webhook signature is valid.
  • The invoice exists in Blesta.
  • The 1nodes plugin is enabled.

Payment Status Checker Does Not Appear

Verify that the customer is returning to the Blesta Order System checkout completion page after payment.

Also verify that the 1nodes plugin is installed and enabled.

Support

For help with installation, configuration, or payments, visit 1nodes.

License

Proprietary software. All rights reserved.

About

A crypto payment gateway for Blesta, with non-custodial payments and direct-to-wallet support via XPUB.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages