• /
  • EnglishEspañolFrançais日本語한국어Português
  • Se connecterDémarrer

Comment on a GitHub issue

|View as Markdown (English)

Creates a new comment on an existing GitHub issue.

For authentication setup, see GitHub issue actions.

The following inputs are available for this action.

Input

Type

Description

Example

token

Required. String

GitHub Personal Access Token (fine-grained or classic) stored as a secret. Fine-grained PATs require Issues: Read and write permission. Classic PATs require repo scope.

"${{ :secrets:github-PAT-token }}"

owner

Required. String

The account owner of the repository (user or organization login). Case-insensitive.

"octocat"

repo

Required. String

Repository name without the .git suffix. Case-insensitive.

"Hello-World"

issueNumber

Required. Int

The number that identifies the issue.

1347

body

Required. String

The contents of the comment.

"Issue has been investigated and resolved."

selectors

Optional. List

JQ selectors to extract values from the response.

[{"name": "commentId", "expression": ".id"}]

This action returns the following outputs.

Output

Type

Example

response

Object

{
"id": 1,
"html_url": "https://github.com/octocat/Hello-World/issues/1347#issuecomment-1",
"body": "Issue has been investigated and resolved.",
"user": {
"login": "octocat"
},
"created_at": "2011-04-14T16:00:49Z",
"updated_at": "2011-04-14T16:00:49Z",
"issue_url": "https://api.github.com/repos/octocat/Hello-World/issues/1347"
}

success

Boolean

success: true | false

errorMessage

String

Contains the GitHub API error response body.

Workflow example

name: github_comment_issue_workflow
description: Add a comment to a GitHub issue
steps:
- name: add_comment
type: action
action: gitHub.issue.comment
version: 1
inputs:
token: ${{ :secrets:github-PAT-token }}
owner: your_user_name
repo: test-workflow
issueNumber: 7
body: |
This issue has been investigated.
Runbook: https://runbooks.example.com/checkout-5xx
next: end
Droits d'auteur © 2026 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.