We are looking to connect SalesForce lead data to Meta (and possibly other networks like TikTok) via server-side tracking.
Stape offers a SalesForce app to send lead status events. It offers 3 integration methods - CAPI Gateway, Signals Gateway, and Server GTM.
We’d prefer to use Server GTM since the client already has a sGTM container configured.
What’s not clear to me is that the only app integration setup is adding our sGTM API Key. But how do the events and data from the SalesForce leads connect with the tagging we have in our Google Tag Manager server container? We have server-side tags for Meta, TikTok, Google Ads, GA4, etc - how do we configure those incoming events from SalesForce to pass to all of them? There doesn’t appear to be anything in the setup documentation about it.
CAPI Gateway and Signals Gateway Stape containers make sense, since they’re Meta-specific and could process from there. Or a server GTM endpoint.
But I don’t understand how we route events to Meta or other networks at the moment with the sGTM integration.
hey @brett the app in your case would send agnostic JSON requests to your server container, that then could be claimed by (for example) our Data Client.
The sGTM API Key that apps asks for input will just let the app know where to send it’s events.
Data Client will breakdown webhook payload into your normal Event Data that can be digested by the normal tag templates you already use. Worst case you will need to do some minimal mapping of certain parameters (for example fbp/fbc).
As a frame of reference, here’s one of our old container exports tailored to do just that. Mind you it’s a bit outdated, but should demonstrate the principle for you.
Let me know if above make sense, or perhaps you need a more elaborate description
awesome thanks Dan. Is there documentation on the parameter mapping. We have the SalesForce app configured, and the Data Client installed in our sGTM container. Want to make sure we map the parameters coming in correctly.
@brett there’s no documentation per-se, but things you need to handle explicitly are really only the wouild-be cookie parameters like fbp/fbc for Meta, _ttp/ttclid for TikTok, and gclid for Ads.
Hi Dan - thanks. Quick question - our data is coming from the SalesForce Stape app, where we have FBCLID (and the other parameters) mapped in the designated field in the app drop-down. We could just look at the event payloads, but is there any guidance or documentation on what FBCLID and those other fields look like coming in, since they’re coming from the Stape app?
hey @brett the best way would be to catch/log one of those requests and see the full payload you’re getting.
In any case, your fbclid will come in fbc root event data parameter, the value will be of an _fbc cookie generated off of your fbclid (if it was pure click_id, if you stored the entire cookie value - it will be untouched).
Hi @Dan - for testing this - what’s the best way to go about it?
We have the Stape app installed in SalesForce, the Stape sGTM container API key added, and the fields mapped.
We have the Stape Data Client setup in sGTM.
We want to run some test events in SalesForce to make sure they come through to the sGTM container. Do we just put sGTM in preview mode to see the event data come through?
Got it - we’ll configure the preview header. Is there any customization needed for the Data Client in regard to accepted paths, etc, with the data coming from the Stape SalesForce app?
@Dan we’re struggling to get this working for a client, and need to get it in place ASAP.
We setup a designated Stape sGTM container and GTM server container pair for testing, installed the Data Client in the GTM server container and published, enabled the sGTM Preview header config in Stape, and initiated GTM server preview and added that manual value to the header config and saved. Then added the test Stape sGTM API Key to the SalesForce app.
When a lead was created in SalesForce, nothing same through in GTM preview.
2 questions:
In the Stape SalesForce app it mentions “Opportunity” stages under the event mapping, but then the mapped statuses are for Leads. Wanted to confirm, since those are separate sections in SalesForce.
2). Is there any specific config of the Data Client that needs to happen in the GTM server container to receive the data? Accepted path, etc.?
Can we pay for some quick, hands-on support with this? We’ve configured everything based on the documentation and specs and it’s not working currently.
Leads vs Opportunities : the app is designed to work with Lead statuses. So when you’re mapping stages to conversion events in the app, those correspond to your Salesforce Lead Status values. That’s the correct setup.
Data Client configuration : for the Salesforce app integration, the Data Client does not require any custom accepted path. A default Data Client setup will claim the incoming requests from the app. No special configuration needed beyond importing the template and creating the client.
As Dan mentioned, the app sends agnostic JSON requests to your server container, which the Data Client claims and breaks down into standard Event Data. From there, your existing platform tags (Meta CAPI, TikTok, Google Ads, etc.) can fire on those events. The main thing you’ll need to handle is creating Event Data variables for the cookie-based parameters — since these come through the CRM payload rather than browser cookies, you’ll want to map them explicitly in your tag configurations.
One more thing worth mentioning, the Stape Salesforce app includes a limited free trial period, and given the timeline of this thread, the trial may have expired by now, which could explain why nothing came through in GTM preview. If you’d like to learn more about the subscription terms for the Stape Salesforce app, we can get you in touch with our team.
We have the Stape SalesForce app installed in our SalesForce instance
We added the Stape sGTM container API key to the app setting
We mapped the SalesForce data and events accordingly in the Stape app
We have a GTM server container connected to that Stape sGTM container
We installed the Data Client and have it in the default configuration
So if all those things are in place - we should see requests coming through? We’ll check the free trial/subscription element.
If all of the above is true and don’t see requests arriving, what should we do as a next step? No problem mapping the event data as soon as we receive the requests
given the timing of this discussion, I’d say you are probably out of your trial which is 1 day by default and that is only plausible reason (bugs aside) for you not seeing any requests.
Like @Faris_A suggested, we can connect you with sales on the matter. Salesforce is one platform were we couldn’t keep the integration free.
Dan - one question on event data. In the Stape SalesForce app - we see mapping for user/lead data, and the mapping of the SalesForce stages to the events.
Is it possible to pass value (like $ value) to sGTM with the app? If it’s part of the SalesForce record does it get sent automatically?
At the moment you can only send it as one of the fields that app support i.e. use something like postal code and feed it the needed field for value.
Value is not yet supported, but since Meta allowed value optimisation for Leads, I think it’s a good idea to add it, which I’ll backlog. Thx for flagging!
Would the event parameters for those values coming from SalesForce be “value” and “currency”? Just trying to avoid having to retest and re-visit the parameter mapping - if those are the parameter names/labels we can just map them in sGTM
@brett yes, value and currency as separate keys in root of the payload. You need to pick them (assign the fields to grab value from) app-side and then if needed map on sGTM (most tag will digest those automatically though)