Search for keywords, like "PayPal", "Recurring Donations", and more.

Documentation / Add-ons / 2Checkout Gateway / Testing the 2Checkout Gateway

Testing the 2Checkout Gateway

When connecting to a payment gateway, it is always recommended to test the gateway using a sandbox or developer account to ensure that transactions are working correctly, without having to use actual money. This document will walk you through testing with a 2Checkout Sandbox account.

Setting up your 2Checkout sandbox account

Setting up your 2Checkout sandbox account
In order to properly test 2Checkout using GiveWP’s Test Mode you first need to sign up for a 2Checkout account. You should select the plan that you prefer and then you’ll be able to get the credentials for your sandbox account. This is an environment designed to mimic a live 2checkout environment, without having to use real money/credit cards.

Once you sign up for an account, you should log in into your account. 2Checkout Login Page

Once you log in, you need to create a new role and a new user account to manage the API.

Creating a new role and user

Navigate to the top right corner and click on the tool icon and then on User management.

2checkout user management menu item

The next step is to create a new role. Click on Roles > Add role and you’ll be asked to add a new name for this role and an optional description.

Then, uncheck everything and leave only the Manage API Access checked, and click to save it.

creating new role with 2 checkout

After you save it, go back to the User Management page and click on Users > Add User. give it a name, email, first name, last name, password, and add the role you just created to it. Then, click to save it.

Getting API Keys

To get the API Keys and other information you’ll need, navigate to Integrations > Webhooks > API.

Get the API Keys information for 2checkout

Now, navigate to your site’s dashboard, click on Donations > Settings > Payment Gateways > 2Checkout Settings and add the information there:

The 2Checkout Settings page

The account number you see on GiveWP is the Merchant Code you get from 2Checkout. And the API username and API User Password are the credentials you created above.

Once that is set up, you are ready to make test donations. Ensure GiveWP is in Test Mode and using the 2Checkout test data, you can process donations without using real money, ensuring that the gateway is properly connected.

Note that these steps are necessary for testing, but once you’ve confirmed that donations are correctly processing in the sandbox, you need to switch out the keys to live keys. The process is remarkably similar in getting live keys. See the primary 2Checkout add-on documentation for more detail.
Last updated 2 years ago

Start Fundraising Better Today!

Get GiveWP Today
GiveWP Plans

Give Fundraising Newsletter

The Give Fundraising Newsletter will help you navigate the world of online fundraising like a pro. Each week we send out fundraising advice, Give LIVE announcements, and exclusive offers to our newsletter subscribers.