Stripe for Salesforce Platform Configuration
Switch Stripe account authentication from OAuth to API key
As of version 1.17 of the Stripe for Salesforce Platform, we no longer offer OAuth-based authentication. To migrate your Stripe account from OAuth to use an API key, follow these steps:
From the Salesforce Setup tab, go to App Launcher > Stripe for Salesforce Platform.
In Account Management, click on the Stripe account you want to migrate.
Click Reauthorize using API key.
Input the Stripe API Key for this account, ensuring that the API key is for the right mode (live or test). Click Save.
Work with Sandboxes and environment clones
When creating a sandbox or copying production data, ensure the Stripe for Salesforce Platform omits select data from the clone. Don’t copy connections and configurations from production or other environments. Use sandbox templates that don’t include any stripeGC
objects.
Configure the Stripe for Salesforce Platform independently on each Salesforce Org and run the setup process on each Salesforce Org.
Remove data copied to a clone
When you copy data from the StripeGC objects to a new Salesforce Org, remove the data by running an Anonymous Apex
script to delete it:
delete [SELECT Id FROM stripeGC__Setup_Data__c]; delete [SELECT Id FROM stripeGC__Stripe_Account__c]; delete [SELECT Id FROM stripeGC__Stripe_Event__c]; delete [SELECT Id FROM stripeGC__Stripe_Webhook_Endpoint__c]; delete [SELECT Id FROM stripeGC__Sync_Log__c];
Default Events excluded from recursion detection
Stripe’s Salesforce Platform has checks to prevent actions from getting stuck in a loop. A logical loop might happen when a set of resources constantly detects and responds to updates from another set. For example, suppose you have one flow that listens to Stripe’s customer.
events and updates a Salesforce Account
. Meanwhile, you have another flow that detects updates to the Salesforce Account
and updates a Stripe customer. This setup leads to a recurring loop, which would continue indefinitely.
charge.captured | charge.expired | charge.failed |
charge.pending | charge.refunded | charge.succeeded |
charge.updated | credit_note.created | credit_note.updated |
credit_note.voided | invoice.created | invoice.deleted |
invoice.finalization_failed | Invoice.finalized | invoice.marked_uncollectible |
invoice.paid | invoice.payment_action_required | invoice.payment_failed |
invoice.payment_succeeded | invoice.sent | invoice.upcoming |
invoice.updated | invoice.voided | invoiceitem.created |
invoiceitem.deleted | invoiceitem.updated | issuing_card.created |
issuing_card.updated | issuing_cardholder.created | issuing_cardholder.updated |
issuing_dispute.closed | issuing_dispute.created | issuing_dispute.funds_reinstated |
issuing_dispute.submitted | issuing_dispute.updated | issuing_transaction.created |
issuing_transaction.updated | mandate.updated | order.created |
order.payment_failed | order.payment_succeeded | order.updated |
payment_intent.amount_capturable_updated | payment_intent.canceled | payment_intent.created |
payment_intent.partially_funded | payment_intent.payment_failed | payment_intent.processing |
payment_intent.requires_action | payment_intent.succeeded | payment_link.created |
payment_link.updated | payment_method.attached | payment_method.automatically_updated |
payment_method.detached | payment_method.updated | payout.canceled |
payout.created | payout.failed | payout.paid |
payout.updated | quote.accepted | quote.canceled |
quote.created | quote.finalized | setup_intent.canceled |
setup_intent.created | setup_intent.requires_action | setup_intent.setup_failed |
setup_intent.succeeded | customer.source.created | customer.source.deleted |
customer.source.expiring | customer.source.updated | source.canceled |
source.chargeable | source.failed | source.mandate_notification |
source.refund_attributes_required |
Recursion detection configuration
You can include and exclude specific events from recursion detection. If you’re an admin, you can modify these events in your settings by configuring recursion detection.
The Recursion Detection Configuration can be accessed by following these steps:
- Navigate to Setup > Custom Code > Custom Metadata Types.
- Under Recursion Detection Configuration, click Manage Records.
- Next to Default, click Edit.
Within this configuration, an admin can add either Included Events or Excluded Events.
Configure sync preferences
- To configure Sync Preferences, launch the Stripe Connector for Salesforce App wizard, navigate to App Launcher > Stripe Universal Connector for Salesforce
- Click the Sync Preferences button.
- Enable or disable Enable Stripe Event Data Cleanup.
- Modify the Maximum Stripe Event Records Retained (Count).
- Enable or disable Sync Log Records.
- Modify the Maximum Sync Log Records Retained (Count).