GitHub v3 REST API

Delete a gist

delete
{protocol}://{hostname}/api/v3/gists/{gist_id}

Path Parameters

gist_idstringrequired

gist_id parameter

Response

Response

delete/gists/{gist_id}
 

List gist comments

get
{protocol}://{hostname}/api/v3/gists/{gist_id}/comments

Query Parameters

per_pageinteger

Results per page (max 100)

Default:30

pageinteger

Page number of the results to fetch.

Default:1

Path Parameters

gist_idstringrequired

gist_id parameter

Response

application/json

Response

A comment made to a gist.

idintegerrequired

Example:1

node_idstringrequired

Example:MDExOkdpc3RDb21tZW50MQ==

urlstring(uri)required

Example:https://api.github.com/gists/a6db0bec360bb87e9418/comments/1

bodystringrequired

The comment text.

<= 65535 characters

Example:Body of the attachment

userobject | nullrequired

Simple User

Show Child Parameters
created_atstring(date-time)required

Example:2011-04-18T23:23:56Z

updated_atstring(date-time)required

Example:2011-04-18T23:23:56Z

author_associationstringrequired

How the author is associated with the repository.

Allowed values:COLLABORATORCONTRIBUTORFIRST_TIMERFIRST_TIME_CONTRIBUTORMANNEQUINMEMBERNONEOWNER

Example:OWNER

get/gists/{gist_id}/comments
 
application/json

Create a gist comment

post
{protocol}://{hostname}/api/v3/gists/{gist_id}/comments

Path Parameters

gist_idstringrequired

gist_id parameter

Body

application/json
bodystringrequired

The comment text.

<= 65535 characters

Example:Body of the attachment

Response

application/json

Response

Gist Comment

A comment made to a gist.

idintegerrequired

Example:1

node_idstringrequired

Example:MDExOkdpc3RDb21tZW50MQ==

urlstring(uri)required

Example:https://api.github.com/gists/a6db0bec360bb87e9418/comments/1

bodystringrequired

The comment text.

<= 65535 characters

Example:Body of the attachment

userobject | nullrequired

Simple User

Show Child Parameters
created_atstring(date-time)required

Example:2011-04-18T23:23:56Z

updated_atstring(date-time)required

Example:2011-04-18T23:23:56Z

author_associationstringrequired

How the author is associated with the repository.

Allowed values:COLLABORATORCONTRIBUTORFIRST_TIMERFIRST_TIME_CONTRIBUTORMANNEQUINMEMBERNONEOWNER

Example:OWNER

post/gists/{gist_id}/comments

Body

{ "body": "Body of the attachment" }
 
application/json

Get a gist comment

get
{protocol}://{hostname}/api/v3/gists/{gist_id}/comments/{comment_id}

Path Parameters

gist_idstringrequired

gist_id parameter

comment_idintegerrequired

comment_id parameter

Response

application/json

Response

Gist Comment

A comment made to a gist.

idintegerrequired

Example:1

node_idstringrequired

Example:MDExOkdpc3RDb21tZW50MQ==

urlstring(uri)required

Example:https://api.github.com/gists/a6db0bec360bb87e9418/comments/1

bodystringrequired

The comment text.

<= 65535 characters

Example:Body of the attachment

userobject | nullrequired

Simple User

Show Child Parameters
created_atstring(date-time)required

Example:2011-04-18T23:23:56Z

updated_atstring(date-time)required

Example:2011-04-18T23:23:56Z

author_associationstringrequired

How the author is associated with the repository.

Allowed values:COLLABORATORCONTRIBUTORFIRST_TIMERFIRST_TIME_CONTRIBUTORMANNEQUINMEMBERNONEOWNER

Example:OWNER

get/gists/{gist_id}/comments/{comment_id}
 
application/json

Update a gist comment

patch
{protocol}://{hostname}/api/v3/gists/{gist_id}/comments/{comment_id}

Path Parameters

gist_idstringrequired

gist_id parameter

comment_idintegerrequired

comment_id parameter

Body

application/json
bodystringrequired

The comment text.

<= 65535 characters

Example:Body of the attachment

Response

application/json

Response

Gist Comment

A comment made to a gist.

idintegerrequired

Example:1

node_idstringrequired

Example:MDExOkdpc3RDb21tZW50MQ==

urlstring(uri)required

Example:https://api.github.com/gists/a6db0bec360bb87e9418/comments/1

bodystringrequired

The comment text.

<= 65535 characters

Example:Body of the attachment

userobject | nullrequired

Simple User

Show Child Parameters
created_atstring(date-time)required

Example:2011-04-18T23:23:56Z

updated_atstring(date-time)required

Example:2011-04-18T23:23:56Z

author_associationstringrequired

How the author is associated with the repository.

Allowed values:COLLABORATORCONTRIBUTORFIRST_TIMERFIRST_TIME_CONTRIBUTORMANNEQUINMEMBERNONEOWNER

Example:OWNER

patch/gists/{gist_id}/comments/{comment_id}

Body

{ "body": "Body of the attachment" }
 
application/json