Graph:Comment

From Facebook Developer Wiki (FbDevWiki.com)
Jump to: navigation, search

A comment on a Graph API object

Contents

Example

https://graph.facebook.com/19292868552_475058873552_14173716 (A comment on Post)

Properties

Name Description Permissions Returns Condition
id The Facebook ID of the comment Available to everyone on Facebook by default A JSON string
created_time The timedate the comment was created Available to everyone on Facebook by default A JSON string containing a IETF RFC 3339 datetime
message The comment text Available to everyone on Facebook by default A JSON string
from The user that created the comment Available to everyone on Facebook by default A JSON object containing the id and name of the creating user
likes The number of times this comment was liked Available to everyone on Facebook by default A JSON integer
user_likes whether the current user likes this comment "true" This field is returned only if the authenticated user likes this comment

Connections

Name Description Permissions Returns
likes All of the likes on this comment Available to everyone on Facebook by default An array of JSON objects containing id and name fields of the user that liked the comment
comments (recognized, but comments don't have their own comments so probably not useful)


Publishing

Requires the publish_stream permission.

You can like a comment by issuing a POST to https://graph.facebook.com/[COMMENT ID]/likes. To delete a like on a comment, issue a DELETE to https://graph.facebook.com/[COMMENT ID]/likes.

curl -F 'access_token=...' \
     https://graph.facebook.com/19292868552_475058873552_14173716/likes


To create a comment, you post with a message field to the "/comment" link of the object you which to comment on. Look at the docs for the particular object you wish to comment on.

Personal tools
Namespaces
Variants
Actions
Navigation
Graph API
FQL
Toolbox