800.897.5709

How To: Square Payment Installation Instructions

Magento version 2.x
Purpose

The purpose of this document is to provide you with detailed instructions for installing your Square Payments extension to connect your Magento e-commerce website with your existing Square Account.

Requirements
Installation
  1. Download OPG Square installation package.
  2. Upload contents of the OPG Square installation package to your store root directory.
    opg magento installation

    • Create folder /app/code/OPG/Square
    • Upload content of the OPG Square installation package to /app/code/OPG/Square
      opg magento installation
  3. Connect to the server through SSH (you can use putty).
  4. Navigate to the “public_html” directory. (The command to do this is: cd public_html < enter >)
    null
  5. Execute the following command: composer require square/connect
  6. Execute the following command: php -f bin/magento setup:upgrade < enter >
    null
  7. Once complete, execute the following command: php -f bin/magento setup:static-content:deploy < enter >
    null
  8. NOTE: The above command will take some time to complete the process.
  9. Once the above process is complete, you will need to clean the cache. This can be done by executing the following command: php bin/magento cache:clean < enter >
    null
  10. Now you will need to flush the cache. This can be done by executing the following command: php bin/magento cache:flush < enter >
    null
  11. Log in the Magento Admin Panel.
  12. In the far left navigation menu, select “Stores”.
    null
  13. From the Stores menu, select “Configuration”.
    null
  14. Once the Configuration page loads, from the left Configuration navigation menu, select “Sales”.
    null
  15. From the dropdown list of the Sales options, select “Payment Methods”.
    null
  16. At the bottom of the Payment Methods page, select “Square”.
  17. Once the “Square” option is open, set the following:
    • Enabled = Yes
    • Select the “Obtain and access token” button
    • Enter the login credentials for the Square Account and select “Sign In”
      • This will access the Square Account to obtain and auto-fill the Personal Access Token information
    • Title = Credit Card (Square), or whatever you wish.
    • Select a sandbox location
    • Sandbox = “No”.
  18. NOTE: Should the following message display, “One or more of the Cache Types are invalidated:Configuration, Page Cache. Please go to Cache Management and refresh cache types.”, do the following otherwise, proceed to the next step (24).
    • Click the “Cache Management” link and select “Flush Magento Cache”.
      null
    • Once the process is complete return to the Payment Methods section (From the left navigation menu select Stores> Configuration>Sales> Payment Method> Square).
      null
  19. Select “Save Config” in the top right corner.
  20. NOTE: Should the following message display, “One or more of the Cache Types are invalidated:Configuration, Page Cache. Please go to Cache Management and refresh cache types.”, repeat step 23.
  21. After an order is place from the front end using Square as the payment method, Magento Admin Panel will display the following on the Order Details:
    • Under Payment Information, “Credit Card (Square)” will be displayed.
      null
    • At the very bottom or the Order Details, “Captured amount of $XX.XX online. Transaction ID: “xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx’’ will be displayed.
      null

For more information on how to produce refunds with Square Payments for Magento 2 click here.

If you still need assistance, please contact our friendly and responsive support team at [email protected] or 1-800-897-5709.