Gitea icon

Gitea

Interact with Gitea via API

Actions393

Overview

This node interacts with the Gitea API to test a specific webhook configured on a repository. The "Repo Test Hook" operation triggers a test delivery of the webhook identified by its ID for a given repository owned by a specified user or organization. This is useful for developers and DevOps engineers who want to verify that their webhooks are correctly set up and receiving payloads as expected without having to perform actual repository events.

Practical examples include:

  • Testing webhook integrations after initial setup to ensure the receiving service processes events correctly.
  • Debugging webhook payloads by triggering test deliveries manually.
  • Automating webhook validation in CI/CD pipelines.

Properties

Name Meaning
Owner The owner (user or organization) of the repository where the webhook is configured.
Repo The name of the repository containing the webhook to be tested.
Id The unique identifier of the webhook to test.
Ref Optional. The name of the commit, branch, or tag to specify which commit will be loaded into the webhook payload during the test.

Output

The node outputs JSON data representing the response from the Gitea API after triggering the test webhook. This typically includes details about the webhook delivery attempt, such as status, response, and any errors encountered. The output does not include binary data.

Dependencies

  • Requires an API key credential for authenticating with the Gitea instance.
  • The node expects the base URL of the Gitea server to be provided via credentials.
  • No additional external dependencies beyond the Gitea API and n8n's HTTP request capabilities.

Troubleshooting

  • Common issues:

    • Invalid or missing API credentials can cause authentication failures.
    • Incorrect repository owner or repo name will result in "not found" errors.
    • Providing an invalid webhook ID will cause the test to fail with an error indicating the hook does not exist.
    • If the ref parameter is incorrect or points to a non-existent commit/branch/tag, the webhook payload may not be generated properly.
  • Error messages:

    • Authentication errors: Verify that the API key credential is correct and has sufficient permissions.
    • 404 Not Found: Check that the owner, repo, and webhook ID are accurate.
    • 400 Bad Request: Ensure the ref value is valid if provided.

Links and References

Discussion