Skip to main content

discussion_comments

Overview

Namediscussion_comments
TypeResource
Idgithub.teams.discussion_comments

Fields

NameDatatypeDescription
authorobjectA GitHub user.
bodystringThe main text of the comment.
body_htmlstring
body_versionstringThe current version of the body content. If provided, this update operation will be rejected if the given version does not match the latest version on the server.
created_atstring
discussion_urlstring
html_urlstring
last_edited_atstring
node_idstring
numberintegerThe unique sequence number of a team discussion comment.
reactionsobject
updated_atstring
urlstring

Methods

NameAccessible byRequired ParamsDescription
get_discussion_comment_in_orgSELECTcomment_number, discussion_number, org, team_slugGet a specific comment on a team discussion. OAuth access tokens require the read:discussion scope.

Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments/{comment_number}.
get_discussion_comment_legacySELECTcomment_number, discussion_number, team_idDeprecation Notice: This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new Get a discussion comment endpoint.

Get a specific comment on a team discussion. OAuth access tokens require the read:discussion scope.
list_discussion_comments_in_orgSELECTdiscussion_number, org, team_slugList all comments on a team discussion. OAuth access tokens require the read:discussion scope.

Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments.
list_discussion_comments_legacySELECTdiscussion_number, team_idDeprecation Notice: This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new List discussion comments endpoint.

List all comments on a team discussion. OAuth access tokens require the read:discussion scope.
create_discussion_comment_in_orgINSERTdiscussion_number, org, team_slug, data__bodyCreates a new comment on a team discussion. OAuth access tokens require the write:discussion scope.

This endpoint triggers notifications. Creating content too quickly using this endpoint may result in secondary rate limiting. See "Secondary rate limits" and "Dealing with secondary rate limits" for details.

Note: You can also specify a team by org_id and team_id using the route POST /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments.
delete_discussion_comment_in_orgDELETEcomment_number, discussion_number, org, team_slugDeletes a comment on a team discussion. OAuth access tokens require the write:discussion scope.

Note: You can also specify a team by org_id and team_id using the route DELETE /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments/{comment_number}.
create_discussion_comment_legacyEXECdiscussion_number, team_id, data__bodyDeprecation Notice: This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new Create a discussion comment endpoint.

Creates a new comment on a team discussion. OAuth access tokens require the write:discussion scope.

This endpoint triggers notifications. Creating content too quickly using this endpoint may result in secondary rate limiting. See "Secondary rate limits" and "Dealing with secondary rate limits" for details.
delete_discussion_comment_legacyEXECcomment_number, discussion_number, team_idDeprecation Notice: This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new Delete a discussion comment endpoint.

Deletes a comment on a team discussion. OAuth access tokens require the write:discussion scope.
update_discussion_comment_in_orgEXECcomment_number, discussion_number, org, team_slug, data__bodyEdits the body text of a discussion comment. OAuth access tokens require the write:discussion scope.

Note: You can also specify a team by org_id and team_id using the route PATCH /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments/{comment_number}.
update_discussion_comment_legacyEXECcomment_number, discussion_number, team_id, data__bodyDeprecation Notice: This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new Update a discussion comment endpoint.

Edits the body text of a discussion comment. OAuth access tokens require the write:discussion scope.