GitHubFileEditor
A Haystack component for editing files in GitHub repositories.
Basic Information
- Type:
haystack_integrations.github.src.haystack_integrations.components.connectors.github.file_editor.GitHubFileEditor
Inputs
| Parameter | Type | Default | Description |
|---|---|---|---|
| command | Union[Command, str] | Operation to perform ("edit", "undo", "create", "delete") | |
| payload | Dict[str, Any] | Dictionary containing command-specific parameters | |
| repo | Optional[str] | None | Repository in owner/repo format (overrides default if provided) |
| branch | Optional[str] | None | Branch to perform operations on (overrides default if provided) |
Outputs
| Parameter | Type | Default | Description |
|---|---|---|---|
| result | str | Dictionary containing operation result |
Overview
Work in Progress
Bear with us while we're working on adding pipeline examples and most common components connections.
A Haystack component for editing files in GitHub repositories.
Supports editing, undoing changes, deleting files, and creating new files through the GitHub API.
Usage Example
components:
GitHubFileEditor:
type: github.src.haystack_integrations.components.connectors.github.file_editor.GitHubFileEditor
init_parameters:
Parameters
Init Parameters
These are the parameters you can configure in Pipeline Builder:
| Parameter | Type | Default | Description |
|---|---|---|---|
| github_token | Secret | Secret.from_env_var('GITHUB_TOKEN') | GitHub personal access token for API authentication |
| repo | Optional[str] | None | Default repository in owner/repo format |
| branch | str | main | Default branch to work with |
| raise_on_failure | bool | True | If True, raises exceptions on API errors |
Run Method Parameters
These are the parameters you can configure for the component's run() method. This means you can pass these parameters at query time through the API, in Playground, or when running a job. For details, see Modify Pipeline Parameters at Query Time.
| Parameter | Type | Default | Description |
|---|---|---|---|
| command | Union[Command, str] | Operation to perform ("edit", "undo", "create", "delete") | |
| payload | Dict[str, Any] | Dictionary containing command-specific parameters | |
| repo | Optional[str] | None | Repository in owner/repo format (overrides default if provided) |
| branch | Optional[str] | None | Branch to perform operations on (overrides default if provided) |
Was this page helpful?