Files
gitea-mcp/pkg/annotation/annotation.go
Ivan Loginov 440547e9c1
Some checks failed
release-nightly / release-image (push) Has been cancelled
first commit
2026-06-05 14:58:55 +03:00

19 lines
459 B
Go

package annotation
import "github.com/mark3labs/mcp-go/mcp"
func ReadOnly(title string) mcp.ToolAnnotation {
t := true
return mcp.ToolAnnotation{Title: title, ReadOnlyHint: &t}
}
func Write(title string) mcp.ToolAnnotation {
f := false
return mcp.ToolAnnotation{Title: title, ReadOnlyHint: &f}
}
func Destructive(title string) mcp.ToolAnnotation {
f, t := false, true
return mcp.ToolAnnotation{Title: title, ReadOnlyHint: &f, DestructiveHint: &t}
}