Difference between revisions of "TwitterSocialAdapter"

From GreenVulcano Wiki
Jump to: navigation, search
m (moved TwitterAdapter to TwitterSocialAdapter: Wrong name)
Line 31: Line 31:
 
|}
 
|}
 
</div>
 
</div>
 +
 +
Its attributes are:
 +
{|class="gvtable"
 +
! Attribute !! Type !! Description
 +
|-
 +
| type || fixed || This attribute must assume the value '''social-adapter'''.
 +
|-
 +
| class || fixed || This attribute must assume the value '''it.greenvulcano.gvesb.social.twitter.TwitterSocialAdapter'''.
 +
|-
 +
| social || fixed || This attribute must assume the value '''twitter'''.
 +
|}
 +
 +
Might contain the following sub-elements:
 +
* [[Description]]
 +
* [[#Account]]
 +
* [[Proxy]]
 +
 +
===Account===
 +
 +
The http-call Element is used by: [[Channel]] and [[routed-call]]. Its attributes are:
 +
{|class="gvtable"
 +
! Attribute !! Type !! Description
 +
|-
 +
| name || required || Account name.
 +
|-
 +
| consumer_key || required || Account consumer key.
 +
|-
 +
| consumer_secret || required || Account consumer secret.
 +
|-
 +
| twitteruserid || required || Account consumer twitter id.
 +
|}
 +
 +
The account information must be completed defining the following information into '''TwitterAccounts.properties''' file:
 +
ACCOUNT_NAME.oauth_access_token=...
 +
ACCOUNT_NAME.oauth_access_token_secret=... 
 +
where '''ACCOUNT_NAME''' is '''@name''' value.

Revision as of 08:22, 14 May 2014

Twitter adapter is an implementation of the Social Adapter dedicated to Twitter platform. It can be called as specified into GVSocialAdapter-Configuration specifying a method name to call, or with some custom function reflecting Twitter ones.

Please refer to GVSocialAdapter-Configuration to see the generic call.

The VCL operations usable in the workflows are the following:

Plug-in Use this for ...
Tweet.png twitter-update-status tweet
Retweet.png twitter-retweet-status retweet
Follow.png twitter-enable-notification follow
Unfollow.png twitter-disable-notification unfollow
Follower.png twitter-get-followers-ids get followers
AddUser.png twitter-get-friends-ids get friends
Message.png twitter-send-direct-message send direct tweet
Plug-in Use this for ...
Tweet.png twitter-get-user-timeline get user timeline
Tweet.png twitter-search search status updates

Its attributes are:

Attribute Type Description
type fixed This attribute must assume the value social-adapter.
class fixed This attribute must assume the value it.greenvulcano.gvesb.social.twitter.TwitterSocialAdapter.
social fixed This attribute must assume the value twitter.

Might contain the following sub-elements:

Account

The http-call Element is used by: Channel and routed-call. Its attributes are:

Attribute Type Description
name required Account name.
consumer_key required Account consumer key.
consumer_secret required Account consumer secret.
twitteruserid required Account consumer twitter id.

The account information must be completed defining the following information into TwitterAccounts.properties file:

ACCOUNT_NAME.oauth_access_token=...
ACCOUNT_NAME.oauth_access_token_secret=...   

where ACCOUNT_NAME is @name value.