Extend check-comment.sh to parse issues event payloads; document issue_comment + issues opened as supported workflow triggers. Co-authored-by: Cursor <cursoragent@cursor.com>
Cursor Gitea Agent
A Gitea Action for self-hosted Action Runners that enables Cursor AI assistance in your Gitea repository. Mention @cursor in an issue or pull request comment to get AI-powered help.
Based on flow96/cursor-gitea-agent, adapted for gitea.schwenk.online.
Prerequisite
Action Runners must be set up and working on your Gitea instance.
Setup
- Create a
cursoruser in your Gitea instance. The name must becursor— that is the trigger word and bot identity. - Log in as the cursor user and create an API token with repository access. Store it as a secret, then log out.
- Add the cursor user as a member to repositories where you want AI assistance.
- Add the workflow below to your repository's
.gitea/workflows/directory. - Store secrets in the repository (or org). Gitea secret names are case-insensitive, alphanumeric/underscore only, and must not start with
GITEA_orGITHUB_:CURSOR_API_KEY— Cursor API keyCURSOR_BOT_TOKEN— Gitea API token for thecursorbot user
Workflow file
Add this workflow to your repository's .gitea/workflows/ directory:
name: Cursor Agent
on:
issue_comment:
types: [created]
issues:
types: [opened]
jobs:
cursor:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: https://gitea.schwenk.online/froxxxy/cursor-gitea-agent@main
with:
cursor_api_key: ${{ secrets.CURSOR_API_KEY }}
gitea_token: ${{ secrets.CURSOR_BOT_TOKEN }}
gitea_base_url: https://gitea.schwenk.online
ai_model: composer-2.5
# push_to_default_branch: "false" # optional — push to default branch instead of opening a PR
# agent_timeout: 5m # optional — max agent runtime (default 5m)
ai_model is optional — it defaults to composer-2.5 when omitted.
For playground repos that commit directly to the default branch (no PR workflow):
- uses: https://gitea.schwenk.online/froxxxy/cursor-gitea-agent@main
with:
cursor_api_key: ${{ secrets.CURSOR_API_KEY }}
gitea_token: ${{ secrets.CURSOR_BOT_TOKEN }}
gitea_base_url: https://gitea.schwenk.online
push_to_default_branch: "true"
agent_timeout: 10m
Action inputs
| Input | Required | Default | Description |
|---|---|---|---|
cursor_api_key |
yes | — | Cursor API key |
gitea_token |
yes | — | Gitea token for the cursor bot user |
gitea_base_url |
yes | — | Gitea instance URL |
ai_model |
no | composer-2.5 |
Cursor model id |
push_to_default_branch |
no | false |
When "true", agent commits and pushes to the default branch instead of opening a PR |
agent_timeout |
no | 5m |
Maximum runtime for the Cursor agent (timeout duration, e.g. 5m, 30m) |
How it works
When someone mentions @cursor in a new issue (title or body), a new issue/PR comment, or similar:
- The action parses the webhook payload (
GITHUB_EVENT_PATH) and checks for@cursor. - Comments from the
cursoruser are ignored to prevent feedback loops. - Cursor CLI and gitea-mcp are installed only when needed (skipped if already on the runner).
- Cursor runs with gitea-mcp so it can read the repo, comment, and open PRs.
You can ask Cursor to review a PR, refine a feature request, or implement a change and open a PR.
Ask Cursor to refine a feature request
Ask Cursor to implement a feature
Ask Cursor to review a PR
Supported events
issue_commentwithtypes: [created]— issue and PR timeline commentsissueswithtypes: [opened]— new issue if@cursorappears in title or body
pull_request_review_comment is not enabled by default: Gitea's payload uses a review object instead of comment, which is easy to get wrong. Open an issue if you need that trigger tested on your Gitea version.


