{"record":{"id":"d9bcf3d84c1c057e","repo":"alibaba/nacos","slug":"10000-d9bcf3","errorCode":"10000","errorMessage":"Required parameter 'dataId' type String is not present","messagePattern":"Required parameter 'dataId' type String is not present","errorType":"validation","errorClass":"NacosApiException","httpStatus":400,"severity":"error","filePath":"config/src/main/java/com/alibaba/nacos/config/server/model/form/ConfigForm.java","lineNumber":255,"sourceCode":"        return grayVersion;\n    }\n    \n    public void setGrayVersion(String grayVersion) {\n        this.grayVersion = grayVersion;\n    }\n    \n    public int getGrayPriority() {\n        return grayPriority;\n    }\n    \n    public void setGrayPriority(int grayPriority) {\n        this.grayPriority = grayPriority;\n    }\n    \n    @Override\n    public void validate() throws NacosApiException {\n        if (StringUtils.isBlank(dataId)) {\n            throw new NacosApiException(HttpStatus.BAD_REQUEST.value(), ErrorCode.PARAMETER_MISSING,\n                \"Required parameter 'dataId' type String is not present\");\n        } else if (StringUtils.isBlank(group)) {\n            throw new NacosApiException(HttpStatus.BAD_REQUEST.value(), ErrorCode.PARAMETER_MISSING,\n                \"Required parameter 'group' type String is not present\");\n        }\n    }\n    \n    /**\n     * Validate form parameter and include validate `content` parameters.\n     *\n     * @throws NacosApiException NacosApiException\n     */\n    public void validateWithContent() throws NacosApiException {\n        validate();\n        if (StringUtils.isBlank(content)) {\n            throw new NacosApiException(HttpStatus.BAD_REQUEST.value(), ErrorCode.PARAMETER_MISSING,\n                \"Required parameter 'content' type String is not present\");\n        }","sourceCodeStart":237,"sourceCodeEnd":273,"githubUrl":"https://github.com/alibaba/nacos/blob/9b989acdf181d00898f2e8839257bb2b2a3cefe3/config/src/main/java/com/alibaba/nacos/config/server/model/form/ConfigForm.java#L237-L273","documentation":"Thrown by ConfigForm.validate() when dataId is blank. Returns HTTP 400 code 10000 (PARAMETER_MISSING). dataId is the primary identifier of a configuration item and is mandatory for nearly all config operations. This is the base form validator inherited by ConfigFormV3.","triggerScenarios":"Any config API (publish, query, delete, history) that calls configForm.validate() with dataId omitted or empty. Common in POST/GET requests missing the dataId param.","commonSituations":"Form binding failure where dataId is not submitted; URL-encoded request missing dataId; typo in the parameter name.","solutions":["Ensure dataId is a non-blank string in the request body or query string.","Validate dataId client-side before calling the API.","Check that the form field name matches 'dataId' exactly."],"exampleFix":"// before\nPOST /v3/admin/cs/config  { \"group\":\"G\", \"content\":\"...\" } // no dataId\n// after\nPOST /v3/admin/cs/config  { \"dataId\":\"app.yml\", \"group\":\"G\", \"content\":\"...\" }","handlingStrategy":"validation","validationCode":"if (StringUtils.isBlank(dataId)) {\n    throw new IllegalArgumentException(\"dataId is required\");\n}","typeGuard":null,"tryCatchPattern":"try { configApi.publish(form); }\ncatch (NacosApiException e) {\n    if (e.getErrCode() == ErrorCode.PARAMETER_MISSING.getCode())\n        { /* supply dataId */ } else throw e;\n}","preventionTips":["Always include a non-blank dataId in config requests.","Validate the form client-side before the API call."],"tags":["config","parameter-missing","validation","form"],"backgroundTag":null,"analyzedSha":"9b989acdf181d00898f2e8839257bb2b2a3cefe3","analyzedAt":"2026-08-14T07:17:31.569Z","schemaVersion":2},"datasetVersion":"2026-08-14T10:17:34.591Z"}