Query

On this page

Snap type:

Read


Description:

This Snap executes a Twitter API query and returns the results as documents. The output is in JSON.

For more information, see the Twitter API here. If you are unfamiliar with using an API, see the topic "Using the Twitter Search API" for some common search operators.

  • Expected upstream Snaps:  File reader followed by any file parser.
  • Expected downstream Snaps:  A JSON Formatter followed by File Writer.
  • Expected input:  Twitter query and Maximum tweets should be given. Until date can be given in order to search until it.
  • Expected output Gets Tweet data.


Prerequisites:

[None]


Support and limitations:Works in Ultra Task Pipelines.
Account: 

This Snap uses account references created on the Accounts page of SnapLogic Manager to handle access to this endpoint. See Configuring Twitter Accounts for information on setting up this type of account.


Views:
InputThis Snap has at most one document input view.
OutputThis Snap has exactly one document output view.
ErrorThis Snap has at most one document error view and produces zero or more documents in the view.

Settings

Label


Required. The name for the Snap. You can modify this to be more specific, especially if you have more than one of the same Snap in your pipeline.

Twitter query



Required. The Twitter query to execute.
Example: @Snaplogic
Default value: [None]


Maximum tweets


Required.The number of Tweets to return from the Twitter API. This is Twitter's count parameter.

Example: 50
Default value: 100


Until date


This setting returns tweets until a date. Dates not matching the YYYY-MM-dd format cause the pipeline to fail.

Example: 2012-12-25
Default value: [None]


Since ID


This setting returns Tweets since the specified ID.

Example: 23452
Default value: [None] 
 

Max ID


Conditional, required if Since ID is used. This setting returns Tweets before the given ID.
Example: 53423
Default value: [None] 
 

Result type


This setting specified the type of results to return. The possible options include:

  • RECENT - Return only the most recent result.
  • MIXED - Include both popular and real time results.
  • POPULAR - Return only the most popular results.

Default value: RECENT

Snap Execution

Select one of the three modes in which the Snap executes. Available options are:

  • Validate & Execute: Performs limited execution of the Snap, and generates a data preview during Pipeline validation. Subsequently, performs full execution of the Snap (unlimited records) during Pipeline runtime.
  • Execute only: Performs full execution of the Snap during Pipeline execution without generating preview data.
  • Disabled: Disables the Snap and all Snaps that are downstream from it.

Example

The examples of Twitter Query Snap are described as use cases: 


See Also


Snap Pack History

 Click to view/expand
ReleaseSnap Pack VersionDateTypeUpdates
4.27main12883 StableUpgraded with the latest SnapLogic Platform release.
4.26main11181 StableUpgraded with the latest SnapLogic Platform release.
4.25main9554 StableUpgraded with the latest SnapLogic Platform release.
4.24424patches8617 Latest

Fixes the error handling issue in the PostTweet Snap, where data and error are now routed to the error view.

4.24main8556
 
Stable

Upgraded with the latest SnapLogic Platform release.

4.23main7430
 
StableUpgraded with the latest SnapLogic Platform release.
4.22main6403
 
StableUpgraded with the latest SnapLogic Platform release.
4.21snapsmrc542
 
StableUpgraded with the latest SnapLogic Platform release.
4.20snapsmrc535
 
StableUpgraded with the latest SnapLogic Platform release.
4.19snapsmrc8338 Latest

Fixed the broken doc link for the PostDirectMessage Snap.

4.19snaprsmrc528
 
StableUpgraded with the latest SnapLogic Platform release.
4.18snapsmrc523
 
StableUpgraded with the latest SnapLogic Platform release.
4.17ALL7402
 
Latest

Pushed automatic rebuild of the latest version of each Snap Pack to SnapLogic UAT and Elastic servers.

4.17snapsmrc515
 
Stable

Added the Snap Execution field to all Standard-mode Snaps. In some Snaps, this field replaces the existing Execute during preview check box.

4.16snapsmrc508
 
StableUpgraded with the latest SnapLogic Platform release.
4.15snapsmrc500
 
StableUpgraded with the latest SnapLogic Platform release.
4.14snapsmrc490
 
StableUpgraded with the latest SnapLogic Platform release.
4.13

snapsmrc486

 
Stable

Upgraded with the latest SnapLogic Platform release.

4.12

snapsmrc480

 
StableUpgraded with the latest SnapLogic Platform release.
4.11snapsmrc465
 
StableUpgraded with the latest SnapLogic Platform release.
4.10

snapsmrc414

 
StableUpgraded with the latest SnapLogic Platform release.
4.9

snapsmrc405

 
Stable

Upgraded with the latest SnapLogic Platform release.

4.8

snapsmrc398

 
StableUpgraded with the latest SnapLogic Platform release.
4.7

snapsmrc382

 
StableUpgraded with the latest SnapLogic Platform release.
4.6

rcmsf233

 
StableUpgraded with the latest SnapLogic Platform release.
4.5.1

twitter1579

 
StableUpdated the Twitter Streaming Search Snap with a timeout of 10 seconds for preview if the original value provided is zero or more than 30 seconds. For more information, see Twitter Streaming Search.
4.5rcmsf231 StableDoc Enhancement: Examples added to Twitter Snap documentation.
4.2.2NA

Updated messages within the Snap Pack.
July/Summer 2014NA

Twitter Query enhanced to support until, since_id, and max_id.
June 30, 2014NA

  • NEW! Twitter Streaming Search Snap. This Snap streams tweets based on a keyword.
  • Addressed the following issues:
    • Twitter Lookup Snap errors out if an expression was used for the screen-name or user-id
    • Twitter Query null pointer exception
March 2014NA

The Twitter Snap Pack was expanded with the addition of Get Direct Messages, Get Tweets, Lookup, Post Direct Message, and Post Tweet.
January 2014NA

Twitter Query updated.

June 2013NA

Introduced in this release.