multica-ai/multica · error
--skill-ids must include at least one skill ID
Error message
--skill-ids must include at least one skill ID
What it means
CLI validation in runAgentSkillsAdd (`multica agent skills add`): --skill-ids was supplied but contained no non-empty IDs after cleanSkillIDsFlag trimming — e.g. '--skill-ids=,,'. Distinct from the flag being absent entirely, which produces the '--skill-ids is required' error.
Solutions
- Pass at least one skill ID in --skill-ids.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at server/cmd/multica/cmd_agent.go:1056 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of multica-ai/multica@2c0912b6ec (2026-08-15).
Data as JSON: /api/errors/6bcdac25b7eae824.
Report an issue: GitHub.
Appendix: source
Thrown at server/cmd/multica/cmd_agent.go:1056
if err := client.PutJSON(ctx, "/api/agents/"+args[0]+"/skills", body, &result); err != nil {
return fmt.Errorf("set agent skills: %w", err)
}
return printAgentSkillsMutationResult(cmd, args[0], result)
}
func runAgentSkillsAdd(cmd *cobra.Command, args []string) error {
client, err := newAPIClient(cmd)
if err != nil {
return err
}
if !cmd.Flags().Changed("skill-ids") {
return fmt.Errorf("--skill-ids is required (comma-separated skill IDs)")
}
cleanIDs := cleanSkillIDsFlag(cmd)
if len(cleanIDs) == 0 {
return fmt.Errorf("--skill-ids must include at least one skill ID")
}
body := map[string]any{
"skill_ids": cleanIDs,
}
ctx, cancel := cli.APIContext(context.Background())
defer cancel()
var result json.RawMessage
if err := client.PostJSON(ctx, "/api/agents/"+args[0]+"/skills/add", body, &result); err != nil {
return fmt.Errorf("add agent skills: %w", err)
}
return printAgentSkillsMutationResult(cmd, args[0], result)
}
func cleanSkillIDsFlag(cmd *cobra.Command) []string {
skillIDs, _ := cmd.Flags().GetStringSlice("skill-ids")View on GitHub (pinned to 2c0912b6ec)