Gitea icon

Gitea

Interact with Gitea via API

Actions393

Overview

This node operation allows users to search for issues within a Gitea instance using various filters and criteria. It is useful for retrieving specific issues or pull requests based on their state, labels, milestones, creation or update times, assignment, and other attributes. Practical applications include tracking open bugs, monitoring pull requests assigned to a user, or filtering issues by priority repository or team.

Properties

Name Meaning
State State of the issue; options: Open, Closed, All
Labels Comma-separated list of label names to filter issues that have any of these labels
Milestones Comma-separated list of milestone names to filter issues that have any of these milestones
Q Search string to query issues
Priority Repo Id Repository ID to prioritize in the results
Type Filter by issue type; options: Issues, Pulls
Since Only show issues updated after this time (RFC 3339 format)
Before Only show issues updated before this time (RFC 3339 format)
Assigned Boolean to filter issues or pulls assigned to the authenticated user
Created Boolean to filter issues or pulls created by the authenticated user
Mentioned Boolean to filter issues or pulls mentioning the authenticated user
Review Requested Boolean to filter pull requests where the authenticated user's review was requested
Reviewed Boolean to filter pull requests reviewed by the authenticated user
Owner Filter by repository owner
Team Filter by team (requires organization owner parameter)
Page Page number of results to return (1-based)
Limit Number of items per page

Output

The output contains a JSON array of issues or pull requests matching the search criteria. Each item in the array represents an issue or pull request with its associated metadata as returned by the Gitea API. The structure typically includes fields such as issue ID, title, state, labels, assignees, creation and update timestamps, and other relevant details.

No binary data output is indicated for this operation.

Dependencies

  • Requires connection to a Gitea instance via its API.
  • An API key credential or equivalent authentication token must be configured in n8n credentials to authorize requests.
  • The base URL for the Gitea API must be set in the credentials configuration.

Troubleshooting

  • Common issues:

    • Authentication failures due to missing or invalid API tokens.
    • Incorrect date formats for Since and Before parameters causing API errors.
    • Pagination parameters (Page and Limit) not set correctly leading to unexpected result counts.
    • Filtering by non-existent labels, milestones, owners, or teams may result in empty responses.
  • Error messages:

    • Unauthorized or 401 errors indicate problems with API credentials.
    • 400 Bad Request errors may occur if query parameters are malformed or invalid.
    • Rate limiting errors from the Gitea API if too many requests are made in a short period.
  • Resolutions:

    • Verify and update API credentials in n8n.
    • Ensure date strings conform to RFC 3339 format.
    • Adjust pagination settings appropriately.
    • Confirm existence of labels, milestones, owners, and teams used in filters.

Links and References

Discussion