刚创建没几天的云环境,调用接口提示资源已过期,需要续费,麻烦看下是怎么回事?
报错信息: Error: errCode: -404011 cloud function execution error | errMsg: cloud.callFunction:fail requestID , cloud function service error code -504002, error message Error: collection.get:fail -501003 exceed request limit. [ResourceUnavailable.ResourceOverdue] Resource has expired. Please renewal fee, but if the problem cannot be solved, contact us. at Object.toSDKError (:41526/var/user/node_modules/wx-server-sdk/index.js:8064) at Object.checkError (:41526/var/user/node_modules/wx-server-sdk/index.js:1421) at Promise (:41526/var/user/node_modules/wx-server-sdk/index.js:1488) at process._tickCallback (:41526/appservice/internal/process/next_tick.js:68) (callid 1614607603581-0.3479458621573275); at cloud.callFunction api; at new g (VM479 WAService.js:2) at c (VM479 WAService.js:2) at I (VM479 WAService.js:2) at e (VM479 WAService.js:2) 云函数代码: // 云函数入口文件 // 云函数入口文件 const cloud = require('wx-server-sdk') cloud.init() const db = cloud.database() // 云函数入口函数 exports.main = async (event, context) => { console.log("获取最新一期的期刊内容") // 获取期刊最新一期内容(按时间排序,最新的在前面,只获取一条) return db.collection('magazineList').orderBy('time','desc').limit(1).get() } 调用处代码: onLoad: function (options) { wx.cloud.callFunction({ name:'getMagazineList' }).then(res=>{ this.data.magezine_number = res.result.data[0].magezine_number // 期刊内容 this.data.classic_list = res.result.data[0].content_list wx.setStorageSync(this.data.magezine_number, this.data.classic_list) // 获取当前期刊最新一页的下标 let index = this.data.classic_list.length - 1 // 更新页面 this.setData({ item:this.data.classic_list[index] }) console.log(this.data.item) }) }, App.js App({ onLaunch: function () { if (!wx.cloud) { console.error('请使用 2.2.3 或以上的基础库以使用云能力') } else { wx.cloud.init({ // env 参数说明: // env 参数决定接下来小程序发起的云开发调用(wx.cloud.xxx)会默认请求到哪个云环境的资源 // 此处请填入环境 ID, 环境 ID 可打开云控制台查看 // 如不填则使用默认环境(第一个创建的环境) env: 'jianwen-masql-9g0o4ju481047301', traceUser: true, }) } this.globalData = {} } })