Siddhi-io-twitter

The siddhi-io-twitter extension is an extension to Siddhi which is used to publish event data from Twitter App. It supports key-value map format.

Prerequisites

  • Go to the https://apps.twitter.com/ and create new App
  • Select the app created in step 1 and go to"permission" tab and select "read&write" permission.
  • Go to the "keys and access tokens" tab and generate new access token
  • Collect following value from "keys and access tokens tab"
  • Consumer key
  • Consumer Secret
  • Access Token
  • Access Token Secret
  • Update the parameter values for the extension with these values.

Find some useful links below:

Latest API Docs

Latest API Docs is 1.0.5.

How to use

Using the extension in WSO2 Stream Processor

  • You can use this extension in the latest WSO2 Stream Processor that is a part of WSO2 Analytics offering, with editor, debugger and simulation support.

  • This extension is shipped by default with WSO2 Stream Processor, if you wish to use an alternative version of this extension you can replace the component jar that can be found in the <STREAM_PROCESSOR_HOME>/lib directory.

Using the extension as a java library

  • This extension can be added as a maven dependency along with other Siddhi dependencies to your project.
     <dependency>
        <groupId>org.wso2.extension.siddhi.io.twitter</groupId>
        <artifactId>siddhi-io-twitter</artifactId>
        <version>x.x.x</version>
     </dependency>

Jenkins Build Status


Branch Build Status
master Build Status

Features

  • twitter ((Source))

    The twitter source receives the events from a twitter App. The events will be received in a key-value map.

    Key values of the map of a tweet and their descriptions.
        1. createdAt - UTC time when this Tweet was created.
        2. tweetId - The integer representation of the unique identifier for this Tweet.
        3. text - The actual UTF-8 text of the status update.
        4. user.createdAt - The UTC datetime that the user account was created on Twitter.
        5. user.id - The integer representation of the unique identifier for this User.
        6. user.screenName - The screen name, that this user identifies themselves with.
        7. user.name - The name of the user, as they've defined it.
        8. user.mail - The mail.id of the user.
        9. user.location - Nullable. The user-defined location for this account's profile.
        10. hashtags - Represents hashtags which have been parsed out of the Tweet.
        11. userMentions - Represents other Twitter users mentioned in the text of the Tweet.
        12. mediaUrls - Represents media elements uploaded with the Tweet.
        13. urls - Represents URLs included in the text of a Tweet.
        14. language - The language inwhich tweep tweeted.
        15. source - Utility used to post the Tweet, as an HTML-formatted string
        16. isRetweet - Indicates whether this is a Retweeted Tweet.
        17. retweetCount - Number of times this Tweet has been retweeted.
        18. favouriteCount = Nullable. Indicates approximately how many times this Tweet has been liked by Twitter users.
        19. geoLocation - Nullable. Represents the geographic location of this Tweet as reported by the user or client application.
        20. quotedStatusId - This field only surfaces when the Tweet is a quote Tweet. This field contains the integer value Tweet ID of the quoted Tweet.
        21. in.reply.to.status.id - Nullable. If the represented Tweet is a reply, this field will contain the integer representation of the original Tweet's ID.
        22. place.id - ID representing this place. This is represented as a string, not an integer.
        23. place.name - Short human-readable representation of the place's name.
        24. place.fullName - Full human-readable representation of the place's name.
        25. place.country_code - Shortened country code representing the country containing this place.
        26. place.country - Name of the country containing this place.
        

How to Contribute

Contact us

Support

  • We are committed to ensuring support for this extension in production. Our unique approach ensures that all support leverages our open development methodology and is provided by the very same engineers who build the technology.

  • For more details and to take advantage of this unique opportunity contact us via http://wso2.com/support/.