When you’ve ever puzzled the best way to set off personalised, automated buyer journeys in Salesforce Advertising and marketing Cloud primarily based on real-time actions from exterior programs, it’s attributable to Journey Builder API Occasions.
These highly effective instruments permit companies to create personalised advertising experiences, triggering buyer journeys primarily based on exterior information like purchases, signups, or app interactions.
On this weblog, we’ll break down all the pieces it’s essential to find out about Salesforce Advertising and marketing Cloud Journey Builder API Occasions in a easy and easy-to-understand approach.
What Are API Occasions in Journey Builder?
In Salesforce Advertising and marketing Cloud (SFMC), Journey Builder helps you create multi-step, automated buyer journeys.
API Occasions allow you to set off these journeys primarily based on information from exterior programs, akin to a CRM, web site, or e-commerce platform.
When a buyer buys a product in your website, an API Occasion can immediately add them to a journey, triggering personalised emails, messages, or different communications primarily based on their buy.

Why Use API Occasions?
Actual-time Engagement: They permit immediate buyer interplay, proper when the shopper takes an motion (like shopping for a product).
Automation: You don’t must manually add clients to journeys, making it a scalable resolution.
Personalization: API Occasions will let you go customer-specific information, which can be utilized to tailor the journey to their particular wants or conduct.
Now, let’s dive into the best way to arrange and use API Occasions in Journey Builder!
Step-by-Step Information to Utilizing API Occasions in Journey Builder:
Step 1: Outline Your Journey and Viewers
First, it’s essential to have a journey prepared in Journey Builder. Take into consideration the expertise you wish to create in your clients:
- Will the journey be triggered when a consumer makes a purchase order?
- Ought to it begin when somebody fills out a kind in your web site?
- Or will or not it’s triggered by another exterior occasion (like subscribing to a e-newsletter)?
Have a transparent aim in your journey and outline the touchpoints (emails, SMS, and many others.) that your clients will undergo.
Step 2: Set Up the Journey with an API Entry Supply
As soon as you understand how you wish to interact along with your viewers, observe these steps:
- Go to Journey Builder in Advertising and marketing Cloud.
- Click on on Create New Journey.
- Choose Multi-Step Journey.
- Below Entry Sources, choose API Occasion. (An entry supply is what triggers the journey. On this case, we’ll use an API Occasion.)
- Select API Occasion as your occasion kind.
- Select what you wish to do with the occasion like replace the contact
Step 3: Get hold of the API Endpoint and Key
- Go to the setup
- Within the fast discover field search Put in packages, click on on Put in packages.
- Click on on new
- Enter title and outline
- Click on on Add Part
- Select Part Sort API Integration
- Choose Server to Server
- Choose scope, for this instance we’ll choose
- Journey: Learn
- Record and Subscribers: Learn
- Click on on Save.
When you’ve configured the bundle, Salesforce will generate
- Consumer Id
- Consumer Secret
- Authentication Base URI
- REST Base URI
- SOAP Base URI

These can be utilized by exterior programs to set off the occasion.
Step 4. Copy the Authentication Base URI to generate the access_token
Methodology : POST
Endpoint: https://your-marketing-cloud-AuthenticationBaseURI-endpoint-url
physique :
{ "grant_type": "client_credentials", "client_id": "*******************", "client_secret": "****************" }
Step 5: Set Up the API Name in Exterior Techniques
Now that you’ve your REST Base URI and access_token, you’ll must combine this along with your exterior system.
Whether or not you’re utilizing a web site, an app, or one other CRM system, you’ll must set it as much as name this endpoint each time the occasion happens.
For instance, if you would like the journey to set off when somebody makes a purchase order:
1. When the acquisition occurs, your web site or e-commerce platform sends an HTTP POST request to the API endpoint.
2. The API name will embrace all of the required buyer information, like title, e-mail, and buy particulars.
Right here’s a pattern API name format:
Methodology: POST
Endpoint: https://your-marketing-cloud-endpoint-url
Header: “Authorization: Bearer YOUR_AUTH_KEY”,”Content material-Sort: utility/json”
Physique:
'{ "contactKey": "[email protected]", "eventDefinitionKey": "YOUR_EVENT_DEFINITION_KEY", "information": { "firstName": "John", "lastName": "Doe", "purchaseAmount": "100", "productId": "12345" } }'
Step 6: Take a look at the API Occasion
Earlier than launching the journey, it’s a good suggestion to check the API occasion to ensure all the pieces works as anticipated.
1. Use a device like Postman to simulate an API name and make sure that the journey is triggered appropriately.
2. Test Advertising and marketing Cloud to make sure the take a look at contact has been injected into the journey.
Step 8: Launch the Journey
When you’ve examined all the pieces, go forward and activate the journey. Now, any time your exterior system makes an API name, the journey will set off, and your clients can be routinely added.
Finest Practices for Utilizing API Occasions in Journey Builder
1. Validate the Information: Be certain that the info coming in out of your exterior system is clear and correctly formatted. Incorrect information could cause the journey to fail.
2. Monitor and Optimize: Use Advertising and marketing Cloud’s monitoring and reporting instruments to see how nicely your journeys carry out. Are clients partaking along with your emails or messages? Make changes as wanted.
3. Safe Your API Calls: At all times guarantee your API endpoints are safe and solely approved programs can set off the journeys. Use tokens, keys, and correct authentication strategies.
For any queries concerning Salesforce Advertising and marketing Cloud or personalised options, contact our knowledgeable Salesforce Consultants at [email protected] or by way of Stay Chat.
Our crew is offered year-round to offer custom-made options tailor-made to your enterprise wants.
When you’ve ever puzzled the best way to set off personalised, automated buyer journeys in Salesforce Advertising and marketing Cloud primarily based on real-time actions from exterior programs, it’s attributable to Journey Builder API Occasions.
These highly effective instruments permit companies to create personalised advertising experiences, triggering buyer journeys primarily based on exterior information like purchases, signups, or app interactions.
On this weblog, we’ll break down all the pieces it’s essential to find out about Salesforce Advertising and marketing Cloud Journey Builder API Occasions in a easy and easy-to-understand approach.
What Are API Occasions in Journey Builder?
In Salesforce Advertising and marketing Cloud (SFMC), Journey Builder helps you create multi-step, automated buyer journeys.
API Occasions allow you to set off these journeys primarily based on information from exterior programs, akin to a CRM, web site, or e-commerce platform.
When a buyer buys a product in your website, an API Occasion can immediately add them to a journey, triggering personalised emails, messages, or different communications primarily based on their buy.

Why Use API Occasions?
Actual-time Engagement: They permit immediate buyer interplay, proper when the shopper takes an motion (like shopping for a product).
Automation: You don’t must manually add clients to journeys, making it a scalable resolution.
Personalization: API Occasions will let you go customer-specific information, which can be utilized to tailor the journey to their particular wants or conduct.
Now, let’s dive into the best way to arrange and use API Occasions in Journey Builder!
Step-by-Step Information to Utilizing API Occasions in Journey Builder:
Step 1: Outline Your Journey and Viewers
First, it’s essential to have a journey prepared in Journey Builder. Take into consideration the expertise you wish to create in your clients:
- Will the journey be triggered when a consumer makes a purchase order?
- Ought to it begin when somebody fills out a kind in your web site?
- Or will or not it’s triggered by another exterior occasion (like subscribing to a e-newsletter)?
Have a transparent aim in your journey and outline the touchpoints (emails, SMS, and many others.) that your clients will undergo.
Step 2: Set Up the Journey with an API Entry Supply
As soon as you understand how you wish to interact along with your viewers, observe these steps:
- Go to Journey Builder in Advertising and marketing Cloud.
- Click on on Create New Journey.
- Choose Multi-Step Journey.
- Below Entry Sources, choose API Occasion. (An entry supply is what triggers the journey. On this case, we’ll use an API Occasion.)
- Select API Occasion as your occasion kind.
- Select what you wish to do with the occasion like replace the contact
Step 3: Get hold of the API Endpoint and Key
- Go to the setup
- Within the fast discover field search Put in packages, click on on Put in packages.
- Click on on new
- Enter title and outline
- Click on on Add Part
- Select Part Sort API Integration
- Choose Server to Server
- Choose scope, for this instance we’ll choose
- Journey: Learn
- Record and Subscribers: Learn
- Click on on Save.
When you’ve configured the bundle, Salesforce will generate
- Consumer Id
- Consumer Secret
- Authentication Base URI
- REST Base URI
- SOAP Base URI

These can be utilized by exterior programs to set off the occasion.
Step 4. Copy the Authentication Base URI to generate the access_token
Methodology : POST
Endpoint: https://your-marketing-cloud-AuthenticationBaseURI-endpoint-url
physique :
{ "grant_type": "client_credentials", "client_id": "*******************", "client_secret": "****************" }
Step 5: Set Up the API Name in Exterior Techniques
Now that you’ve your REST Base URI and access_token, you’ll must combine this along with your exterior system.
Whether or not you’re utilizing a web site, an app, or one other CRM system, you’ll must set it as much as name this endpoint each time the occasion happens.
For instance, if you would like the journey to set off when somebody makes a purchase order:
1. When the acquisition occurs, your web site or e-commerce platform sends an HTTP POST request to the API endpoint.
2. The API name will embrace all of the required buyer information, like title, e-mail, and buy particulars.
Right here’s a pattern API name format:
Methodology: POST
Endpoint: https://your-marketing-cloud-endpoint-url
Header: “Authorization: Bearer YOUR_AUTH_KEY”,”Content material-Sort: utility/json”
Physique:
'{ "contactKey": "[email protected]", "eventDefinitionKey": "YOUR_EVENT_DEFINITION_KEY", "information": { "firstName": "John", "lastName": "Doe", "purchaseAmount": "100", "productId": "12345" } }'
Step 6: Take a look at the API Occasion
Earlier than launching the journey, it’s a good suggestion to check the API occasion to ensure all the pieces works as anticipated.
1. Use a device like Postman to simulate an API name and make sure that the journey is triggered appropriately.
2. Test Advertising and marketing Cloud to make sure the take a look at contact has been injected into the journey.
Step 8: Launch the Journey
When you’ve examined all the pieces, go forward and activate the journey. Now, any time your exterior system makes an API name, the journey will set off, and your clients can be routinely added.
Finest Practices for Utilizing API Occasions in Journey Builder
1. Validate the Information: Be certain that the info coming in out of your exterior system is clear and correctly formatted. Incorrect information could cause the journey to fail.
2. Monitor and Optimize: Use Advertising and marketing Cloud’s monitoring and reporting instruments to see how nicely your journeys carry out. Are clients partaking along with your emails or messages? Make changes as wanted.
3. Safe Your API Calls: At all times guarantee your API endpoints are safe and solely approved programs can set off the journeys. Use tokens, keys, and correct authentication strategies.
For any queries concerning Salesforce Advertising and marketing Cloud or personalised options, contact our knowledgeable Salesforce Consultants at [email protected] or by way of Stay Chat.
Our crew is offered year-round to offer custom-made options tailor-made to your enterprise wants.