Testing live transactions in your Sandbox is not considered best practice. Chargent does, however, allow you to test live transactions in your Sandbox prior to implementing Chargent in Production if required.
As a security precaution, when running in Sandbox, all Chargent Payment Gateway records are designed to send transactions to the test payment gateways, regardless of whether you set them up as test or live. The Test Endpoint checkbox field is effectively disabled, so transactions are always sent to a test endpoint whether it is checked or not.
If you wish to send live transactions from a Salesforce Sandbox as a final step in testing, simply use Chargent’s Endpoint Override field on the Gateway record, and enter the production endpoint of your chosen gateway.
Keep in mind, the full endpoint URL must be entered in the Endpoint Override field, and the domain must be present in the Remote Site Settings (for standard Chargent integrations it will already be present).
The production endpoint URL for your gateway can be found in your gateway’s Setup Guide.
Note: If you are using a Full or Partial copy sandbox, your data, batches, and gateways (including any value in Endpoint Override field) will be copied from your Production org. Ensure you disable the Recurring Billing Batch to make sure no accidental live transactions are processed.
How to Test Live Transactions in a Salesforce Sandbox
Create a new Gateway in your Sandbox using your live login credentials and add the Endpoint Override URL to the Endpoint Override field.
- Click the App Launcher and select the Chargent App
- Click the Gateways tab
- Click New
- Walk through the steps to set up a new gateway using your live gateway credentials
- In Sandbox, you will not have the option to choose between live or test
- Add the correct URL in the Endpoint Override field.
- You can find the correct Endpoint Override URL in your gateway’s Setup Guide.
Update the new Gateway record, setting the Test Endpoint checkbox to unchecked.
- After creating the new gateway, revisit the Gateways tab
- Click your new gateway record
- Click Edit
- Click Advanced Settings
- Uncheck the Test Endpoint checkbox
- Click Save
Test your Live Transactions in a Sandbox:
- Use your own credit card or a company credit card
- Charge a small amount, such as $1 or $5
- Go to the created Transaction record
- Click Void
Notes:
- If voided the same day, the transaction will not settle and should not appear on your statement or deduct funds from your account. For more information about Voids, visit Refunds & Voids.
- Live transactions will incur per-transaction fees (typically 10 to 30 cents/transaction).
- The process differs slightly when using the Authorize.net gateway. For more information, see Authorize.net: Testing Live Transactions in a Salesforce Sandbox.