Facebook

Facebook

Facebook API allows you to access and publish posts on your Facebook user account

Note:

  • This is a Standard connector.

Throttling Limits

Name Calls Renewal Period
API calls per connection 500 300 seconds
Frequency of trigger polls 1 120 seconds

Actions

Get feed from my timeline

Gets the feeds from the logged in user's timeline.

Optional Parameters

Fields
string
Specify the fields you want returned. Example (id,name,picture).
Max posts
integer
Maximum number of posts to be retrieved.
With or without location
string
Restrict the list of posts to only those with location attached.
Filter for the feeds returned
string
Retrieve only posts that match a particular stream filter.

Returns

Feed
GetFeedResponse

List of feed items.

Get page feed (V2)

Get posts from the feed of a specified page (V2).

Required Parameters

Page ID
string
Unique ID of the page from which posts have to be retrieved.

Optional Parameters

Max posts
integer
Maximum number of posts to be retrieved.
Include hidden posts
boolean
Whether or not to include any posts that were hidden by the Page.
Fields
string
Specify the fields you want returned. Example (id,name,picture).

Returns

Feed
GetFeedResponse

List of feed items.

Get user or page timeline [DEPRECATED]

Get posts from a user or page timeline.

Required Parameters

User ID
string
Unique ID of the user or page whose timeline have to be retrieved.

Optional Parameters

Max posts
integer
Maximum number of posts to be retrieved.
With or without location
string
Restrict the list of posts to only those with location attached.
Include hidden posts
boolean
Whether or not to include any posts that were hidden by the Page.
Fields
string
Specify the fields you want returned. Example (id,name,picture).

Returns

Feed
GetFeedResponse

List of feed items.

Get user timeline

Get posts from a user's timeline.

Required Parameters

User ID
string
Unique ID of the user whose timeline have to be retrieved.

Optional Parameters

Max posts
integer
Maximum number of posts to be retrieved.
With or without location
string
Restrict the list of posts to only those with location attached.
Fields
string
Specify the fields you want returned. Example (id,name,picture).

Returns

Feed
GetFeedResponse

List of feed items.

Post to my timeline [DEPRECATED]

Post a status message to the logged in user's timeline.

Required Parameters

Status message
string
The main body of the post, otherwise called the status message.
Privacy value
string
The value of the privacy setting.

Optional Parameters

Post link
uri
The URL of a link to attach to the post.
Link image
uri
Determines the preview image associated with the link.
Link name
string
Overwrites the title of the link preview.
Link caption
string
Overwrites the caption under the title in the link preview.
Link description
string
Overwrites the description in the link preview.
Post location
string
Page ID of a location associated with this post.
Tagged users
string
Comma-separated list of user IDs of people tagged in this post.
Privacy settings description
string
Text that describes the privacy settings, as they would appear in Facebook.
Allowed users
string
When value is CUSTOM, this is a comma-separated list of user IDs and friend list IDs that can see the post.
Denied users
string
When value is CUSTOM, this is a comma-separated list of user IDs and friend list IDs that cannot see the post.
Denied friends
string
When value is CUSTOM, this indicates which group of friends can see the post.
Thumbnail picture ID
string
Facebook ID for an existing picture in the person's photo albums to use as the thumbnail image.

Returns

Posted Item
PostFeedResponse

Details of the item posted to the feed.

Post to page (V2)

Post a message to a Facebook Page as the logged in user (V2).

Required Parameters

Page ID
string
Unique ID of the page to post to.
Status message
string
The main body of the post, otherwise called the status message.

Optional Parameters

Post link
uri
The URL of a link to attach to the post.
Link image
uri
Determines the preview image associated with the link.
Link name
string
Overwrites the title of the link preview.
Link caption
string
Overwrites the caption under the title in the link preview.
Link description
string
Overwrites the description in the link preview.
Action link name
string
The name or label of the action link.
Action link
string
The URL of the action link itself.
Post location
string
Page ID of a location associated with this post
Tag users
string
Comma-separated list of user IDs of people tagged in this post.
Thumbnail picture ID
string
Facebook ID for an existing picture in the person's photo albums to use as the thumbnail image.
Country code
string
Location key
string
Target location item's key.
Location key
string
Target location item's key.
Locale code
integer
Country code
string
Location key
string
Target location item's key.
Location key
string
Target location item's key.
Location key
string
Target location item's key.
Minimum age
integer
Must be 13 or higher.
Maximum age
integer
Maximum Age.
Gender code. Use 1 for male and 2 for female.
integer
Relationship status. Use 1 for single, 2 for 'in a relationship', 3 for married, and 4 for engaged.
integer
Interest code. Use 1 to indicate male, 2 indicates female.
integer
Graduation year
integer
Education status code. Use 1 for high school, 2 for undergraduate, and 3 for alum (or localized equivalents).
integer
Locale code
integer
Publish post.
boolean
Whether a story is shown about this newly published object.
Schedule publish time
date-time
Time when this post should go live, this can be any date between ten minutes and six months from the time of the API call.
Back date time.
date-time
Specifies a time in the past to back-date this post to.
Backdated time display format.
string
Controls the display of how a backdated post appears.
Attachment link
string
The URL of a link to attach to the post.
Link picture
uri
Determines the preview image associated with the link (1:1 aspect ratio and a minimum of 458 x 458 px for best display).
Image hash
string
Hash of a preview image associated with the link from your ad image library (1:1 aspect ratio and a minimum of 458 x 458 px for best display).
Link name
string
The title of the link preview.
Link description
string
Used to show either a price, discount or website domain.
Multi-share end card
boolean
If set to false, does not display the end card of a carousel link post when child_attachments is used.

Returns

Posted Item
PostFeedResponse

Details of the item posted to the feed.

Post to page [DEPRECATED]

Post a message to a Facebook Page as the logged in user.

Required Parameters

Page ID
string
Unique ID of the page to post to.
Status message
string
The main body of the post, otherwise called the status message.

Optional Parameters

Post link
uri
The URL of a link to attach to the post.
Link image
uri
Determines the preview image associated with the link.
Link name
string
Overwrites the title of the link preview.
Link caption
string
Overwrites the caption under the title in the link preview.
Link description
string
Overwrites the description in the link preview.
Action link name
string
The name or label of the action link.
Action link
string
The URL of the action link itself.
Post location
string
Page ID of a location associated with this post
Tag users
string
Comma-separated list of user IDs of people tagged in this post.
Thumbnail picture ID
string
Facebook ID for an existing picture in the person's photo albums to use as the thumbnail image.
Country code
string
Locale code
integer
Region code
integer
City code
integer
Country code
string
Region code
integer
City code
integer
Minimum age
integer
Must be 13 or higher.
Maximum age
integer
Maximum Age.
Gender code. Use 1 for male and 2 for female.
integer
Relationship status. Use 1 for single, 2 for 'in a relationship', 3 for married, and 4 for engaged.
integer
Interest code. Use 1 to indicate male, 2 indicates female.
integer
Graduation year
integer
Education status code. Use 1 for high school, 2 for undergraduate, and 3 for alum (or localized equivalents).
integer
Locale code
integer
Publish post.
boolean
Whether a story is shown about this newly published object.
Schedule publish time
date-time
Time when this post should go live, this can be any date between ten minutes and six months from the time of the API call.
Back date time.
date-time
Specifies a time in the past to back-date this post to.
Backdated time display format.
string
Controls the display of how a backdated post appears.
Attachment link
string
The URL of a link to attach to the post.
Link picture
uri
Determines the preview image associated with the link (1:1 aspect ratio and a minimum of 458 x 458 px for best display).
Image hash
string
Hash of a preview image associated with the link from your ad image library (1:1 aspect ratio and a minimum of 458 x 458 px for best display).
Link name
string
The title of the link preview.
Link description
string
Used to show either a price, discount or website domain.
Multi-share end card
boolean
If set to false, does not display the end card of a carousel link post when child_attachments is used.

Returns

Posted Item
PostFeedResponse

Details of the item posted to the feed.

Triggers

When there is a new post on my timeline

Triggers a new flow when there is a new post on the logged in user's timeline. The ability of our service to detect a post must pass several privacy checks including a person's privacy settings on Facebook. Therefore, it is possible for this trigger to not activate for all posts.

Returns

Timeline Feed
TriggerFeedResponse

List of newly created posts.

Definitions

GetFeedResponse

List of feed items.

Response Data
array of PostItem
List of feed items.

TriggerFeedResponse

List of newly created posts.

Response Data
array of TriggerItem
List of newly created posts.

PostItem

An individual entry in a profile's feed. The profile could be a user, page, app, or group.

Admin Creators
array of AdminItem
Unique ID of admin who created the post. Applies to pages only.
Created Date-Time
date-time
The time the post was initially published. For a post about a life event, this will be the date and time of the life event.
Icon link
string
A link to an icon representing the type of this post.
Image url
uri
The picture scraped from any link included with the post.
Is hidden?
boolean
If this post is marked as hidden (applies to Pages only).
Is published?
boolean
Indicates whether a scheduled post was published (applies to scheduled Page Post only, for users post and instanlty published posts this value is always true).
Last updated time
date-time
The time of the last change to this post, or the comments on it.
Link Description
string
A description of a link in the post (appears beneath the caption).
Link caption
string
The caption of a link in the post (appears beneath the name).
Link url
uri
The link attached to this post.
Media ID
string
The ID of any uploaded photo or video attached to the post.
Name
string
The name of the link.
News Feed Target
FeedTargetItem
Object that controls news feed targeting for this post. Anyone in these groups will be more likely to see this post, others will be less likely. Applies to Pages only.
Post ID
string
Unique ID of the post.
Post Properties
array of PropertyItem
A list of properties for any attached video, for example, the length of the video.
Post type
string
A string indicating the object type of this post.
Status message
string
The status message in the post.
Status update type
string
Description of the type of a status update.
Story text
string
Text from stories not intentionally generated by users, such as those generated when two people become friends, or when someone else posts on the person's wall.
To
array of ProfileCollection
Profiles mentioned or targeted in this post.
User
UserItem
Details of a specific Facebook user.
Video source
uri
A URL to any Flash movie or video file attached to the post.
media
array of uri
An individual entry in a profile's feed. The profile could be a user, page, app, or group.
place
PlaceItem
An individual entry in a profile's feed. The profile could be a user, page, app, or group.
privacy
PrivacyItem
An individual entry in a profile's feed. The profile could be a user, page, app, or group.
targeting
TargetItem
An individual entry in a profile's feed. The profile could be a user, page, app, or group.
with_tags
ProfileCollection
An individual entry in a profile's feed. The profile could be a user, page, app, or group.

TriggerItem

An individual entry in a profile's feed. The profile could be a user, page, app, or group.

Created Time
date-time
The time the post was initially published. For a post about a life event, this will be the date and time of the life event.
Image url
uri
The picture scraped from any link included with the post.
Link description
string
A description of a link in the post (appears beneath the caption).
Link url
uri
The link attached to this post.
Name
string
The name of the link.
Post ID
string
The post ID.
Post Type
string
A string indicating the object type of this post.
Status message
string
The status message in the post.
User
UserItem
Details of a specific Facebook user.
media
array of uri
An individual entry in a profile's feed. The profile could be a user, page, app, or group.

AdminItem

Admin full name
string
Name of the admin.
User ID
integer
Unique ID of the admin user.

PropertyItem

Property link
uri
Any link associated with the property.
Property name
string
The property name.
Property value
string
The value of the property.

PostFeedResponse

Details of the item posted to the feed.

Post ID
string
Details of the item posted to the feed.

ProfileCollection

data
array of UserItem

UserItem

Details of a specific Facebook user.

First name
string
User first name.
Full name
string
User full name.
Gender
string
Gender of the user.
Last name
string
User last name.
User ID
string
Unique ID of the user.
User bio
string
Body of the user's bio page.

TargetItem

Excluded cities
array of integer
Values for excluded cities.
Targetted countries
array of string
Values of targeting countries.
Targetted locales
array of integer
Targeted locales.
Targetted regions
array of integer
Values for targeted regions.

FeedTargetItem

Object that controls news feed targeting for this post. Anyone in these groups will be more likely to see this post, others will be less likely. Applies to Pages only.

Excluded cities
array of integer
Values for excluded cities.
Maximum age
integer
Maximum Age.
Minimum age
integer
Must be 13 or higher.
Targetted college graduation year
array of integer
Array of integers for graduation year from college.
Targetted countries
array of string
Values of targeting countries.
Targetted education statuses
array of integer
Array of integers for targeting based on education level.
Targetted genders
array of integer
Target specific genders. 1 targets all male viewers and 2 females. Default is to target both.
Targetted interests
array of integer
Indicates targeting based on the 'interested in' field of the user profile.
Targetted locales
array of integer
Targeted locales.
Targetted regions
array of integer
Values for targeted regions.
Targetted relationship statuses
array of integer
Array of integers for targeting based on relationship status.

PlaceItem

Place ID
string
Unique ID of the place
Place name
string
Name of the place
Place rating
float
Overall rating of place, on a 5-star scale. 0 means not enough data to get a combined rating.
location
LocationItem

LocationItem

City name
string
City of the location.
Country name
string
Country of the location.
Latitude
float
Latitude of the location.
Located in
string
The parent location if this location is located within another location.
Location name
string
Name of the location.
Longitude
float
Longitude of the location.
Region name
string
Name of the location region.
State name
string
State which the location is in.
Street name
string
Street which the location is on.
Zipcode
string
Location Zip Code.

PrivacyItem

Allowed users
string
When value is CUSTOM, this is a comma-separated list of user IDs and friend list IDs that can see the post.
Denied friends
string
When value is CUSTOM, this indicates which group of friends can see the post.
Denied users
string
When value is CUSTOM, this is a comma-separated list of user IDs and friend list IDs that cannot see the post.
Privacy settings description
string
Text that describes the privacy settings, as they would appear in Facebook.
Privacy value
string
The value of the privacy setting.