TIBCO Scribe® Online Connector For Twitter

Use the TIBCO Scribe® Online Connector for Twitter to extract data from Twitter and use it in a different datastore or external system by querying and filtering tweets for specific hashtags, keywords, or handles. The Twitter Connector can only be used to retrieve Source data, but cannot integrate data back into the Twitter database.

Possible use cases for data extracted using the Twitter Connector include: 

Connector Specifications

Supports version 1.1 of the Twitter REST API.

  Supported

Agent Types

Connect on-premise X
Connect cloud X

Data Replication Apps

Source X
Target  

On Schedule Apps

Source  
Target  

On Event Apps

Source  
Target  

Flows

Integration X
Request-Reply  
Message  
Note: This Connector is available from the TIBCO Cloud™ Integration Marketplace. See Marketplace Connectors for more information.

Supported Entities

The Twitter Connector supports the following entities. Select a linked entity name for additional information when using that entity in TIBCO Cloud™ Integration - Connect.

Entity Query Create Update Delete Upsert

Place

X

 

 

 

 

Status

X

 

 

 

 

User

X

 

 

 

 

Setup Considerations

To use the Twitter Connector you need a Twitter User account.

Selecting An Agent Type For Twitter

Refer to TIBCO Cloud™ Integration - Connect Agents for information on available agent types and how to select the best agent for your app.

API Usage Limits

Twitter limits the number of API calls in a sliding 15 minute window for the user communicating with its API. Users that exceed those limits may be blacklisted and will not be able to access the Twitter API. TIBCO Cloud™ Integration - Connect monitors API usage to prevent you from exceeding the API limit. TIBCO Cloud™ Integration - Connect tracks the number of remaining API calls in the current 15 minute window and stops the query before the limit is exceeded.

If you are running an app and it is close to exceeding the API usage limits, the app stops running and TIBCO Cloud™ Integration - Connect generates the following error message:

API limit reached for method <name of entity>
Where <name of entity> is the name of the metadata entity being queried when the maximum was reached.

Note: To prevent you from exceeding your API limits, TIBCO Cloud™ Integration - Connect restricts the number of API calls used in the Preview option for a Query. This may result in the Preview option being blank where an actual query would return results.
Note: Refreshing metadata for the Connector consumes API calls.

Refer to the Twitter documentation for additional information on per user usage limits. See API Rate Limits.

Managing API Limits

Twitter API rate limits can cause TIBCO Cloud™ Integration - Connect apps to fail depending on the number of records requested. Below are some options to help you work within these limits.

Connecting To Twitter

Note: Best practice is to create Connections with credentials that limit permissions in the target system, following the principle of least privilege. Using Administrator level credentials in a Connection provides Administrator level access to the target system for TIBCO Cloud™ Integration - Connect users. Depending on the entities supported, a TIBCO Cloud™ Integration - Connect user could alter user accounts in the target system.
  1. Select Connections from the menu.
  2. From the Connections page select Create to open the Create a connection dialog.
  3. Select the Connector from the list to open the Connection dialog, and then enter the following information for this Connection:
    • Name — This can be any meaningful name, up to 25 characters.
    • Alias — An alias for this Connection name. The alias is generated from the Connection name, and can be up to 25 characters. The Connection alias can include letters, numbers, and underscores. Spaces and special characters are not accepted. You can change the alias. For more information, see Connection Alias.
  4. Select Authenticate to open the Twitter authorization page:
    • If you are not already logged into Twitter, the Twitter login page displays. Enter your email address and password, and select Log in.
    • If this is the first time you are creating a Twitter connection, the Twitter Authorization page displays. Click Authorize to allow Twitter to use the data specified.

      A page with the following message displays:

    • Click Close, return to the TIBCO Cloud™ Integration - Connect page, and then select Test to ensure that the agent can connect to Twitter. Be sure to test the connection against all agents that use this connection. See Testing Connections.
    • Tip: Do not test the Connection until the message at the top of the Connection dialog reads Authentication complete. Note that it may take a few minutes for this message to display.
  5. If you are using Replication Services, enter filter information in the RS Filter field. This field is required.
  6. In the Sentiment Scoring Values table select Add to enter a specific word or phrase and either a positive or negative number. Maximum of 50 entries. This field is optional. See Sentiment Scoring Values for additional information.
  7. Select OK/Save to save the Connection.

Sentiment Scoring Values

Use the Sentiment Scoring Values table in the TIBCO Cloud™ Integration - Connect Manage Connections dialog for Twitter to search tweets for keywords or phrases and give each occurrence a positive or negative score. The cumulative sentiment score indicates whether the tweet is negative or positive, which helps you determine how to act on that tweet. The score given to each keyword is user specified and should be based on your own calculation for what constitutes a negative or positive total score.

TIBCO Cloud™ Integration - Connect uses the data in the sentiment filter as follows: 

Scores are cumulative and are stored in the target datastore in the sentiment field. For example, if you have entered good with a score of 100 and bad with a score of -25, a tweet of this phrase, "He is neither good nor bad.", generates a sentiment score of 75 or 100 + (-25)= 75.

Sentiment Scoring Values can be used with both Data replication and On schedule apps. If the Sentiment Scoring Values table is populated, a sentiment score is always generated for tweets that match the criteria. Create additional Twitter Connections to store different sets of sentiments or to remove all sentiments for instances when you do not want any sentiment scores.

Metadata Notes

Consider the following for Twitter data fields and entity types.

Naming

Connection metadata must have unique entity, relationship, and field names. If your Connection metadata has duplicate names, review the source system to determine if the duplicates can be renamed.

Entity Types

Twitter entities, as used in TIBCO Cloud™ Integration - Connect, are classified as either main entities or sublists.

Twitter Connector As A Data Replication App Source

Consider the following when using the Twitter Connector as Data replication app source.

Twitter Connector As An App Source

Consider the following when using the Twitter Connector as an App source.

Filter, Match Criteria, Or Lookup

Notes On Standard Entities

Place

Placeattribute

Status

Contributor

Media

User

TIBCO Cloud™ Integration - Connect API Considerations

Note: Connectors using OAuth for authentication are not fully supported by the TIBCO Cloud™ Integration - Connect API at this time.

More Information

For additional information on this Connector, refer to the Knowledge Base and Discussions in the TIBCO Community.