Metamask & web3js Ethereum payment method extenstion for Magento 2 without any third party gateways

Overview

CurrencyPrecision Magento 2 Extension

Metamask Ethereum payment method module for Magento 2

Table of contents

Description

Extension allows to receive direct payments from customer Ethereum blockchain wallet to merchant Ethereum wallet using Metamask in Ethereum cryptocurrency Ethers.

Idea

Using any gateways and third party services to make and receive payments breaks the philosophy of cryptocurrencies. If you use cryptocurrencies to pay you should be able to make it directly between wallets that no one can control, interrupt and change your transaction. But when this module was created there are only modules for Magento 2 from companies that are gateways between customer and merchant and handle the payment process, can control this process and payment processes in this case have no any differences from using bank account.

The main idea of this module is to allow you make and receive payments directly between wallets, without using any third party gateways and commission and pay only networks gas.

Features

  1. Display prices in Ether currency
  2. Pay by Ether from checkout after placing order
  3. Pay from customer accound order view page (customer can pay on checkout or, if have any troubles, later from his account)
  4. Check transaction status using web3js library
  5. Check transaction status through etherscan.io API request
  6. Check transactions by cron using etherscan.io API request
  7. Check transaction manually from admin area transaction page

Installation

To install module you need to add repositories to your composer.json:

Composer installation

    "repositories": {
        "crypto-base": {
            "type": "git",
            "url": "[email protected]:torys877/crypto-base.git"
        },
        "crypto-currency-precision": {
            "type": "git",
            "url": "[email protected]:torys877/crypto-currency-precision.git"
        },
        "crypto-metamask-eth-payment": {
            "type": "git",
            "url": "[email protected]:torys877/crypto-metamask-eth-payment.git"
        }
    }

Or add repositories from console:

composer config repositories.crypto-base git [email protected]:torys877/crypto-base.git

composer config repositories.crypto-currency-precision git [email protected]:torys877/crypto-currency-precision.git

composer config repositories.crypto-metamask-eth-payment git [email protected]:torys877/crypto-metamask-eth-payment.git

Install module:

composer require cryptom2/metamask-eth-payment:v1.0.0

And run

php bin/magento setup:upgrade

Settings

Checkout Payment Page

Live Settings

  • Enabled - enable/disable payment method
  • Title - payment method title
  • Ether Network Version - version of network (can be checked in metamask settings, by default Ethereus is 1, but testing networks have another version)
  • Merchant Ether Address - merchant ethereum address to take payment
  • Etherscan Url - url to view transactions (can be different in different networks, useful during testing)
  • Check transaction on Etherscan - if set not cron does not work and transactions are checking only on frontend on payment page using web3js
  • Etherscan Api Url - display if Check transaction on Etherscan is enabled. Api url for needed network to check transaction (can be different for different networks)
  • Etherscan Api Key - display if Check transaction on Etherscan is enabled. Api key for etherscan - can be taken on etherscan.io/apis

Test Mode

Settings are the same as for Live, but you need to use test networks (test network version, test network etherscan api url/key etc. On screen uses Ropsten network)

Display Eth Currency

To display ETH currency you also need to add it to allowed currencies and add currency rate in magento (automatically update rates will maybe included in future releases)

Screenshots

Display Prices

Display Prices

Payment Method On Checkout

Note: Payment method is displaying only if ETH currency selected 

Checkout payment method

Connect Wallet

Note: If wallet is not connected firstly customer sees 'Connect Wallet' button, then 'Pay' button

Connect Wallet

Pay by ETH

Pay By Eth

Processing Transaction

Note: After confirming transaction in Metamask wallet, customer should wait on the same page to magento confirm transaction
Magento sends request to metamask using Web3js and try to get confirmation message, after it, Magento
sends request to server and if Etherscan checking is enabled, transaction status also is checking on etherscan.

IMPORTANT: it is highly recommended to enable etherscan checking to prevent JS injection on processing page

Processing Transaction

Check transaction in admin area

Transaction ID is clickable and move you on etherscan page for this transaction

Check in admin area

Pay From Customer Account

If customer placed order but not paid it, he still can do it from his account. This button sends him to processing page and allows to do payment

Pay from customer account

Transaction Captured

When transaction is captured and approved in blockchain and magento, customer sees this message 

Pay from customer account

Author

Ihor Oleksiienko

License

Metamask Ethereum extension for Magento 2 is licensed under the MIT License - see the LICENSE file for details

You might also like...
A PHP package to simplify using DPO Payment API in your application.

DPO (Direct Pay Online) PHP Package The best DPO php package, simple Ever This is the package that will help you add DPO Payment API to your PHP Appli

QPay Moodle payment gateway plugin

QPay Moodle payment gateway plugin The plugin allows a site to connect to QPay. This plugin was developed by Smotana thanks to funding from Aspire Edu

Sharkpay is a system to provide a full order/payment eco-system for your project.
Sharkpay is a system to provide a full order/payment eco-system for your project.

sharkpay sharkpay is a PHP library which aims to provide a full order/payment eco-system for your projects. A form of plug-in & ready to go for E-Comm

Adds a new report to the WooCommerce analytics section about used payment methods.

Payment Methods Report for WooCommerce This is an extension to WooCommerce Analytics that will display a new report on the usage of configured payment

Mawthouq Payment is an open source project by Mawthouq

mawthouqpay Welcome to the mawthouqpay ! Mawthouq Payment is an open source project by the first platform Mawthouq that works in Algeria to develop th

Prestashop module for Orange Money web payment in Central Africa
Prestashop module for Orange Money web payment in Central Africa

PrestaShop payment module which allow to add African (Cameroon, Cote D'Ivoire etc...) Orange Money payment method on our website

A Magento 1.9's module to export products informations, inside a chosen date range, to a .XLSX file.
A Magento 1.9's module to export products informations, inside a chosen date range, to a .XLSX file.

Magento 1.9 Export products module A magento 1.9 module to export products informations to a .XLSX file. Module informations Package/Namespace: "Mathe

Magento 2 module to only allow checkout when the number of items in the cart are a multiple of X.

Cart Quantity Multiple - Magento 2 Module Introduction This module allows to limit checkout only when the contents of the cart are a multiple of X

Example of Pre-Loader Implementation for Magento 2

Example of preloader Implements optimistic preloader for configurable product data without taking into account simple product status for: Price of con

Releases(v1.0.1)
  • v1.0.1(Aug 25, 2022)

    What's Changed

    • check merchant on backend by @torys877 in https://github.com/torys877/crypto-metamask-eth-payment/pull/2
    • add composer version by @torys877 in https://github.com/torys877/crypto-metamask-eth-payment/pull/3

    New Contributors

    • @torys877 made their first contribution in https://github.com/torys877/crypto-metamask-eth-payment/pull/2

    Full Changelog: https://github.com/torys877/crypto-metamask-eth-payment/compare/v1.0.0...v1.0.1

    Source code(tar.gz)
    Source code(zip)
Owner
Ihor Oleksiienko
Ihor Oleksiienko
PHP payment library to easily integrate Baltic banklinks (supports old and new iPizza protocol), E-commerce gateaway (Estcard, Nets Estonia), Liisi Payment Link and Pocopay.

PHP Payment library PHP payment library to easily integrate Baltic banklinks, E-commerce gateaway (Estcard, Nets Estonia), Liizi Payment Link and Poco

Rene Korss 34 Apr 27, 2022
Laravel paypal payment package , help you process credit card payment using paypal api

Important :The use of the PayPal REST /payments APIs to accept credit card payments is restricted by paypal and they recomand to use Braintree Direct

Anouar Absslm 328 Oct 31, 2022
The Laravel eCommerce Mollie Payment Gateway allows the merchants to integrate Mollie payment gateway to their bagisto Store.

The Laravel eCommerce Mollie Payment Gateway allows the merchants to integrate Mollie payment gateway to their bagisto Store.

Bagisto 2 May 31, 2022
(Live Link) Extensive ecommerce site with vendors, mods & ability to add to cart without being logged in. Upgraded to Laravel 8.x

(Live Link) Extensive ecommerce site with vendors, mods & ability to add to cart without being logged in. Upgraded to Laravel 8.x

null 14 Dec 21, 2022
A framework agnostic, multi-gateway payment processing library for PHP 5.6+

Omnipay An easy to use, consistent payment processing library for PHP Omnipay is a payment processing library for PHP. It has been designed based on i

The League of Extraordinary Packages 5.7k Jan 4, 2023
PHP 7+ Payment processing library. It offers everything you need to work with payments: Credit card & offsite purchasing, subscriptions, payouts etc. - provided by Forma-Pro

Supporting Payum Payum is an MIT-licensed open source project with its ongoing development made possible entirely by the support of community and our

Payum 1.7k Jan 5, 2023
Cardano Mercury Payment Gateway for WooCommerce

Cardano Mercury for WooCommerce Simple, reliable plugin to accept Cardano (Ada) payments for goods and services in WooCommerce. Version: 1.0 Tags: woo

null 25 Aug 3, 2022
stripe payment

CodeIgniter 4 Application Starter What is CodeIgniter? CodeIgniter is a PHP full-stack web framework that is light, fast, flexible and secure. More in

aminxs 3 Jul 29, 2021
Binance Smart Chain - BNB Payment Gateway

BSC Pay (Simple BNB Payment Gateway) I like to use Binance Smart Chain, do you? You can use my simple payment gateway if you need to get paid with BSC

null 18 Dec 19, 2022
Payu payment gateway for bagisto laravel ecommerce open source platform

Bagisto Payu Payment Gateway Payu is a popular payment gateway in india. This package provides a additional strong help for the user to use the payu p

Saju G 3 Dec 14, 2021