Class WarningsMcpServerExtension
java.lang.Object
io.jenkins.plugins.analysis.core.mcp.WarningsMcpServerExtension
- All Implemented Interfaces:
ExtensionPoint,io.jenkins.plugins.mcp.server.McpServerExtension
@OptionalExtension(requirePlugins="mcp-server")
public class WarningsMcpServerExtension
extends Object
implements io.jenkins.plugins.mcp.server.McpServerExtension
An extension of the for MCP server exposing
AnalysisResult
associated with a given build as a JSON object.-
Nested Class Summary
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.jenkins.plugins.mcp.server.McpServerExtension
getSyncPrompts, getSyncResources, getSyncTools
-
Constructor Details
-
WarningsMcpServerExtension
public WarningsMcpServerExtension()
-
-
Method Details
-
getWarnings
@Tool(description="Retrieves the warnings from static analysis tools associated with a Jenkins build", annotations=) public Map<String,Object> getWarnings(@ToolParam(description="Job full name of the Jenkins job (e.g., \'folder/job-name\')") String jobFullName, @ToolParam(description="Build number (optional, if not provided, returns the test results for last build)",required=false) Integer buildNumber, @ToolParam(description="ID of the check action (optional, if not provided, all warnings are returned)",required=false) String checkId) Retrieves the warnings from static analysis tools.- Parameters:
jobFullName- full job namebuildNumber- build numbercheckId- check action ID- Returns:
- map in the form {checkId1:[{category:"CAT", message:"MSG", type:"TYPE", ...}]}
-