- 25 Sep 2023
- 6 Minutes to read
- Print
- DarkLight
Payment Gateway
- Updated on 25 Sep 2023
- 6 Minutes to read
- Print
- DarkLight
- Field Name:
TouchNet uPay Site ID
- API Name: bt_stripe__TouchNet_uPay_Site_ID__c
- Data Type: Text(15)
- Field Name:
TouchNet uPay Site URL
- API Name: bt_stripe__TouchNet_uPay_Site_URL__c
- Text(255)
In Blackthorn Payments, a Payment Gateway record is synonymous with a gateway (i.e. Stripe, Authorize.net etc.) account. Each Payment Gateway record you create connects your Salesforce org to one gateway account, in either test or live mode. To have your gateway account in both test and live mode, create two Payment Gateway records. There is no limit on the number of Payment Gateway accounts you can connect to your org.
Do not change your Payment Gateway record from test mode to live mode or vice versa by clicking Connect to Gateway or checking/unchecking the Test Mode
checkbox. Instead, create a new record for the other mode you wish to enable.
Supported Payment Gateway Providers
Blackthorn supports several Payment Gateway providers. The primary Payment Gateway providers are Stripe, Authorize.net, and Spreedly. Blackthorn also supports the providers below via one of the primary providers.
Stripe
* Apple Pay
* Google Pay
* Alipay
* Bacs Direct Debit
* Bancontact
* EPS
* Giropay
* iDEAL
* Plaid (must be set up in Stripe)
* SEPA Direct Debit
* SOFORT
Cybersource
- via Spreedly - fully tested
Spreedly
The following Spreedly processors are used by Blackthorn customers.
- Braintree
- Cardconnect
- Elavon
- eWAY
- Fat Zebra
- Litle
- Orbital
- Payflow Pro
- Paypal
- Sage
Events and Storefront Checkout
Blackthorn also supports two Payment Gateway providers that only work with Events Checkout and Storefront Checkout.
- TouchNet
- CashNet
First Payment Gateway Record
Your first Payment Gateway record, named "primary" was created automatically during the Setup Wizard.
- Navigate to the Payment Gateway object.
Lightning/Classic: Payments (Admin) App > Click the "Payment Gateways" Tab
- Select All from the list of List Views.
- Click on the record named "primary".
If you connected to your gateway account in test mode, the Test Mode field will be checked
The Default field is checked.
Objects with a Payment Gateway lookup field (such as Transaction and Payment Method) will default to the Payment Gateway record marked "Default" if the field is left blank on save.The Gateway Information section provides all the connection details.
If these fields are blank, data in Salesforce will not process in the gateway. Do not copy your Stripe API keys and insert them here as these keys are different than your Stripe keys (they are OAuth keys). You can only get them by clicking the Connect to Gateway button.
Create Payment Gateway Records (for Stripe)
Create a Payment Gateway for Stripe
Each Stripe account mode (test and live) needs its own Payment Gateway record. This is to ensure that your data is separated from "Live" and "Test".
For example, if you connected to your account in Test Mode during setup, create a new Stripe Payment Gateway record for live mode.
- Navigate to the Payment Gateway object.
Lightning/Classic: Payments (Admin) App > Click the "Payment Gateways" Tab
- Click New.
- Populate the following fields:
- Payment Gateway Name = Name for this record
- Webhook Label = Name for the webhook URL
This is needed to configure webhooks. - Default= Check this field if you want this as your default Payment Gateway.
If you have multiple Stripe Payment Gateway accounts, you can change which one should default. - Test Mode = Check this field if you are connecting to the test mode in your Stripe account.
- Click Save.
- Click the Connect to Gateway button.
- Enter your Stripe Credentials.
Once you sign in, all fields under the "Gateway Information" section in the Payment Gateway record will be filled out.
There will be no data in the Related Lists section. Connecting to your Stripe Account does not automatically sync existing data over into Salesforce. If you have data in your Stripe Account that needs to come over into Salesforce, see our Historical Sync documentation.
Available and Pending Balances
There are several fields and a button on the Payment Gateway object to track your available and pending balances for both Salesforce and Stripe. Having both balances allows you to compare your Stripe and Salesforce balances.
Stripe
Stripe Balance Available and Stripe Balance Pending
These fields are updated via the Stripe's Balance.Available or Account.Updated Webhook Events.
Stripe Balance Last Updated
This is a date and time field that is updated when the balances are updated, giving you an insight as to when the two balances were last updated.
Held in Reserve
This field shows the funds held from your account due to negative balances on Connected Accounts. This field is automatically updated from Stripe through a webhook.
Salesforce
Calculate Salesforce Balances From
This field is for calculating historical transactions that were processed through Stripe before the balance fields were packaged.
Salesforce Balance Available and Salesforce Balance Pending
These fields are automatically calculated based on related Transactions.
- If the related Transaction's Balance Status = "Available", then the Retained Net Amount is rolled up to the Salesforce Balance Available.
- If the Transaction's Balance Status is "Pending" then the Retained Net Amount is rolled up to the Salesforce Balance Pending.
Stripe Balance Last Updated
This is a date and time field that is updated when the balances are updated.
Balance(s) Incorrect
When this field is checked, it means the Stripe Balance Available and Stripe Balance Pending and Salesforce Balance Available and Salesforce Balance Pending do not match. Often, they won't match based upon timing of the Stripe webhook and the Salesforce batch process running.
Update Balance button
There is a daily apex job that runs and updates the Salesforce and Stripe available and pending balances. Clicking this button forces the job to run immediately.
If you have a high Transaction volume, don't click the Update Balance button. You will run into a query limit error.
Scheduled Apex Job
There is Scheduled Job called, Blackthorn | Payments Balance Update that runs daily. This job updates the Stripe Balance Available and Stripe Balance Pending and Salesforce Balance Available and Salesforce Balance Pending fields on the Payment Gateway record(s).
- Navigate to Setup.
- In the Quick Find/Search, type in and click Scheduled Jobs.
Block Amex Payment Methods
Some providers like Stripe charge higher fees for using the American Express Payment Method. In order to help customers mitigate these extra fees we've provided a field on the Payment Gateway object to block Transactions from the REST API that are attempting to charge a payment with an American Express card. This field is labeled Block Amex Transactions In Rest API and can be used with:
- PayLink
- DocumentLink
- REST API requests (custom front-end code)
Don't forget to add this field to your Payment Gateway page layout if you would like to use it.
Here is an example of what a customer will see if the Block Amex Transactions In Rest API checkbox = "True":
Payment Gateway Owner - Known Limitation
If you have configured a Sharing Rule for the Payment Gateway object, there is a known limitation in Salesforce if the Payment Gateway owner is listed as "Automated Process User". If your Payment Gateway Owner field is displaying the value "Automated Process User" you may notice that Sharing Rules are not being applied. The work around for this is to update the Owner field to reflect another user in your org such as the System Administrator. Read more about this here.
Troubleshooting
If you have received an error with your Payment Gateway or have a question, please view our Troubleshooting page.