Stay organized with collections Save and categorize content based on your preferences.

For a list of methods for this resource, see the end of this page.

Resource representations

A comment on a file.

  "kind": "drive#comment",
  "id": string,
  "createdTime": datetime,
  "modifiedTime": datetime,
  "author": {
    "kind": "drive#user",
    "displayName": string,
    "photoLink": string,
    "me": boolean,
    "permissionId": string,
    "emailAddress": string
  "htmlContent": string,
  "content": string,
  "deleted": boolean,
  "resolved": boolean,
  "quotedFileContent": {
    "mimeType": string,
    "value": string
  "anchor": string,
  "replies": [
    replies Resource
Property name Value Description Notes
kind string Identifies what kind of resource this is. Value: the fixed string "drive#comment".
id string The ID of the comment.
createdTime datetime The time at which the comment was created (RFC 3339 date-time).
modifiedTime datetime The last time the comment or any of its replies was modified (RFC 3339 date-time).
author nested object The author of the comment. The author's email address and permission ID will not be populated.
author.kind string Identifies what kind of resource this is. Value: the fixed string "drive#user".
author.displayName string A plain text displayable name for this user. boolean Whether this user is the requesting user.
author.permissionId string The user's ID as visible in Permission resources.
author.emailAddress string The email address of the user. This may not be present in certain contexts if the user has not made their email address visible to the requester.
htmlContent string The content of the comment with HTML formatting.
content string The plain text content of the comment. This field is used for setting the content, while htmlContent should be displayed. writable
deleted boolean Whether the comment has been deleted. A deleted comment has no content.
resolved boolean Whether the comment has been resolved by one of its replies.
quotedFileContent object The file content to which the comment refers, typically within the anchor region. For a text file, for example, this would be the text at the location of the comment.
quotedFileContent.mimeType string The MIME type of the quoted content.
quotedFileContent.value string The quoted content itself. This is interpreted as plain text if set through the API. writable
anchor string A region of the document represented as a JSON string. For details on defining anchor properties, refer to Add comments and replies. writable
replies[] list The full list of replies to the comment in chronological order.


Creates a comment on a file.
Deletes a comment.
Gets a comment by ID.
Lists a file's comments.
Updates a comment with patch semantics.