Skip to main content

Examine an Integration Use Case

Learning Objectives

After completing this unit, you’ll be able to:

  • Describe the challenge of keeping customer data in Stripe in sync with Salesforce.
  • Explain how to use MuleSoft Composer to sync customer data in Stripe with Salesforce.
  • Prepare to create a flow.

Before You Start

This module builds on MuleSoft Composer Installation and Configuration, so make sure you've completed it before you continue. Recall from that module, you need to have the MuleSoft Composer User permission set if you want to build and run integration flows.

In this module, we assume you’re an authorized MuleSoft Composer user. If you’re not a MuleSoft Composer user, that’s OK. Read along to learn how they perform the steps. Don’t try to follow the steps in a Trailhead Playground, because MuleSoft Composer isn't available in the Trailhead Playground.


To learn about MuleSoft Composer’s integration features, flow components, and flow creation tasks, take MuleSoft Composer Basics.

In this unit, you step into the role of admin for Northern Trail Outfitters (NTO), an outdoor and recreational gear retailer. First, you examine an integration challenge faced by NTO, and then you learn about a MuleSoft Composer integration solution. Finally, you learn how to prepare to create your flow.

Integration Challenge

Let’s take a look at an integration challenge NTO is facing. Your sales team at NTO creates and maintains customers and credit card payments in Stripe. The team also manages and maintains accounts in the NTO org’s Sales Cloud. For best visibility into NTO’s customer base, the team needs to keep the customer data in Stripe in sync with the account data in Sales Cloud.

Currently, the sales team is performing these tasks manually. Every time a customer makes a payment using a credit card, the team creates a charge in Stripe. Then, the team creates an account for the customer associated with the charge in Sales Cloud, if the account doesn’t exist. Also, there’s a significant time lag between when the charge is entered into Stripe and when the account for the customer associated with the charge is created in Sales Cloud. This process is time-consuming and highly error-prone, so the team wants to automate it.

Integration Solution

As a solution, you need to automate the data sync between Stripe and Sales Cloud in order to achieve near real-time integration. To do this, you use MuleSoft Composer to create an integration flow that automatically syncs customers in Stripe with accounts in Sales Cloud. Specifically, the flow must perform the following tasks.

  1. Find any new charge in Stripe.
  2. Find the customer associated with the charge in Stripe.
  3. Determine if an account associated with the Stripe customer exists in Sales Cloud.
  4. If the account doesn’t exist, create an account in Sales Cloud.

To implement the solution using MuleSoft Composer, you need to perform these flow creation tasks.

  • Prepare to create a flow.
  • Design and test a flow.
  • Activate a flow.
  • Monitor and troubleshoot a flow.

You learn how to perform these tasks in the rest of this module.

Prepare to Create a Flow

Ready to get started?

First, you need to gather all required information about the systems and assets your flow is going to use. The following table describes the systems the flow needs to connect to and the information you need to have for those systems.

As a best practice, ensure the NTO org has a sandbox org you can connect to when you design and test your flows. 

Required Information


  • Email and password with appropriate permissions to a Stripe account
  • API (application programming interface) keys for test and live modes

NTO’s Sales Cloud

  • URLs of the NTO sandbox and production orgs
  • Username and password with appropriate permissions to the NTO orgs

Next, let’s find out your secret API key for a Stripe connection in test mode.

MuleSoft Composer interacts with Stripe by sending and receiving API requests. The Stripe API authenticates MuleSoft Composer’s API requests using your Stripe account’s secret API key. 

Every Stripe account has two secret API keys, one for testing transactions (test mode) and the other for running live transactions (live mode). All API requests are made in either test mode or live mode. Objects such as payments, customers, plans, and coupons in the test mode can’t be manipulated by objects in the live mode and vice versa.

As a best practice, when you create flows to integrate with Stripe using MuleSoft Composer, you first use a test mode secret API key to test transactions. Test mode secret API keys have the prefix sk_test_.

After you’ve successfully tested your flow, you use a live mode secret API key to run live transactions. Live mode secret API keys have the prefix sk_live_. For more information on managing Stripe API keys, see API keys.

When you create a test mode connection to Stripe using MuleSoft Composer, you must specify a secret API key. Follow these steps to find a test mode secret API key in Stripe.

  1. Log in to your Stripe account using your email and password.
  2. Click Viewing test data.
  3. Click API keys.
  4. Click Reveal test key.
  5. Copy and paste the test key into a text file of your choice.

You’ve taken the first steps to prepare to create your flow with MuleSoft Composer. In the next unit, you learn how to design and test your flow.


Keep learning for
Sign up for an account to continue.
What’s in it for you?
  • Get personalized recommendations for your career goals
  • Practice your skills with hands-on challenges and quizzes
  • Track and share your progress with employers
  • Connect to mentorship and career opportunities