list_task_credentials takes no parameters but built its JSON Schema with
obj(map[string]any{}, ""), emitting {"type":"object","required":[""],
"properties":{}}. The required array contains an empty string, which strict
function-call validators reject. Observed with DeepSeek through an
OpenAI-compatible gateway (format "openai"):
openai: status 400 invalid_tool_spec -
"function.parameters.required must be an array of non-empty strings"
Because the tool is in the worker toolset, every worker run fails before the
first tool call (terminal state model_error); the planner and main agent are
unaffected since they don't load it. Anthropic/OpenAI accept the malformed
schema silently, so it only surfaces on stricter providers.
Pass no required args so obj omits the required key entirely:
{"type":"object","properties":{}}.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>