Skip to main content

Esta versión de GitHub Enterprise Server se discontinuó el 2024-09-25. No se realizarán lanzamientos de patch, ni siquiera para problemas de seguridad críticos. Para obtener rendimiento mejorado, seguridad mejorada y nuevas características, actualice a la versión más reciente de GitHub Enterprise Server. Para obtener ayuda con la actualización, póngase en contacto con el soporte técnico de GitHub Enterprise.

Ahora la API de REST tiene control de versiones. Para obtener más información, consulta "Acerca del control de versiones de la API".

Terminales de REST para la API de reacciones

Usa la de API REST para interactuar con las reacciones en GitHub.

Acerca de las reacciones

Puedes crear y administrar reacciones a comentarios, problemas, solicitudes de incorporación de cambios y discusiones en GitHub. Cuando se crea una reacción, los valores permitidos para el parámetro content son los siguientes (con el emoji correspondiente como referencia):

Contenido Emoji
+1 👍
-1 👎
laugh 😄
confused 😕
heart ❤️
hooray 🎉
rocket 🚀
eyes 👀

List reactions for a team discussion comment

List the reactions to a team discussion comment.

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/reactions.

OAuth app tokens and personal access tokens (classic) need the read:discussion scope to use this endpoint.

Parámetros para "List reactions for a team discussion comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
org string Requerido

The organization name. The name is not case sensitive.

team_slug string Requerido

The slug of the team name.

discussion_number integer Requerido

The number that identifies the discussion.

comment_number integer Requerido

The number that identifies the comment.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to a team discussion comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for a team discussion comment"

status codeDescripción
200

OK

Ejemplos de código para "List reactions for a team discussion comment"

Ejemplo de solicitud

get/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/orgs/ORG/teams/TEAM_SLUG/discussions/DISCUSSION_NUMBER/comments/COMMENT_NUMBER/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for a team discussion comment

Create a reaction to a team discussion comment.

A response with an HTTP 200 status means that you already added the reaction type to this team discussion comment.

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/:comment_number/reactions.

OAuth app tokens and personal access tokens (classic) need the write:discussion scope to use this endpoint.

Parámetros para "Create reaction for a team discussion comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
org string Requerido

The organization name. The name is not case sensitive.

team_slug string Requerido

The slug of the team name.

discussion_number integer Requerido

The number that identifies the discussion.

comment_number integer Requerido

The number that identifies the comment.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the team discussion comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for a team discussion comment"

status codeDescripción
200

Response when the reaction type has already been added to this team discussion comment

201

Created

Ejemplos de código para "Create reaction for a team discussion comment"

Ejemplos de solicitud

post/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/orgs/ORG/teams/TEAM_SLUG/discussions/DISCUSSION_NUMBER/comments/COMMENT_NUMBER/reactions \ -d '{"content":"heart"}'

Response when the reaction type has already been added to this team discussion comment

Status: 200
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

Delete team discussion comment reaction

Note

You can also specify a team or organization with team_id and org_id using the route DELETE /organizations/:org_id/team/:team_id/discussions/:discussion_number/comments/:comment_number/reactions/:reaction_id.

Delete a reaction to a team discussion comment.

OAuth app tokens and personal access tokens (classic) need the write:discussion scope to use this endpoint.

Tokens de acceso específicos para "Delete team discussion comment reaction"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Team discussions" organization permissions (write)

Parámetros para "Delete team discussion comment reaction"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
org string Requerido

The organization name. The name is not case sensitive.

team_slug string Requerido

The slug of the team name.

discussion_number integer Requerido

The number that identifies the discussion.

comment_number integer Requerido

The number that identifies the comment.

reaction_id integer Requerido

The unique identifier of the reaction.

Códigos de estado de respuesta HTTP para "Delete team discussion comment reaction"

status codeDescripción
204

No Content

Ejemplos de código para "Delete team discussion comment reaction"

Ejemplo de solicitud

delete/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions/{reaction_id}
curl -L \ -X DELETE \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/orgs/ORG/teams/TEAM_SLUG/discussions/DISCUSSION_NUMBER/comments/COMMENT_NUMBER/reactions/REACTION_ID

Response

Status: 204

List reactions for a team discussion

List the reactions to a team discussion.

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/reactions.

OAuth app tokens and personal access tokens (classic) need the read:discussion scope to use this endpoint.

Parámetros para "List reactions for a team discussion"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
org string Requerido

The organization name. The name is not case sensitive.

team_slug string Requerido

The slug of the team name.

discussion_number integer Requerido

The number that identifies the discussion.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to a team discussion.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for a team discussion"

status codeDescripción
200

OK

Ejemplos de código para "List reactions for a team discussion"

Ejemplo de solicitud

get/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/orgs/ORG/teams/TEAM_SLUG/discussions/DISCUSSION_NUMBER/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for a team discussion

Create a reaction to a team discussion.

A response with an HTTP 200 status means that you already added the reaction type to this team discussion.

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/reactions.

OAuth app tokens and personal access tokens (classic) need the write:discussion scope to use this endpoint.

Parámetros para "Create reaction for a team discussion"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
org string Requerido

The organization name. The name is not case sensitive.

team_slug string Requerido

The slug of the team name.

discussion_number integer Requerido

The number that identifies the discussion.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the team discussion.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for a team discussion"

status codeDescripción
200

OK

201

Created

Ejemplos de código para "Create reaction for a team discussion"

Ejemplos de solicitud

post/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/orgs/ORG/teams/TEAM_SLUG/discussions/DISCUSSION_NUMBER/reactions \ -d '{"content":"heart"}'

Response

Status: 200
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

Delete team discussion reaction

Note

You can also specify a team or organization with team_id and org_id using the route DELETE /organizations/:org_id/team/:team_id/discussions/:discussion_number/reactions/:reaction_id.

Delete a reaction to a team discussion.

OAuth app tokens and personal access tokens (classic) need the write:discussion scope to use this endpoint.

Tokens de acceso específicos para "Delete team discussion reaction"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Team discussions" organization permissions (write)

Parámetros para "Delete team discussion reaction"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
org string Requerido

The organization name. The name is not case sensitive.

team_slug string Requerido

The slug of the team name.

discussion_number integer Requerido

The number that identifies the discussion.

reaction_id integer Requerido

The unique identifier of the reaction.

Códigos de estado de respuesta HTTP para "Delete team discussion reaction"

status codeDescripción
204

No Content

Ejemplos de código para "Delete team discussion reaction"

Ejemplo de solicitud

delete/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions/{reaction_id}
curl -L \ -X DELETE \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/orgs/ORG/teams/TEAM_SLUG/discussions/DISCUSSION_NUMBER/reactions/REACTION_ID

Response

Status: 204

List reactions for a commit comment

List the reactions to a commit comment.

Tokens de acceso específicos para "List reactions for a commit comment"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Metadata" repository permissions (read)

Este punto de conexión se puede usar sin autenticación o los permisos mencionados anteriormente si solo se solicitan recursos públicos.

Parámetros para "List reactions for a commit comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to a commit comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for a commit comment"

status codeDescripción
200

OK

404

Resource not found

Ejemplos de código para "List reactions for a commit comment"

Ejemplo de solicitud

get/repos/{owner}/{repo}/comments/{comment_id}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/comments/COMMENT_ID/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for a commit comment

Create a reaction to a commit comment. A response with an HTTP 200 status means that you already added the reaction type to this commit comment.

Tokens de acceso específicos para "Create reaction for a commit comment"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Contents" repository permissions (write)

Parámetros para "Create reaction for a commit comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the commit comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for a commit comment"

status codeDescripción
200

Reaction exists

201

Reaction created

422

Validation failed, or the endpoint has been spammed.

Ejemplos de código para "Create reaction for a commit comment"

Ejemplos de solicitud

post/repos/{owner}/{repo}/comments/{comment_id}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/comments/COMMENT_ID/reactions \ -d '{"content":"heart"}'

Reaction exists

Status: 200
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

Delete a commit comment reaction

Note

You can also specify a repository by repository_id using the route DELETE /repositories/:repository_id/comments/:comment_id/reactions/:reaction_id.

Delete a reaction to a commit comment.

Tokens de acceso específicos para "Delete a commit comment reaction"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Contents" repository permissions (write)

Parámetros para "Delete a commit comment reaction"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

reaction_id integer Requerido

The unique identifier of the reaction.

Códigos de estado de respuesta HTTP para "Delete a commit comment reaction"

status codeDescripción
204

No Content

Ejemplos de código para "Delete a commit comment reaction"

Ejemplo de solicitud

delete/repos/{owner}/{repo}/comments/{comment_id}/reactions/{reaction_id}
curl -L \ -X DELETE \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/comments/COMMENT_ID/reactions/REACTION_ID

Response

Status: 204

List reactions for an issue comment

List the reactions to an issue comment.

Tokens de acceso específicos para "List reactions for an issue comment"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Issues" repository permissions (read)

Este punto de conexión se puede usar sin autenticación o los permisos mencionados anteriormente si solo se solicitan recursos públicos.

Parámetros para "List reactions for an issue comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to an issue comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for an issue comment"

status codeDescripción
200

OK

404

Resource not found

Ejemplos de código para "List reactions for an issue comment"

Ejemplo de solicitud

get/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/issues/comments/COMMENT_ID/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for an issue comment

Create a reaction to an issue comment. A response with an HTTP 200 status means that you already added the reaction type to this issue comment.

Tokens de acceso específicos para "Create reaction for an issue comment"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Issues" repository permissions (write)

Parámetros para "Create reaction for an issue comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the issue comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for an issue comment"

status codeDescripción
200

Reaction exists

201

Reaction created

422

Validation failed, or the endpoint has been spammed.

Ejemplos de código para "Create reaction for an issue comment"

Ejemplos de solicitud

post/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/issues/comments/COMMENT_ID/reactions \ -d '{"content":"heart"}'

Reaction exists

Status: 200
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

Delete an issue comment reaction

Note

You can also specify a repository by repository_id using the route DELETE delete /repositories/:repository_id/issues/comments/:comment_id/reactions/:reaction_id.

Delete a reaction to an issue comment.

Tokens de acceso específicos para "Delete an issue comment reaction"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Issues" repository permissions (write)

Parámetros para "Delete an issue comment reaction"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

reaction_id integer Requerido

The unique identifier of the reaction.

Códigos de estado de respuesta HTTP para "Delete an issue comment reaction"

status codeDescripción
204

No Content

Ejemplos de código para "Delete an issue comment reaction"

Ejemplo de solicitud

delete/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions/{reaction_id}
curl -L \ -X DELETE \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/issues/comments/COMMENT_ID/reactions/REACTION_ID

Response

Status: 204

List reactions for an issue

List the reactions to an issue.

Tokens de acceso específicos para "List reactions for an issue"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Issues" repository permissions (read)

Este punto de conexión se puede usar sin autenticación o los permisos mencionados anteriormente si solo se solicitan recursos públicos.

Parámetros para "List reactions for an issue"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

issue_number integer Requerido

The number that identifies the issue.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to an issue.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for an issue"

status codeDescripción
200

OK

404

Resource not found

410

Gone

Ejemplos de código para "List reactions for an issue"

Ejemplo de solicitud

get/repos/{owner}/{repo}/issues/{issue_number}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/issues/ISSUE_NUMBER/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for an issue

Create a reaction to an issue. A response with an HTTP 200 status means that you already added the reaction type to this issue.

Tokens de acceso específicos para "Create reaction for an issue"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Issues" repository permissions (write)

Parámetros para "Create reaction for an issue"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

issue_number integer Requerido

The number that identifies the issue.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the issue.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for an issue"

status codeDescripción
200

OK

201

Created

422

Validation failed, or the endpoint has been spammed.

Ejemplos de código para "Create reaction for an issue"

Ejemplos de solicitud

post/repos/{owner}/{repo}/issues/{issue_number}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/issues/ISSUE_NUMBER/reactions \ -d '{"content":"heart"}'

Response

Status: 200
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

Delete an issue reaction

Note

You can also specify a repository by repository_id using the route DELETE /repositories/:repository_id/issues/:issue_number/reactions/:reaction_id.

Delete a reaction to an issue.

Tokens de acceso específicos para "Delete an issue reaction"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Issues" repository permissions (write)

Parámetros para "Delete an issue reaction"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

issue_number integer Requerido

The number that identifies the issue.

reaction_id integer Requerido

The unique identifier of the reaction.

Códigos de estado de respuesta HTTP para "Delete an issue reaction"

status codeDescripción
204

No Content

Ejemplos de código para "Delete an issue reaction"

Ejemplo de solicitud

delete/repos/{owner}/{repo}/issues/{issue_number}/reactions/{reaction_id}
curl -L \ -X DELETE \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/issues/ISSUE_NUMBER/reactions/REACTION_ID

Response

Status: 204

List reactions for a pull request review comment

List the reactions to a pull request review comment.

Tokens de acceso específicos para "List reactions for a pull request review comment"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Pull requests" repository permissions (read)

Este punto de conexión se puede usar sin autenticación o los permisos mencionados anteriormente si solo se solicitan recursos públicos.

Parámetros para "List reactions for a pull request review comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to a pull request review comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for a pull request review comment"

status codeDescripción
200

OK

404

Resource not found

Ejemplos de código para "List reactions for a pull request review comment"

Ejemplo de solicitud

get/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/pulls/comments/COMMENT_ID/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for a pull request review comment

Create a reaction to a pull request review comment. A response with an HTTP 200 status means that you already added the reaction type to this pull request review comment.

Tokens de acceso específicos para "Create reaction for a pull request review comment"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Pull requests" repository permissions (write)

Parámetros para "Create reaction for a pull request review comment"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the pull request review comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for a pull request review comment"

status codeDescripción
200

Reaction exists

201

Reaction created

422

Validation failed, or the endpoint has been spammed.

Ejemplos de código para "Create reaction for a pull request review comment"

Ejemplos de solicitud

post/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/pulls/comments/COMMENT_ID/reactions \ -d '{"content":"heart"}'

Reaction exists

Status: 200
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

Delete a pull request comment reaction

Note

You can also specify a repository by repository_id using the route DELETE /repositories/:repository_id/pulls/comments/:comment_id/reactions/:reaction_id.

Delete a reaction to a pull request review comment.

Tokens de acceso específicos para "Delete a pull request comment reaction"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado debe tener el siguiente conjunto de permisos:

  • "Pull requests" repository permissions (write)

Parámetros para "Delete a pull request comment reaction"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

comment_id integer Requerido

The unique identifier of the comment.

reaction_id integer Requerido

The unique identifier of the reaction.

Códigos de estado de respuesta HTTP para "Delete a pull request comment reaction"

status codeDescripción
204

No Content

Ejemplos de código para "Delete a pull request comment reaction"

Ejemplo de solicitud

delete/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions/{reaction_id}
curl -L \ -X DELETE \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/pulls/comments/COMMENT_ID/reactions/REACTION_ID

Response

Status: 204

List reactions for a release

List the reactions to a release.

Tokens de acceso específicos para "List reactions for a release"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado no requiere ningún permiso.

Parámetros para "List reactions for a release"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

release_id integer Requerido

The unique identifier of the release.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to a release.

Puede ser uno de los siguientes: +1, laugh, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for a release"

status codeDescripción
200

OK

404

Resource not found

Ejemplos de código para "List reactions for a release"

Ejemplo de solicitud

get/repos/{owner}/{repo}/releases/{release_id}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/releases/RELEASE_ID/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for a release

Create a reaction to a release. A response with a Status: 200 OK means that you already added the reaction type to this release.

Tokens de acceso específicos para "Create reaction for a release"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado no requiere ningún permiso.

Parámetros para "Create reaction for a release"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

release_id integer Requerido

The unique identifier of the release.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the release.

Puede ser uno de los siguientes: +1, laugh, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for a release"

status codeDescripción
200

Reaction exists

201

Reaction created

422

Validation failed, or the endpoint has been spammed.

Ejemplos de código para "Create reaction for a release"

Ejemplos de solicitud

post/repos/{owner}/{repo}/releases/{release_id}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/releases/RELEASE_ID/reactions \ -d '{"content":"heart"}'

Reaction exists

Status: 200
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

Delete a release reaction

Note

You can also specify a repository by repository_id using the route DELETE delete /repositories/:repository_id/releases/:release_id/reactions/:reaction_id.

Delete a reaction to a release.

Tokens de acceso específicos para "Delete a release reaction"

Este punto de conexión funciona con los siguientes tipos de token pormenorizados:

El token pormenorizado no requiere ningún permiso.

Parámetros para "Delete a release reaction"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
owner string Requerido

The account owner of the repository. The name is not case sensitive.

repo string Requerido

The name of the repository without the .git extension. The name is not case sensitive.

release_id integer Requerido

The unique identifier of the release.

reaction_id integer Requerido

The unique identifier of the reaction.

Códigos de estado de respuesta HTTP para "Delete a release reaction"

status codeDescripción
204

No Content

Ejemplos de código para "Delete a release reaction"

Ejemplo de solicitud

delete/repos/{owner}/{repo}/releases/{release_id}/reactions/{reaction_id}
curl -L \ -X DELETE \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/repos/OWNER/REPO/releases/RELEASE_ID/reactions/REACTION_ID

Response

Status: 204

List reactions for a team discussion comment (Legacy)

Warning

Endpoint closing down notice: This endpoint route is closing down and will be removed from the Teams API. We recommend migrating your existing code to use the new List reactions for a team discussion comment endpoint.

List the reactions to a team discussion comment.

OAuth app tokens and personal access tokens (classic) need the read:discussion scope to use this endpoint.

Parámetros para "List reactions for a team discussion comment (Legacy)"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
team_id integer Requerido

The unique identifier of the team.

discussion_number integer Requerido

The number that identifies the discussion.

comment_number integer Requerido

The number that identifies the comment.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to a team discussion comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for a team discussion comment (Legacy)"

status codeDescripción
200

OK

Ejemplos de código para "List reactions for a team discussion comment (Legacy)"

Ejemplo de solicitud

get/teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/teams/TEAM_ID/discussions/DISCUSSION_NUMBER/comments/COMMENT_NUMBER/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for a team discussion comment (Legacy)

Warning

Endpoint closing down notice: This endpoint route is closing down and will be removed from the Teams API. We recommend migrating your existing code to use the new "Create reaction for a team discussion comment" endpoint.

Create a reaction to a team discussion comment.

A response with an HTTP 200 status means that you already added the reaction type to this team discussion comment.

OAuth app tokens and personal access tokens (classic) need the write:discussion scope to use this endpoint.

Parámetros para "Create reaction for a team discussion comment (Legacy)"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
team_id integer Requerido

The unique identifier of the team.

discussion_number integer Requerido

The number that identifies the discussion.

comment_number integer Requerido

The number that identifies the comment.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the team discussion comment.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for a team discussion comment (Legacy)"

status codeDescripción
201

Created

Ejemplos de código para "Create reaction for a team discussion comment (Legacy)"

Ejemplo de solicitud

post/teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/teams/TEAM_ID/discussions/DISCUSSION_NUMBER/comments/COMMENT_NUMBER/reactions \ -d '{"content":"heart"}'

Response

Status: 201
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }

List reactions for a team discussion (Legacy)

Warning

Endpoint closing down notice: This endpoint route is closing down and will be removed from the Teams API. We recommend migrating your existing code to use the new List reactions for a team discussion endpoint.

List the reactions to a team discussion.

OAuth app tokens and personal access tokens (classic) need the read:discussion scope to use this endpoint.

Parámetros para "List reactions for a team discussion (Legacy)"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
team_id integer Requerido

The unique identifier of the team.

discussion_number integer Requerido

The number that identifies the discussion.

Parámetros de consulta
Nombre, Tipo, Descripción
content string

Returns a single reaction type. Omit this parameter to list all reactions to a team discussion.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

per_page integer

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

Valor predeterminado: 30

page integer

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Valor predeterminado: 1

Códigos de estado de respuesta HTTP para "List reactions for a team discussion (Legacy)"

status codeDescripción
200

OK

Ejemplos de código para "List reactions for a team discussion (Legacy)"

Ejemplo de solicitud

get/teams/{team_id}/discussions/{discussion_number}/reactions
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/teams/TEAM_ID/discussions/DISCUSSION_NUMBER/reactions

Response

Status: 200
[ { "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" } ]

Create reaction for a team discussion (Legacy)

Warning

Endpoint closing down notice: This endpoint route is closing down and will be removed from the Teams API. We recommend migrating your existing code to use the new Create reaction for a team discussion endpoint.

Create a reaction to a team discussion.

A response with an HTTP 200 status means that you already added the reaction type to this team discussion.

OAuth app tokens and personal access tokens (classic) need the write:discussion scope to use this endpoint.

Parámetros para "Create reaction for a team discussion (Legacy)"

Encabezados
Nombre, Tipo, Descripción
accept string

Setting to application/vnd.github+json is recommended.

Parámetros de la ruta de acceso
Nombre, Tipo, Descripción
team_id integer Requerido

The unique identifier of the team.

discussion_number integer Requerido

The number that identifies the discussion.

Parámetros del cuerpo
Nombre, Tipo, Descripción
content string Requerido

The reaction type to add to the team discussion.

Puede ser uno de los siguientes: +1, -1, laugh, confused, heart, hooray, rocket, eyes

Códigos de estado de respuesta HTTP para "Create reaction for a team discussion (Legacy)"

status codeDescripción
201

Created

Ejemplos de código para "Create reaction for a team discussion (Legacy)"

Ejemplo de solicitud

post/teams/{team_id}/discussions/{discussion_number}/reactions
curl -L \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ http(s)://HOSTNAME/api/v3/teams/TEAM_ID/discussions/DISCUSSION_NUMBER/reactions \ -d '{"content":"heart"}'

Response

Status: 201
{ "id": 1, "node_id": "MDg6UmVhY3Rpb24x", "user": { "login": "octocat", "id": 1, "node_id": "MDQ6VXNlcjE=", "avatar_url": "https://github.com/images/error/octocat_happy.gif", "gravatar_id": "", "url": "https://HOSTNAME/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://HOSTNAME/users/octocat/followers", "following_url": "https://HOSTNAME/users/octocat/following{/other_user}", "gists_url": "https://HOSTNAME/users/octocat/gists{/gist_id}", "starred_url": "https://HOSTNAME/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://HOSTNAME/users/octocat/subscriptions", "organizations_url": "https://HOSTNAME/users/octocat/orgs", "repos_url": "https://HOSTNAME/users/octocat/repos", "events_url": "https://HOSTNAME/users/octocat/events{/privacy}", "received_events_url": "https://HOSTNAME/users/octocat/received_events", "type": "User", "site_admin": false }, "content": "heart", "created_at": "2016-05-20T20:09:31Z" }