Payment Gateway Setup (AlfaCoins)

Overview
AlfaCoins is a payment gateway for blockchain payments. According to their website "ALFAcoins was founded in 2013 as a Bitcoin payment processor and has since become a trusted provider of payment services supporting Bitcoin, Litecoin, Ethereum, Bitcoin Cash, Dash, XRP and Litecoin Testnet". To use this gateway please see below.
Live/Sandbox
AlfaCoins doesn`t have a native Sandbox area, but passes test variables if Maian Coin is in test mode.

Live Account:
https://alfacoins.com.
API Setup
NOTE: Before you can set up the API, you must verify your site and activate 2 factor authentication.
1 Log into your AlfaCoins account.

2 From the menu click "Integration > API".

3 Click "Add" to create new API credentials.

4 Complete all options. Permissions can be all. For "Notification URL" enter full url to your 'control/callback.php file.

https://www.example.com/coin/control/callback.php

5 Save API and make a note of the secret hash shown on screen.

6 Log in to your Maian Coin control panel and navigate to "Settings > Payment/Currency".

7 On the "General" tab, select "AlfaCoins" as the "BitCoin/Blockchain Gateway".

8 On the parameters tab, create the following parameters:

alfacoins-api-pass: Your AlfaCoins API password
alfacoins-api-secret: Your AlfaCoins API secret key
alfacoins-shopname: Your AlfaCoins API shop name
alfacoins-pay-type: Your preferred payment crypto currency. The setting here overwrites the "Receiving Currency" value in the payment settings. The value for "alfacoins-pay-type" MUST be one of the following ONLY: bitcoin, litecoin, ethereum, bitcoincash, dash, xrp OR litecointestnet


Setup completed. You are now ready to receive/test payments using AlfaCoins.
Accepted Statuses
Maian Coin will only update a sale as completed when it receives a response of "completed" from AlfaCoins. In some cases, there could be a delay before this response is received. If you would like the system to update a sale as completed for other statuses, add them to the 'accepted-statuses' array in the following file:

control/classes/gateways/class.alfacoins.php

You should be cautious about this. Only the "completed" status confirms the sale on the blockchain and the merchant.

For a list of available statuses see the AlfaCoins website.

If you wish to allow sales that are pending (if supported by gateway), see the "Process Pending Payments as Completed" option in the payment settings.
Allowed IP Addresses
Maian Coin will only accept callbacks from valid gateway IP addresses. At the time of these docs, the allowed IP(s) for this gateway are:

138.201.230.93

If the IP(s) are updated/changed, update IP addresses in the following file:

control/classes/gateways/class.alfacoins.php