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?
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.
If you want to display recent tweets up front, you could use an embedded timeline along with the follow button.
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!
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.
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.
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.