Documentation
¶
Index ¶
Constants ¶
View Source
const (
// GetUserInfoToolName is the instruction to get authenticated user information
GetUserInfoToolName = "get_user_info"
)
View Source
const (
SearchUsers = "search_users"
)
Variables ¶
View Source
var GetUserInfoTool = mcp.NewTool( GetUserInfoToolName, mcp.WithDescription("This is a tool from the gitee MCP server.\nGet information about the authenticated user"), )
GetUserInfoTool defines the tool for getting authorized user information
View Source
var SearchUsersTool = mcp.NewTool(SearchUsers, mcp.WithDescription("Search users on Gitee"), mcp.WithString( "q", mcp.Description("Search keywords"), mcp.Required(), ), mcp.WithNumber( "page", mcp.Description("Page number"), mcp.DefaultNumber(1), ), mcp.WithNumber( "per_page", mcp.Description("Number of results per page"), mcp.DefaultNumber(20), ), )
Functions ¶
func GetUserInfoHandleFunc ¶
func GetUserInfoHandleFunc() server.ToolHandlerFunc
GetUserInfoHandleFunc returns a server.ToolHandlerFunc for handling get user info requests
func GetUserInfoHandler ¶
func GetUserInfoHandler(ctx context.Context, request mcp.CallToolRequest) (*mcp.CallToolResult, error)
GetUserInfoHandler handles the request to get authorized user information
func SearchUsersHandler ¶
func SearchUsersHandler(ctx context.Context, request mcp.CallToolRequest) (*mcp.CallToolResult, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.