mirror of
https://gitea.com/gitea/gitea-mcp.git
synced 2026-08-28 11:07:44 +00:00
feat(connector): add search and fetch tools for ChatGPT connectors
Add a new "connector" domain exposing exactly-named "search" and "fetch" MCP tools for ChatGPT-style connector compatibility (gitea#84). search looks up repositories via the existing SearchRepos SDK call, optionally resolving an owner/org name to an owner ID, and returns concise entries (id, name, url, html_url). fetch reuses GetContents to read a file and decodes its base64 content, returning path, sha, size, encoding and the decoded content. Registers connector.Tool in operation.go and documents the two tools in all three README tables. Co-Authored-By: Codet <codet@commitgo.dev> (GPT-5-Codex)
This commit is contained in:
@@ -14,6 +14,7 @@ import (
|
||||
"time"
|
||||
|
||||
"gitea.com/gitea/gitea-mcp/operation/actions"
|
||||
"gitea.com/gitea/gitea-mcp/operation/connector"
|
||||
"gitea.com/gitea/gitea-mcp/operation/issue"
|
||||
"gitea.com/gitea/gitea-mcp/operation/label"
|
||||
"gitea.com/gitea/gitea-mcp/operation/milestone"
|
||||
@@ -47,7 +48,7 @@ var (
|
||||
domainTools = []*tool.Tool{
|
||||
user.Tool, actions.Tool, repo.Tool, notification.Tool, issue.Tool,
|
||||
label.Tool, milestone.Tool, packages.Tool, pull.Tool, search.Tool,
|
||||
version.Tool, wiki.Tool, timetracking.Tool,
|
||||
version.Tool, wiki.Tool, timetracking.Tool, connector.Tool,
|
||||
repo.FileTool, repo.BranchTool, repo.TagTool, repo.CommitTool, repo.ReleaseTool,
|
||||
}
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user