Explained in 60 Seconds: Integrating Twitter Lead Gen Cards Into Salesforce

August 04, 2015

Over the years, Twitter has expanded its role as a medium between businesses and potential clients. Many businesses use Twitter’s advertising platform as a way of promoting content from their website with the hopes of generating leads. However, many marketers are not taking advantage of one of the cool features included in it: Lead Generation Cards. These cards skip the process of users going to your site and filling out a lead generation form, but instead bring up a simple form right on Twitter. Once a user fills out the form, the individual gains access to your content and the business receives his or her’s twitter handle, name, and email address through Salesforce. In order for your company to start generating these quick and easy leads, here are a few steps you must complete to integrate Salesforce and Twitter.


1.) Login to the Salesforce account that you want to receive information from Twitter.
2.) Under your account name, click Setup.
3.) On the left hand side of the page, navigate the toolbar to Customize => Leads => Web-to-Lead.

4.) Make sure Web-to-Lead is enabled and click on the Create Web-to-Lead Form button.

5.) Once you click this button, you will be directed to a page that allows you to choose which fields to input Twitter’s information from. Since this is limited to what information Twitter sends over, check off Lead Source, Email, Last Name, and Twitter Handle (this may be a custom field that you have to make).

6.) Click on the Generate button.
7.) The result that you see is the HTML that you would need to create a Web-to-Lead form. However, we will not be using this code for those purposes. Instead, we will use it as a reference when we need some of the information later on.


1.) Login to the Twitter account that will be using the Lead Gen Cards.
2.) Under Twitter Ads, navigate to Creatives => Cards.
3.) Click on Create Lead Generation Card.

4.) Fill out the content in the first part of the form. It will ask for a short description, image, call to action, your website’s privacy policy, and a Fallback URL (this is where users will be redirected if they are viewing the card from a third-party platform).

5.) The next category is your Destination URL settings. This is where users will be directed once they fill out the lead generation card.
6.) The next category, Data settings, is where the HTML from Salesforce will come in handy. The first thing they ask for is the Submit URL. In the HTML, look for the code that says “form action=”. This is ours, and probably yours too:
7.) For the HTTP Method choose “Post”.

8.) Next we have to fill in the custom key names for the fields we choose in Salesforce. Looking back at your HTML, look at the id identifier for each of the fields listed in Twitter. For example, the id identifier for last name is “last_name”. Fill these in for Name, Email, and Screenname.

9.) There may be hidden custom fields that your Salesforce requires in order for full integration to work. In your HTML code, look for anything that says “input type=hidden” and note their values. If there are any, add them to the list by clicking on Add Hidden Field in Twitter and inputting their values.
10.) After you name your card and hit submit, Twitter will run a test to make sure the lead information goes through. If it does, you’re ready to go!

Add to Flipboard Magazine.

Related Reading

a hand touching a phone with social media icons leaping out of the phone like whisps of water vapor
Measuring Social Media Success in Higher Education

What’s considered a “success” in social media? 

a hashtag drawn in sand
Social Media Feeds: Do They Belong on Your Higher Ed Site?

“We should put our social media accounts on our website!”

How to Run a Successful and Safe Student Social Media Takeover

In a quest to connect and engage with prospective students, college and university marketing teams are turning to student social media takeovers of official social media accounts.

UX Folks We Follow On Twitter (and You Should Too)

Here at OHO Interactive we love everything about UX, but we know that we’re not the only ones.