{"record":{"id":"6a3eef3878a27d38","repo":"binarywang/WxJava","slug":"errorcode-errormsg-6a3eef","errorCode":null,"errorMessage":"错误代码：{errorCode}, 错误信息：{errorMsg}","messagePattern":"错误代码：(.+?), 错误信息：(.+?)","errorType":"exception","errorClass":"WxErrorException","httpStatus":null,"severity":"error","filePath":"weixin-java-common/src/main/java/me/chanjar/weixin/common/util/http/hc/HttpComponentsMinishopMediaUploadRequestCustomizeExecutor.java","lineNumber":66,"sourceCode":"        .addTextBody(\"upload_type\", this.uploadType)\n        .setMode(HttpMultipartMode.EXTENDED)\n        .build();\n      httpPost.setEntity(entity);\n    }\n    else {\n      HttpEntity entity = MultipartEntityBuilder\n              .create()\n              .addTextBody(\"resp_type\", this.respType)\n              .addTextBody(\"upload_type\", this.uploadType)\n              .addTextBody(\"img_url\", this.imgUrl)\n              .setMode(org.apache.hc.client5.http.entity.mime.HttpMultipartMode.EXTENDED)\n              .build();\n      httpPost.setEntity(entity);\n    }\n    String responseContent = requestHttp.getRequestHttpClient().execute(httpPost, Utf8ResponseHandler.INSTANCE);\n    WxError error = WxError.fromJson(responseContent, wxType);\n    if (error.getErrorCode() != 0) {\n      throw new WxErrorException(error);\n    }\n    log.info(\"responseContent: {}\", responseContent);\n    return WxMinishopImageUploadCustomizeResult.fromJson(responseContent);\n  }\n}\n","sourceCodeStart":48,"sourceCodeEnd":72,"githubUrl":"https://github.com/binarywang/WxJava/blob/1c43293a3c2c9d7e91304b6d037fb017f680d0c6/weixin-java-common/src/main/java/me/chanjar/weixin/common/util/http/hc/HttpComponentsMinishopMediaUploadRequestCustomizeExecutor.java#L48-L72","documentation":"Error \"错误代码：{errorCode}, 错误信息：{errorMsg}\" thrown in binarywang/WxJava.","triggerScenarios":"Thrown at weixin-java-common/src/main/java/me/chanjar/weixin/common/util/http/hc/HttpComponentsMinishopMediaUploadRequestCustomizeExecutor.java:66 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["根据返回的 errorCode 对照微信小店接口文档确认具体错误原因并修正请求参数。","检查 access_token 是否有效、appId/secret 配置是否正确，以及上传媒体格式和大小是否符合要求。"],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"1c43293a3c2c9d7e91304b6d037fb017f680d0c6","analyzedAt":"2026-08-14T02:29:11.060Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}