그래프 API 버전

Comment

읽기

A Facebook comment

새로운 페이지 환경

This endpoint is supported for 새로운 페이지 환경.

Feature Permissions

이름설명
페이지 전체 공개 콘텐츠 액세스기능 권한이 필요할 수도 있습니다.

Graph API Explorer
GET /v25.0/{comment-id} HTTP/1.1
Host: graph.facebook.com
/* PHP SDK v5.0.0 */
/* make the API call */
try {
  // Returns a `Facebook\FacebookResponse` object
  $response = $fb->get(
    '/{comment-id}',
    '{access-token}'
  );
} catch(Facebook\Exceptions\FacebookResponseException $e) {
  echo 'Graph returned an error: ' . $e->getMessage();
  exit;
} catch(Facebook\Exceptions\FacebookSDKException $e) {
  echo 'Facebook SDK returned an error: ' . $e->getMessage();
  exit;
}
$graphNode = $response->getGraphNode();
/* handle the result */
/* make the API call */
FB.api(
    "/{comment-id}",
    function (response) {
      if (response && !response.error) {
        /* handle the result */
      }
    }
);
/* make the API call */
new GraphRequest(
    AccessToken.getCurrentAccessToken(),
    "/{comment-id}",
    null,
    HttpMethod.GET,
    new GraphRequest.Callback() {
        public void onCompleted(GraphResponse response) {
            /* handle the result */
        }
    }
).executeAsync();
/* make the API call */
FBSDKGraphRequest *request = [[FBSDKGraphRequest alloc]
                               initWithGraphPath:@"/{comment-id}"
                                      parameters:params
                                      HTTPMethod:@"GET"];
[request startWithCompletionHandler:^(FBSDKGraphRequestConnection *connection,
                                      id result,
                                      NSError *error) {
    // Handle the result
}];
그래프 API를 사용하는 방법을 알아보려면 그래프 API 사용 가이드를 읽어보세요.

매개변수

이 엔드포인트는 매개변수가 없습니다.

필드

필드설명
id
token with structure: Comment ID

The comment ID

admin_creator

For a comment made by a page, the page admin who wrote it. A page access token is required to access this field.

application

The app this comment was published by

attachment

Link or photo attached to the comment

can_comment
bool

Whether the viewer can reply to this comment

can_hide
bool

Whether the viewer can hide this comment from everyone except the comment author and the author's friends. This can only be true for comments on Page posts

can_like
bool

Whether the viewer can like this comment

can_remove
bool

Whether the viewer can remove this comment

can_reply_privately
bool

Whether the page viewer can send a private reply to this comment

comment_count
unsigned int32

Number of replies to this comment

created_time
datetime

The time this comment was made

from
User|Page

The profile that made this comment

is_hidden
bool

Whether this comment is hidden from everyone except the comment author and the author's friends

is_private
bool

Whether the comment is a private comment

like_count
unsigned int32

Number of times this comment was liked

live_broadcast_timestamp
unsigned int32

Time the comment was made on a live video

message
string

The comment text

message_tags

Profiles tagged in mentions in the message

object

The object the comment is on

parent

For comment replies, the comment this is a reply to

permalink_url
uri

The permanent static URL to the comment

private_reply_conversation

If private reply was sent to this comment, gets private conversation between the page and author of the comment that was started by private reply

user_likes
bool

Whether the viewer has liked this comment

에지

Edge설명
Edge<Comment>

Comments made on this

Edge<Profile>

People who like this

Edge<Profile>

People who reacted on this

오류 코드

오류설명
100Invalid parameter
80001There have been too many calls to this Page account. Wait a bit and try again. For more info, please refer to https://developers.facebook.com/docs/graph-api/overview/rate-limiting.
200Permissions error
368The action attempted has been deemed abusive or is otherwise disallowed
190Invalid OAuth 2.0 Access Token
283That action requires the extended permission pages_read_engagement and/or pages_read_user_content and/or pages_manage_ads and/or pages_manage_metadata
2500Error parsing graph query
459The session is invalid because the user has been checkpointed
613Calls to this api have exceeded the rate limit.
210User not visible

만들기

다음 경로에서 comments 에지에 POST 요청을 만들 수 있습니다:
이 에지에 게시할 때 a Comment이(가) 생성됩니다.

매개변수

매개변수설명
attachment_id
numeric string or integer

ID for a photo attachment to associate with this

attachment_share_url
URL

Link to set the comment attachment to. Does not include the url in the message

attachment_url
URL

Link to set the comment attachment to

is_offline
boolean

Whether the comment was originally made while offline

message
UTF-8 string

Same as the text param

이모티콘 지원
text
UTF-8 string

The text of the comment that allows emoji

이모티콘 지원

반환 유형

이 엔드포인트는 기록 후 읽기를 지원하며 반환 유형에서 id로 표시되는 노드를 읽습니다.
Struct {
id: token with structure: Comment ID,
}

오류 코드

오류설명
100Invalid parameter
190Invalid OAuth 2.0 Access Token
368The action attempted has been deemed abusive or is otherwise disallowed
200Permissions error
1705There was an error during posting.
459The session is invalid because the user has been checkpointed

업데이트 중

/{comment_id}에 POST 요청을 하여 a Comment을(를) 업데이트할 수 있습니다.

매개변수

매개변수설명
attachment_id
numeric string or integer

ID for a photo attachment to associate with this

attachment_share_url
URL

Link to set the comment attachment to. Does not include the url in the message.

attachment_url
URL

Link to set the comment attachment to.

is_hidden
boolean

Is this comment hidden? Only applicable to Page comments

message
UTF-8 string

The text in the new comment message

이모티콘 지원

반환 유형

이 엔드포인트는 기록 후 읽기 기능을 지원하며 회원님이 게시한 노드를 읽습니다.
Struct {
success: bool,
}

오류 코드

오류설명
200Permissions error
368The action attempted has been deemed abusive or is otherwise disallowed
100Invalid parameter
80001There have been too many calls to this Page account. Wait a bit and try again. For more info, please refer to https://developers.facebook.com/docs/graph-api/overview/rate-limiting.
190Invalid OAuth 2.0 Access Token
210User not visible

삭제 중

/{comment_id}에 DELETE 요청을 만들어 a Comment을(를) 삭제할 수 있습니다.

매개변수

이 엔드포인트는 매개변수가 없습니다.

반환 유형

Struct {
success: bool,
}

오류 코드

오류설명
200Permissions error
100Invalid parameter
368The action attempted has been deemed abusive or is otherwise disallowed
190Invalid OAuth 2.0 Access Token