Ballerina API Documentation

Functions of org.wso2.ballerina.connectors.twitter package

function constructRequestHeaders(message request, string httpMethod, string serviceEP, string consumerKey, string consumerSecret, string accessToken, string accessTokenSecret, map parameters)

Parameters:

Parameter NameData TypeDescription
requestmessage
httpMethodstring
serviceEPstring
consumerKeystring
consumerSecretstring
accessTokenstring
accessTokenSecretstring
parametersmap


Connectors of org.wso2.ballerina.connectors.twitter package

connector ClientConnector (string consumerKey, string consumerSecret, string accessToken, string accessTokenSecret)

Twitter client connector.

Parameters:

Parameter NameData TypeDescription
consumerKeystringThe consumer key of the Twitter account.
consumerSecretstringThe consumer secret of the Twitter account.
accessTokenstringThe access token of the Twitter account.
accessTokenSecretstringThe access token secret of the Twitter account.

Actions:

action destroyStatus()

Distroy a status.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
idstringThe numerical ID of the desired status.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action getClosestTrendLocations()

Retrive closest trend locations.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
latstringLatitude of the location.
longstringLongitude of the location

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action getTopTrendsByPlace()

Retrive top trends by place.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
locationIdstringThe Yahoo! Where On Earth ID of the location to return trending information for.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action retweet()

Retweet a tweet.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
idstringThe numerical ID of the desired status.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action search()

Search for tweets.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
querystringQuery string to retrieve the related tweets.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action showStatus()

Retrive a single status.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
idstringThe numerical ID of the desired status.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action tweet()

Update the authenticated user's current status.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
statusstringThe text of status update

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action unretweet()

Untweet a retweeted status.

Parameters:

Parameter NameData TypeDescription
tClientConnectorThe twitter Connector instance
idstringThe numerical ID of the desired status.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.


Menu

  • Functions
    • constructRequestHeaders(message request, string httpMethod, string serviceEP, string consumerKey, string consumerSecret, string accessToken, string accessTokenSecret, map parameters)
  • Connectors
    • ClientConnector (string consumerKey, string consumerSecret, string accessToken, string accessTokenSecret)
      • destroyStatus(ClientConnector t, string id)
      • getClosestTrendLocations(ClientConnector t, string lat, string long)
      • getTopTrendsByPlace(ClientConnector t, string locationId)
      • retweet(ClientConnector t, string id)
      • search(ClientConnector t, string query)
      • showStatus(ClientConnector t, string id)
      • tweet(ClientConnector t, string status)
      • unretweet(ClientConnector t, string id)

Copyright 2017 Ballerina API Documentation