第三方平台为授权的小程序帐号上传小程序代码报47001问题

第三方平台为授权的小程序帐号上传小程序代码报47001问题

  1. 首先,Post数据要求ext_json需为string类型,
    在这里插入图片描述

  2. 其次, extJson传入后端时,要确保【"】双引号未被转译为【& q u o t ;】,

  3. 最后,检查下数据传参名字是否写错,例ext_json在这个接口是以【_】连接命名而不是驼峰式。
    JSONObject json = new JSONObject();
    json.accumulate(“template_id”, templateId);
    json.accumulate(“ext_json”, extJson);
    json.accumulate(“user_version”, userVersion);
    json.accumulate(“user_desc”, userDesc);
    String retStr = HttpsUtil.post(url, json.toString());

  4. 这样就可以基本避免出现47001了。

猜你喜欢

转载自blog.csdn.net/Lossdate/article/details/89703451