You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Required Args
Previously the required list of method parameters assumes that all args are required (this was before ToolArg.required was added with a default value of true).
If ToolArg.required = false then the argument should not be shown in Tools/list.
Given:
That ToolArg.required = false for e.g:
public boolean testToolArgNotRequired(@ToolArg(name = "value", description = "boolean value", required = false) boolean value) When
We call the Tools/list method to list all of the Tools Then
Ensure that for the existing tools/list operation there is a test in place that checks that the array called "required" is empty in the JSON response for both primitive and an object types. We can use the existing io.openliberty.mcp.internal.fat.tool.ToolTest.testToolList() method for this.