Gitea icon

Gitea

Interact with Gitea via API

Actions393

Overview

This node interacts with a Gitea server via its API to retrieve information about repository variables. Specifically, the "Get Repo Variable" operation fetches the value of a named variable from a specified repository owned by a given user or organization. This is useful in automation workflows where repository-level configuration or secrets stored as variables need to be accessed dynamically.

Practical examples include:

  • Retrieving deployment keys or environment-specific settings stored as repository variables.
  • Accessing feature flags or toggles configured at the repository level.
  • Automating CI/CD pipelines that require fetching secret variables before running jobs.

Properties

Name Meaning
Owner The username or organization name that owns the repository.
Repo The name of the repository from which to get the variable.
Variablename The exact name of the repository variable to retrieve.

Output

The node outputs JSON data representing the requested repository variable. This typically includes the variable's name and its corresponding value as stored in the repository. The output structure allows subsequent nodes in the workflow to use this variable's value for further processing.

No binary data output is involved in this operation.

Dependencies

  • Requires an active connection to a Gitea instance via its API.
  • Needs an API authentication token credential configured in n8n to authorize requests.
  • The base URL of the Gitea server must be set in the credentials.

Troubleshooting

  • Common issues:

    • Incorrect owner or repository names will result in errors or empty responses.
    • Requesting a variable name that does not exist in the repository will likely cause a "not found" error.
    • Authentication failures if the API token is missing, expired, or lacks sufficient permissions.
  • Error messages and resolutions:

    • 401 Unauthorized: Check that the API token credential is correctly configured and has access rights.
    • 404 Not Found: Verify the owner, repository, and variable name are correct and exist.
    • Network errors: Ensure the Gitea server URL is reachable from the n8n instance.

Links and References

Discussion