This guide describes how to install and configure Openpay Payment Gateway Extension to Magento 1.9.X Community Edition. You should have an existing Magento installed.
Magento is an eCommerce platform, built on open source technology, which provides online merchants with not only a flexible shopping cart system, but also control over the look and feel, content and the functionality of their online store. Magento has been fully integrated with Openpay’s online payment solutions.
Installing and configuring the Hosted Payment Solution module of Openpay provide a simple, secure and convenient option to connect with Openpay’s online payment processing platform via Magento.
In order to start taking payments through Openpay, you need to sign up and get approval for an Openpay merchant account. Once your application is approved, you can configure Openpay Hosted Payment Solution module and start taking payments.
Openpay provides a test account and users for training and testing purpose.
Before installing the Openpay module, make sure that your web server meets the following criteria:
For further details on PHP compatibility, MySQL, supported Web servers and other requirements, please refer to the Magento website: http://devdocs.magento.com/guides/m1x/system-requirements.html
Magento can be run on a Windows server.
To install the Openpay payment extension, copy and paste all the plugin files within the Magento root folder
cd <magento installation directory>/app/code/community/Openpay/Payment/Model/paymentadapter/OpenpayApi and run the command composer install to download the packages
Log in to the Magento admin panel and clear your browser cache and Session:
Navigate to System > Cache Management > Flush Magento Cache
Log in to your Magento admin account. If cron is not configured properly, you will get the error message (see the screenshot below). You need to setup the Magento cron properly. For cron set up instructions click here.
Navigate to Stores > Configuration > (on left panel) Sales > Payment Methods > Openpay Payment Method
Openpay Cron Jobs Setup:
Please make sure cron jobs are setup on your server to fetch the Min/Max Amounts configured for the nominated retailer and to update the status of the Pending Orders in Magento to either Active or Cancelled depending on the plan Status in Openpay.
Min/Max Cron Job The purpose of this call is to not display Openpay as a payment option if the order total is not within the range and this job will run every day at midnight.
Update Order Status Cron Job will run every hour to update the status of the pending orders in the store.
Please install the plugin Aoe_Scheduler, which will provide a good UI for cron jobs.
https://github.com/AOEpeople/Aoe_Scheduler/tree/master
After installing Cron Scheduler Module, you will automatically see the Openpay cron jobs.
If the customer chooses to checkout with items that are worth less than the total amount provided in the admin total, then Openpay will not show on the “Payment Method”.
If the amount is greater than the Minimum Order Value and Less than the Maximum Order Value which is set on admin configuration, it will allow the users to pay using Openpay Payment Method.
Click on the “Continue” tab, and the Order Review Option will be shown.
Click on the ‘Place Order’ and it will be redirected to the Openpay Payment Gateway. This will perform a HTTP POST request to Openpay.
If the customer is already registered with Openpay, the following screen will be displayed:
If you do not have an Openpay account, you need to create one.
We do not send Email code on training mode please use 123456 for verification.
We do not send SMS on training mode please use 111111 for verification.
If the customer continues to login, then the following page will be displayed:
If one clicks on Submit Plan, and the plan is successful, the browser will be redirected to your site with “Your order has been placed” message.
This section provides the credentials for test user and test merchant account on Openpay Training Environment to create and check your Openpay plan.
Username: testmagento@xx.yy
Password: Testing123
https://retailer.myopenpay.com.au/training
Username: test_user
Password: Test@123
Processing
After successful payment order status will be ‘Processing’.
Complete
If the order is shipped or dispatch by the admin then orders status change to complete. If there is any partial refund it also changes the order to ‘Completed’.
Cancelled
If the order is cancelled by an admin user, or if ‘Automatically Cancel Openpay Pending Orders’ is set ‘Yes’ in Openpay payment settings, it will cancel the order based on the frequency of which it is configured. Openpay recommends that this frequency is set to ‘After one hour’.
Close
If the order is fully refunded by an admin user, then orders status change to ‘Close’.
Below is the detailed order status to share with your staff who look after orders, dispatch and refunds.
Select an Openpay order you wish to partially refund. Order Status of that order should be either ‘Complete’ or ‘Processing’. (Example: Order ID#145000074)
Navigate from Magento Admin Panel to Sales > Orders > Choose the Openpay order you wish to refund and click on View.
Information > Invoice > Submit Invoice
Now, we have to create a Credit Memo for this order.
Click on Invoices > Open the Invoice > Click Credit Memo from the right upper corner.
New Credit Memo for the Order will be created.
To double check if this plan is active log on to your Openpay Retailer Portal in this instance the Openpay Plan ID is ‘3000000072571’. (This is just an example your Openpay plan id will be different).
Plan Status column on Openpay dashboard will show the plan Active as we haven’t refunded the plan yet.
Back to your Magento admin scroll down to Qty to Refund
Under Qty to Refund change the quantity to ‘0’ on all the products except the one you want to refund and click Update Qty’s.
If you wish you can refund the shipping amount by changing the value on Refund Shipping or adjust the refund manually by changing the value on Adjustment Refund and click on > Refund.
Refunded order will show as follows.
Back on Openpay Retailer’s Portal, after the partial refund, we can see the Openpay plan is updated, and under the ‘Purchase’ column amount has changed from $73.00 to $60.00. The plan will still show Active as the balance amount is yet to be paid off.
On Magento admin, the order status will show ‘Processing’ for a partial refund.
Please Note: The order can be partially refund n number of times until the full amount is refunded. You have to repeat the same process to make another partial refund.
Choose an Openpay order you wish to fully refund.
Order Status of that order should be either ‘Complete’ or ‘Processing’. (Example: Order ID# 145000075) Navigate from Magento Admin Panel to Sales > Orders > Choose the Openpay order you wish to full refund.
Click on Invoices > View
Now, we have to create a Credit Memo for this order. Click Credit Memo from the right upper corner.
To double check if this plan is active Openpay log on to your Openpay Retailer Portal in this instance the Openpay Plan ID is ‘3000000072573’. (This is just an example your Openpay plan id will be different).
Plan Status column on Openpay dashboard will show the plan Active as we haven’t refunded the plan yet.
Back to your Magento admin scroll down to Refund Totals and click on Refund button this will refund the full order amount.
Now the Status will be updated to ‘Closed’
You have now fully refunded the Magento Order.
You may confirm the refund on Openpay Retailers Dashboard the Openpay Plan Status will be changed to Refunded and the Purchase amount will change to $0.00
Set <active>true</active> to <active>false</active>
On the Openpay website, if there is an update available for the Openpay payment extension, then the client will get the notification of Update with the download link. They can download that extension from the Openpay website and install it.
Q: For a successful purchase, what is the status in Magento?
A: After successful payment order status will be “Processing” by default.
Q: When does a processing order status change to complete?
A: If the order is shipped or dispatch by the admin then the order status change to complete. Also if there is any partial refund the order status change to complete.
# | Date | Version | Description |
---|---|---|---|
1 | February 2021 |
1.0.0
|
Created payment plugin |