我也是一样的错误,不知道怎么解决
analysis数据分析接口无效4月4日开始,小游戏上这一接口就失效了,请求就返回这个错误 {‘errcode’: 61502, ‘errmsg’: ‘this is game miniprogram, data api is not supported hint: [_36I7a00981504]’} 现在需要通过公众平台去抓取数据,每次要去扫码,几百款下来吐血,官方能否给个答复? 接口:https://developers.weixin.qq.com/miniprogram/dev/api-backend/analysis.getDailyVisitTrend.html
2021-08-25这个问题已经解决了,其实很多人解决了没有说或者不屑于再说,我提交了一次代码后就正常了
我的微信小程序使用自己的云函数和云数据库交互一定要开启云函数本地调试才正常?我在自己windows10的机器上,用小程序开发环境,用云函数读取或者插入数据到云数据库, 有的报错,有的不保错,却没有数据写入或者得到,当我打开云函数本地调试,就一切都正常了, 因为官方也没有说,是否本地开发的调试就得开启云函数本地调试,提交线上就正常了呢
2020-09-01我也这个情况,如果这是正常,为啥官网没有提呢?
云函数本地调试无法操作数据库?node.js:1 [error] Unhandled Rejection at: Promise {<rejected>: CloudSDKError: errCode: -1 unknown error | errMsg: collection.get:fail Error: 400 Bad Req…}__proto__: Promise[[PromiseStatus]]: "rejected"[[PromiseValue]]: CloudSDKError: errCode: -1 unknown error | errMsg: collection.get:fail Error: 400 Bad Request ; at collection.get api; at returnAsCloudSDKError (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:6086:16) at Object.returnAsFinalCloudSDKError (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:6100:15) at Promise (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:1472:32) at processTicksAndRejections (internal/process/task_queues.js:86:5)errCode: -1errMsg: "collection.get:fail Error: ↵ 400 Bad Request↵ ; at collection.get api; "message: (...)stack: "Error: errCode: -1 unknown error | errMsg: collection.get:fail Error: ↵ 400 Bad Request↵ ; at collection.get api; ↵ at returnAsCloudSDKError (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:6086:16)↵ at Object.returnAsFinalCloudSDKError (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:6100:15)↵ at Promise (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:1472:32)↵ at processTicksAndRejections (internal/process/task_queues.js:86:5)"get message: ƒ get()set message: ƒ set(msg)__proto__: Error reason: CloudSDKError: errCode: -1 unknown error | errMsg: collection.get:fail Error: 400 Bad Request ; at collection.get api; at returnAsCloudSDKError (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:6086:16) at Object.returnAsFinalCloudSDKError (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:6100:15) at Promise (C:\Users\Administrator\WeChatProjects\miniprogram-3\cloudfunctions\obj\node_modules\wx-server-sdk\index.js:1472:32) at processTicksAndRejections (internal/process/task_queues.js:86:5) // 云函数入口文件 const cloud = require('wx-server-sdk') const rp = require('request-promise') const fs = require('fs') const path = require('path') cloud.init({ env: 'jbd-test-6c456c' })const db = cloud.database() var url = require("url") // 云函数入口函数 exports.main = async (event, context) => { db.collection('objects').get({ success: function (res) { // res.data 是一个包含集合中有权限访问的所有记录的数据,不超过 20 条 console.log(res.data) } }) } 代码为最简单的文档中给出的测试代码 package.json { "name": "obj", "version": "1.0.0", "description": "", "main": "index.js", "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, "author": "", "license": "ISC", "dependencies": { "request-promise": "^4.2.5", "wx-server-sdk": "^1.8.2" } }
2020-08-28