GitHub v3 REST API

List issue comments

Issue Comments are ordered by ascending ID.

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/issues/{issue_number}/comments

Query Parameters

sincestring(date-time)

Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.

per_pageinteger

Results per page (max 100)

Default:30

pageinteger

Page number of the results to fetch.

Default:1

Path Parameters

ownerstringrequired
repostringrequired
issue_numberintegerrequired

issue_number parameter

Response

application/json

Response

Comments provide a way for people to collaborate on an issue.

idintegerrequired

Unique identifier of the issue comment

Example:42

node_idstringrequired
urlstring(uri)required

URL for the issue comment

Example:https://api.github.com/repositories/42/issues/comments/1

bodystring

Contents of the issue comment

Example:What version of Safari were you using when you observed this bug?

body_textstring
body_htmlstring
html_urlstring(uri)required
userobject | nullrequired

Simple User

Show Child Parameters
created_atstring(date-time)required

Example:2011-04-14T16:00:49Z

updated_atstring(date-time)required

Example:2011-04-14T16:00:49Z

issue_urlstring(uri)required
author_associationstringrequired

How the author is associated with the repository.

Allowed values:COLLABORATORCONTRIBUTORFIRST_TIMERFIRST_TIME_CONTRIBUTORMANNEQUINMEMBERNONEOWNER

Example:OWNER

performed_via_github_appobject | null

GitHub apps are a new way to extend GitHub. They can be installed directly on organizations and user accounts and granted access to specific repositories. They come with granular permissions and built-in webhooks. GitHub apps are first class actors within GitHub.

Show Child Parameters
reactionsobject
Show Child Parameters
get/repos/{owner}/{repo}/issues/{issue_number}/comments
 
application/json

Create an issue comment

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.

post
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/issues/{issue_number}/comments

Path Parameters

ownerstringrequired
repostringrequired
issue_numberintegerrequired

issue_number parameter

Body

application/json
bodystringrequired

The contents of the comment.

Response

application/json

Response

Issue Comment

Comments provide a way for people to collaborate on an issue.

idintegerrequired

Unique identifier of the issue comment

Example:42

node_idstringrequired
urlstring(uri)required

URL for the issue comment

Example:https://api.github.com/repositories/42/issues/comments/1

bodystring

Contents of the issue comment

Example:What version of Safari were you using when you observed this bug?

body_textstring
body_htmlstring
html_urlstring(uri)required
userobject | nullrequired

Simple User

Show Child Parameters
created_atstring(date-time)required

Example:2011-04-14T16:00:49Z

updated_atstring(date-time)required

Example:2011-04-14T16:00:49Z

issue_urlstring(uri)required
author_associationstringrequired

How the author is associated with the repository.

Allowed values:COLLABORATORCONTRIBUTORFIRST_TIMERFIRST_TIME_CONTRIBUTORMANNEQUINMEMBERNONEOWNER

Example:OWNER

performed_via_github_appobject | null

GitHub apps are a new way to extend GitHub. They can be installed directly on organizations and user accounts and granted access to specific repositories. They come with granular permissions and built-in webhooks. GitHub apps are first class actors within GitHub.

Show Child Parameters
reactionsobject
Show Child Parameters
post/repos/{owner}/{repo}/issues/{issue_number}/comments

Body

{ "body": "Me too" }
 
application/json

List issue events

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/issues/{issue_number}/events

Query Parameters

per_pageinteger

Results per page (max 100)

Default:30

pageinteger

Page number of the results to fetch.

Default:1

Path Parameters

ownerstringrequired
repostringrequired
issue_numberintegerrequired

issue_number parameter

Response

application/json

Response

Issue Event for Issuearray

Issue Event for Issue

Any Of
idintegerrequired
node_idstringrequired
urlstringrequired
actorobjectrequired

Simple User

Show Child Parameters
eventstringrequired
commit_idstring | nullrequired
commit_urlstring | nullrequired
created_atstringrequired
performed_via_github_appobject | nullrequired

GitHub apps are a new way to extend GitHub. They can be installed directly on organizations and user accounts and granted access to specific repositories. They come with granular permissions and built-in webhooks. GitHub apps are first class actors within GitHub.

Show Child Parameters
labelobjectrequired
Show Child Parameters
get/repos/{owner}/{repo}/issues/{issue_number}/events
 
application/json

List labels for an issue

get
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/issues/{issue_number}/labels

Query Parameters

per_pageinteger

Results per page (max 100)

Default:30

pageinteger

Page number of the results to fetch.

Default:1

Path Parameters

ownerstringrequired
repostringrequired
issue_numberintegerrequired

issue_number parameter

Response

application/json

Response

Color-coded labels help you categorize and filter your issues (just like labels in Gmail).

idinteger(int64)required

Example:208045946

node_idstringrequired

Example:MDU6TGFiZWwyMDgwNDU5NDY=

urlstring(uri)required

URL for the label

Example:https://api.github.com/repositories/42/labels/bug

namestringrequired

The name of the label.

Example:bug

descriptionstring | nullrequired

Example:Something isn't working

colorstringrequired

6-character hex code, without the leading #, identifying the color

Example:FFFFFF

defaultbooleanrequired

Example:true

get/repos/{owner}/{repo}/issues/{issue_number}/labels
 
application/json

Add labels to an issue

post
{protocol}://{hostname}/api/v3/repos/{owner}/{repo}/issues/{issue_number}/labels

Path Parameters

ownerstringrequired
repostringrequired
issue_numberintegerrequired

issue_number parameter

Body

application/json
One Of
labelsarray[string]

The names of the labels to add to the issue’s existing labels. You can pass an empty array to remove all labels. Alternatively, you can pass a single label as a string or an array of labels directly, but GitHub recommends passing an object with the labels key. You can also replace all of the labels for an issue. For more information, see “Set labels for an issue.”

>= 1 items

Response

application/json

Response

Color-coded labels help you categorize and filter your issues (just like labels in Gmail).

idinteger(int64)required

Example:208045946

node_idstringrequired

Example:MDU6TGFiZWwyMDgwNDU5NDY=

urlstring(uri)required

URL for the label

Example:https://api.github.com/repositories/42/labels/bug

namestringrequired

The name of the label.

Example:bug

descriptionstring | nullrequired

Example:Something isn't working

colorstringrequired

6-character hex code, without the leading #, identifying the color

Example:FFFFFF

defaultbooleanrequired

Example:true

post/repos/{owner}/{repo}/issues/{issue_number}/labels

Body

{ "labels": [ "bug", "enhancement" ] }
 
application/json