intentEvent fires before receiving actions of a popup?


  function followIntentToAnalytics (intentEvent) {
    if (!intentEvent) return;
  var label = + " (" + + ")";

twttr.ready(function (twttr) {
  // Now bind our custom intent events'click', clickEventToAnalytics);'tweet', tweetIntentToAnalytics);'retweet', retweetIntentToAnalytics);'like', likeIntentToAnalytics);'follow', followIntentToAnalytics);


<a href="" class="twitter-follow-button" data-show-count="false"  data-size="large">Follow @ravikumar_j</a>

By clicking follow button it should open a pop-up, then user will follow that user_id. Based on the status of twitter login he will follow or not thereafter.

The actions after clicking on follow button follows:

  1. A pop up will be open
  2. User may follow the intend twitter id on close the popup.
  3. User may close the popup without making any action.

As soon as 1 action(above) happens the followIntentToAnalytics(intentEvent) exits irrespective of 2&3 actions. Can you help here to model the response and action on 2&3 also?


The web intent event behavior changed on November 20 to fire at the time of interaction. We often do not have a communications bridge between the webpage or app completing the action and your webpage.


So how can we detect or know a tweet has been made? Our site, and many I know, rely on this to know what has happened, not what might happen. This move doesn’t seem to make much sense. We already had a click event so we knew when a click happened. We need to know when a tweet has happened. The “reliability” issue does not seem reasonable since its no different than any other three way communication (server/server/client). Every twitter communication needs to be checked for failure and gracefully handle that case. How is this any different? This move didn’t make anything better, it just removed a potentially useful feature that is harmless if it fails, but helpful if it succeeds (which it usually does). This seems a bad move with a very “thin” explanation that really does not hold up. Keeping the functionality with a disclaimer regarding mobile seems a smarter and more dev friendly answer. We should get this back with appropriate documentation.


thank you @niall for your information. Though it seems good but how I can figure it out the response of the action(tweet/follow/retweet or close the popup) because after the action it responding with empty object.


So since these changes can we no longer detect whether a user actually clicks the follow button in the popup window?

I have a website that offers a discount for users that follow a twitter account, this is now broken since the change as it applies the discount when a user simply clicks the follow button on the site, and not when the follow button in the popup window is clicked.

Flow that SHOULD happen:

  1. User click follow button on website
  2. Popup window opens
  3. User clicks Follow button in popup
  4. Discount applied on website
    (if user clicks unfollow, discount is removed)

Flow that happens NOW:

  1. User clicks follow button on website
  2. Popup window opens AND discount applied on website

Regardless of follow/unfollow click in popup window, discount is neither removed or applied.

Is there anyway around this?

closed #8