> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fetchhive.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GitHub

> Manage GitHub repositories, issues, pull requests, and workflow runs via your connected account.

Use GitHub when your workflow needs repository, issue, pull request, or workflow-run actions. It fits steps that create, update, find, or review code collaboration work.

## Configuration

| Option | Required | Description |
| - | - | - |
| Name | No | Label for the step in the workflow canvas. |
| Authentication | Yes | The connected GitHub account to use for this step. |
| Action | Yes | The GitHub action to perform (for example Create issue, Get pull request, List pull requests, Create pull request). |
| Arguments | Yes | Per-action form fields generated from the action's schema. Each text field has an **Insert Variable** button for injecting `{{placeholder}}` values. A **Raw JSON** tab is available for advanced usage. |
| When the step fails | No | Controls whether the workflow should **Terminate Workflow** or **Continue** if this step fails. |

Before you configure this step, connect GitHub in **Integrations** for your workspace using the sign-in flow. If no active connection is available, the step shows a warning with a link to **Integrations** instead of the account selector.

## Arguments form

When you select an action, the **Arguments** section renders a form driven by the action's input schema.

Switch to the **Raw JSON** tab when you prefer to write the full arguments object by hand. Changes in either tab stay in sync.

## Common actions

| Action | Description |
| - | - |
| **Create issue** | Creates a new issue in a repository. |
| **Get pull request** | Retrieves a specific pull request by number. |
| **List pull requests** | Lists pull requests for a repository. |
| **Create pull request** | Creates a pull request from one branch to another. |
| **Request reviewers** | Requests reviewers for a pull request. |
| **Mark pull request ready** | Marks a draft pull request as ready for review. |
| **Check pull request merged** | Checks whether a pull request has been merged. |
| **List repository issues** | Lists issues and pull requests in a repository. |
| **Get issue comments** | Retrieves comments for an issue or pull request. |
| **Create issue comment** | Creates a comment on an issue or pull request. |
| **Add assignees** | Adds one or more assignees to an issue. |
| **Add labels** | Adds labels to an issue and creates missing labels. |
| **Close issue** | Closes an open issue. |
| **Reopen issue** | Reopens a closed issue. |
| **List workflows** | Lists GitHub Actions workflows in a repository. |

Destructive actions, such as deleting records, are not available in the workflow action picker.

## Output

This step stores the GitHub response as the step output. The shape of the response depends on the action.

Use the full output reference in later steps:

```text theme={null}
{{STEP_IDENTIFIER.output}}
```

## Example

1. Open **Integrations** and connect GitHub if you have not already done that.
2. Add a **GitHub** step to your workflow.
3. Select a connected account in **Authentication**.
4. Choose **Create issue** in **Action**.
5. Fill in the required fields. Use **Insert Variable** to reference an earlier step's output for any field value.
6. Click **Run** in the step header to test the action, then review the returned payload in **Output**.

## Use cases

### Triage a new bug report

1. Create issue
2. Add labels
3. Add assignees

### Review a pull request

1. Get pull request
2. Request reviewers
3. Mark pull request ready

### Close resolved work

1. List repository issues
2. Close issue
3. Create issue comment

## Notes

* This step depends on a connected GitHub integration in your workspace.
* The workflow action picker shows a curated set of actions. Agents with the GitHub tool can use more of them.
* The sign-in screen may show third-party authorization branding.

## Using GitHub as an Agent Tool

You can also add GitHub as a tool in the **Agent Editor**. Open the agent, click **Add tool**, and select **GitHub**. In the tool settings panel, choose the connected account the agent should use. The agent calls GitHub actions when they are relevant to the conversation.

See also: [Integrations](https://docs.fetchhive.com/workspace/integrations.md), [Creating and Editing](https://docs.fetchhive.com/workflows/creating-and-editing.md), and [Testing and Iteration](https://docs.fetchhive.com/workflows/testing-and-iteration.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.