How to embed tweet feed or list of followers, as non-account holder


#1

I want the equivalent of Google+ Badge https://developers.google.com/+/web/badge/ or Facebook Like Box https://developers.facebook.com/docs/plugins/like-box-for-pages … I have a website where many users would like to share their twitter followers, or maybe recent tweets, along with the Facebook and Google info. Both Facebook and Google allow this to be done easily by having the user enter their Facebook or Google company page URL. Can this be done with Twitter? If not, why not?


#2

Hi @abrambailey, what you describe is offered by the follow button, however users do not see the followers or recent tweets until the button is clicked.

https://dev.twitter.com/docs/follow-button

If you want to display recent tweets up front, you could use an embedded timeline along with the follow button.

https://dev.twitter.com/docs/embedded-timelines

As to “why” we don’t have specifically what you are asking for, I don’t have an answer. This could be a great new widget to complement out existing set, so we’ll take this feedback into consideration. Thanks!


#3

The widget ID populated by Twitter’s widget generator tools stores options a specific Twitter account has chosen and may edit on Twitter.com without editing the source of the webpage. You may override widget values inside the markup you publish on your pages. The Overriding Timeline Selection section of the Embedded Timeline docs details some of your choices.
https://dev.twitter.com/docs/embedded-timelines#timeline-selection

You might accept a Twitter URL as input, strip to just the path, and verify / normalize the screen name through the users/show REST API. You can also use a Sign In with Twitter OAuth flow to capture information about the authenticating user.
https://dev.twitter.com/docs/api/1.1/get/users/show

Tweets by @twitterdev

The HTML code above would store common widget options in the widget ID associated with a single account. Your site would store a Twitter account’s screenname to build the anchor element to be interpreted by Twitter’s widget.js.


#4