Schema Documentation
Comment
Description
A Comment object
Fields
Field Name | Description |
---|---|
agent -
String | User agent used to post the comment. This field is equivalent to WP_Comment->comment_agent and the value matching the "comment_agent" column in SQL. |
approved -
Boolean | The approval status of the comment. This field is equivalent to WP_Comment->comment_approved and the value matching the "comment_approved" column in SQL. |
author -
CommentToCommenterConnectionEdge | The author of the comment |
authorIp -
String | IP address for the author. This field is equivalent to WP_Comment->comment_author_IP and the value matching the "comment_author_IP" column in SQL. |
commentId -
Int | ID for the comment, unique among comments. Deprecated in favor of databaseId |
commentedOn -
CommentToContentNodeConnectionEdge | Connection between the Comment type and the ContentNode type |
content -
String | Content of the comment. This field is equivalent to WP_Comment->comment_content and the value matching the "comment_content" column in SQL. |
Arguments
| |
databaseId -
Int! | The unique identifier stored in the database |
date -
String | Date the comment was posted in local time. This field is equivalent to WP_Comment->date and the value matching the "date" column in SQL. |
dateGmt -
String | Date the comment was posted in GMT. This field is equivalent to WP_Comment->date_gmt and the value matching the "date_gmt" column in SQL. |
id -
ID! | The globally unique identifier for the comment object |
isRestricted -
Boolean | Whether the object is restricted from the current viewer |
karma -
Int | Karma value for the comment. This field is equivalent to WP_Comment->comment_karma and the value matching the "comment_karma" column in SQL. |
parent -
CommentToParentCommentConnectionEdge | Connection between the Comment type and the Comment type |
Arguments
| |
parentDatabaseId -
Int | The database id of the parent comment node or null if it is the root comment |
parentId -
ID | The globally unique identifier of the parent comment node. |
replies -
CommentToCommentConnection | Connection between the Comment type and the Comment type |
Arguments
| |
type -
String | Type of comment. This field is equivalent to WP_Comment->comment_type and the value matching the "comment_type" column in SQL. |
Example
{"agent":"abc123","approved":false,"author":CommentToCommenterConnectionEdge,"authorIp":"abc123","commentId":987,"commentedOn":CommentToContentNodeConnectionEdge,"content":"xyz789","databaseId":987,"date":"abc123","dateGmt":"abc123","id":4,"isRestricted":true,"karma":987,"parent":CommentToParentCommentConnectionEdge,"parentDatabaseId":987,"parentId":4,"replies":CommentToCommentConnection,"type":"abc123"}