{"record":{"id":"2bbe6a7c886ccd46","repo":"alibaba/nacos","slug":"parameter-missing-2bbe6a","errorCode":"PARAMETER_MISSING","errorMessage":"Request parameter `skillName` should not be blank.","messagePattern":"Request parameter `skillName` should not be blank\\.","errorType":"exception","errorClass":"NacosApiException","httpStatus":400,"severity":"error","filePath":"ai/src/main/java/com/alibaba/nacos/ai/form/skills/admin/SkillOnlineForm.java","lineNumber":50,"sourceCode":"    \n    @Serial\n    private static final long serialVersionUID = 1L;\n    \n    /**\n     * \"skill\" means enable/disable the whole skill. Otherwise version-level.\n     */\n    private String scope;\n    \n    /**\n     * Version for version-level online/offline.\n     */\n    private String version;\n    \n    @Override\n    public void validate() throws NacosApiException {\n        fillDefaultNamespaceId();\n        if (StringUtils.isBlank(getSkillName())) {\n            throw new NacosApiException(NacosException.INVALID_PARAM, ErrorCode.PARAMETER_MISSING,\n                \"Request parameter `skillName` should not be blank.\");\n        }\n    }\n    \n    public String getScope() {\n        return scope;\n    }\n    \n    public void setScope(String scope) {\n        this.scope = scope;\n    }\n    \n    public String getVersion() {\n        return version;\n    }\n    \n    public void setVersion(String version) {\n        this.version = version;","sourceCodeStart":32,"sourceCodeEnd":68,"githubUrl":"https://github.com/alibaba/nacos/blob/9b989acdf181d00898f2e8839257bb2b2a3cefe3/ai/src/main/java/com/alibaba/nacos/ai/form/skills/admin/SkillOnlineForm.java#L32-L68","documentation":"SkillOnlineForm.validate() requires a non-blank `skillName` to toggle a skill (or a version of it, depending on `scope`) online/offline. Online state is per-skill (or per-skill-version), so the target skill must be named. Uses StringUtils.isBlank; namespaceId defaults to \"public\" via fillDefaultNamespaceId.","triggerScenarios":"Calling the skill online/offline API with skillName missing, empty, or whitespace-only. The form also has optional `scope` and `version` fields for finer-grained toggling, but skillName is always required.","commonSituations":"Assuming the server toggles 'all skills' or the latest; frontend sending only scope/version; path variable not bound to skillName.","solutions":["Include `skillName` of the skill to toggle.","Confirm the skill exists via list/detail.","If toggling a specific version, also send `version`; if scoping, send `scope`."],"exampleFix":"// before\n{\"scope\":\"version\",\"version\":\"1.0.0\"}\n// after\n{\"skillName\":\"my-skill\",\"scope\":\"version\",\"version\":\"1.0.0\"}","handlingStrategy":"validation","validationCode":"// Before calling skill online/offline\nif (skillName == null || skillName.isBlank()) {\n    throw new IllegalArgumentException(\"skillName is required to toggle online state\");\n}","typeGuard":"// TypeScript\nconst hasSkillName = (s?: string | null): boolean =>\n  s != null && s.trim().length > 0;","tryCatchPattern":"try {\n    form.validate();\n} catch (NacosApiException e) {\n    // skillName missing\n}","preventionTips":["Bind the skill from the selected row; don't expect server inference.","If toggling a version, also send version and scope.","Disable the toggle UI until a skill is selected."],"tags":["validation","skill-api","required-field","skill-name","lifecycle"],"backgroundTag":null,"analyzedSha":"9b989acdf181d00898f2e8839257bb2b2a3cefe3","analyzedAt":"2026-08-14T07:17:31.569Z","schemaVersion":2},"datasetVersion":"2026-08-14T10:17:34.591Z"}