Commit Graph

7 Commits

Author SHA1 Message Date
Ben
f8eda211e6 Fix gitea_api_call to accept both string and dict for params/body
All checks were successful
Build and Push Gitea MCP Docker Image / build (push) Successful in 17s
The gitea_api_call tool was failing when MCP clients passed JSON objects
for the body or params parameters. The issue was that the tool signature
only accepted string types, but MCP frameworks parse JSON strings into
dicts before passing them to the tool.

This fix updates the function signature to accept Union[str, dict] for
both params and body parameters, and handles both cases appropriately.

Fixes #1
2025-12-26 20:02:26 +00:00
Ben
77a945bd1e feat: smart error extraction for failed workflow logs
All checks were successful
Build and Push Gitea MCP Docker Image / build (push) Successful in 1m25s
For failed jobs, instead of just showing the tail (which is cleanup),
now scans for error patterns (, Error:, FAILED, TypeScript errors,
npm/pnpm errors, exit codes, etc.) and shows context around them.

Falls back to tail for successful jobs or if no errors detected.
2025-12-22 14:50:03 +00:00
Ben
7c4b35dc68 fix: correct job ID discovery for workflow logs
All checks were successful
Build and Push Gitea MCP Docker Image / build (push) Successful in 19s
Gitea uses different ID namespaces for tasks vs jobs. Now searches
the /actions/jobs endpoint and matches by html_url containing the
run_number to find the correct job_id for logs retrieval.
2025-12-22 14:40:04 +00:00
Ben
d43cc4717c feat: add get_workflow_run_logs tool for easy CI log retrieval
All checks were successful
Build and Push Gitea MCP Docker Image / build (push) Successful in 25s
- Fetches logs by run_number (or defaults to most recent run)
- Returns last 50 lines by default (configurable via tail_lines)
- Handles Gitea's task/job ID mapping automatically
- Updates API reference with correct workflow endpoints
2025-12-22 14:21:27 +00:00
Ben
f83ddd59bd fix: handle non-JSON responses (logs endpoint returns text)
All checks were successful
Build and Push Gitea MCP Docker Image / build (push) Successful in 20s
- Check content-type header before parsing as JSON
- Return raw text wrapped in dict for non-JSON responses
- Also accept both GITEA_URL and GITEA_HOST env vars
2025-12-22 05:57:26 +00:00
Ben
418af129af fix: simplify health check to liveness probe
All checks were successful
Build and Push Gitea MCP Docker Image / build (push) Successful in 17s
Health check no longer validates Gitea connectivity - this is checked
when tools are actually called. Fixes Docker health check failures when
container networking can't resolve external Gitea URL.
2025-12-22 05:16:18 +00:00
Ben
1375175290 Initial commit: Gitea MCP Server
- 6 curated MCP tools (get_my_user_info, search_repos, list_my_repos, get_repo, list_repo_issues, list_repo_commits)
- API pass-through tool (gitea_api_call) for complete API coverage
- Curated API reference resource (gitea://api-reference)
- Health check endpoint
- Docker support with health checks
2025-12-22 04:46:35 +00:00