Ballerina API Documentation

Connectors of org.ballerinalang.connectors.facebook package

connector ClientConnector (string accessToken)

Facebook client connector.

Parameters:

Parameter NameData TypeDescription
accessTokenstringValue of the valid access_token.

Actions:

action createPost()

Create a post for user, page, event or group.

Parameters:

Parameter NameData TypeDescription
fClientConnectorid: The identifier.
idstringThe identifier.
msgstringThe main body of the post.
linkstringThe URL of a link to attach to the post.
placestringPage ID of a location associated with this post.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action retrievePost()

Retrieve a post.

Parameters:

Parameter NameData TypeDescription
fClientConnectorpostId: The post ID.
postIdstringThe post ID.
fieldsstringThe fields to retrieve which belongs to an object.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action deletePost()

Delete a post.

Parameters:

Parameter NameData TypeDescription
fClientConnectorpostId: The post ID.
postIdstringThe post ID.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action updatePost()

Update a post.

Parameters:

Parameter NameData TypeDescription
fClientConnectorpostId: The post ID.
postIdstringThe post ID.
msgstringThe main body of the post.
tagsstringComma-separated list of user IDs of people tagged in this post.
privacystringPrivacy settings of the post.

Return Parameters:

Return VariableData TypeDescription
messageResponse object

action addLikes()

Add likes.

Parameters:

Parameter NameData TypeDescription
fClientConnectorobjectId: The object ID to add like.
objectIdstringThe object ID to add like.

Return Parameters:

Return VariableData TypeDescription
messageResponse object

action getLikesDetails()

Get like details.

Parameters:

Parameter NameData TypeDescription
fClientConnectorobjectId: The object ID to get the like details.
objectIdstringThe object ID to get the like details.
fieldsstringThe fields to retrieve.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action deleteLikes()

Delete likes.

Parameters:

Parameter NameData TypeDescription
fClientConnectorobjectId: The object ID to remove the likes.
objectIdstringThe object ID to remove the likes.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action addComments()

Add comments

Parameters:

Parameter NameData TypeDescription
fClientConnectorobjectId: The ID of the object such as a page, video, etc.
objectIdstringThe ID of the object such as a page, video, etc.
msgstringThe comment text.
attachmentIdstringAn ID of an unpublished photo.
attachmentUrlstringThe URL of an image to include as a photo comment.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.

action getComments()

Get comments.

Parameters:

Parameter NameData TypeDescription
fClientConnectorobjectId: The ID of the object such as a page, video, etc.
objectIdstringThe ID of the object such as a page, video, etc.
fieldsstringThe fields to retrieve.

Return Parameters:

Return VariableData TypeDescription
messageResponse object.


Menu

  • Connectors
    • ClientConnector (string accessToken)
      • createPost(ClientConnector f, string id, string msg, string link, string place)
      • retrievePost(ClientConnector f, string postId, string fields)
      • deletePost(ClientConnector f, string postId)
      • updatePost(ClientConnector f, string postId, string msg, string tags, string privacy)
      • addLikes(ClientConnector f, string objectId)
      • getLikesDetails(ClientConnector f, string objectId, string fields)
      • deleteLikes(ClientConnector f, string objectId)
      • addComments(ClientConnector f, string objectId, string msg, string attachmentId, string attachmentUrl)
      • getComments(ClientConnector f, string objectId, string fields)

Copyright 2017 Ballerina API Documentation