Sync events arent getting deleted from the UI.
I tried restarting the Dapp also but it didnāt help.
I hat is the server url? What is the event that you want to delete? Did you try to remove/delete them from code?
Yes, I tried everything.
I tried from UI but didnāt succeed.
I tried from this code but it doesnāt work.
const unwatchAll = async () => {
// code example of creating a sync event from cloud code
await Moralis.start({ serverUrl, appId, masterKey });
let options = { tableName: "approvalforall" };
const tables = ["promotionNFTTransfers", "channels", "approval", "subscriptions", "notifications", "notificationNFTTransfers", "notificationNFTs",
"promotionNFTApprovals", "promotionUpdated", "promotions", "approvalforall", "notificationNFTExtended", "subscribeChannelFromBurn" ]
for (var i: number = 0; i < tables.length; i++) {
Moralis.Cloud.run("coreservices_removeEventSync", {"tableName": tables[i]}, { useMasterKey: true }).then(
(result: any) => {
console.log(result);
}
);
}
};
What happens when it doesnāt work?
Did you try to restart corrservices?
I can take a look later
I delete them on UI, refresh the page and it appears again.
By deleting from ui you mean from the database dashboard or form the admin interface?
From the admin UI, I am trying to delete the events and they arent getting deleted.
Can you please help us out here?
One more question, Are you guys discontinuing the servers?
The plan is to migrate to self hosted servers. You will be able to use streams api for event syncs.
Dude,
We shifted to another account and now the cloudcode is not working.
It always shows this
/******/ (() => { // webpackBootstrap
/******/ /* webpack/runtime/compat */
/******/
/******/ if (typeof __nccwpck_require__ !== 'undefined') __nccwpck_require__.ab = __dirname + "/";
/******/
/************************************************************************/
var __webpack_exports__ = {};
module.exports = __webpack_exports__;
/******/ })()
;
It shows on the console that Cloudcode updated correctly.
Following servers were found:
(0) n
What server do you want to connect to?: 0
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
Changes Uploaded Correctly
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
Changes Uploaded Correctly
Changes Uploaded Correctly
Changes Uploaded Correctly
Changes Uploaded Correctly
BUt nothing happens on the new event firing.
this is what you see when nothing was uploaded, try to upload a simple js file maybe
I tried to upload file js file with these contents only.
const logger = Moralis.Cloud.getLogger();
Same result.
this server has cloud code now
now it isnāt, I had the impression that I saw it
try to upload a file instead of a folder maybe, some difference in parameters
moralis-admin-cli watch-cloud-folder --moralisApiKey myKey --moralisApiSecret mySecret --moralisSubdomain idy0lkjetah4.usemoralis.com --autoSave 1 --moralisCloudfolder /Users/saurav/Programs/ama.fans/mvp-contracts/moralisCloud.js
Everytime I make changes and save to ā/Users/saurav/Programs/ama.fans/mvp-contracts/moralisCloud.jsā The output is
Changes Uploaded Correctly
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
Changes Uploaded Correctly
Changes Uploaded Correctly
Changes Uploaded Correctly
Changes Uploaded Correctly
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
ncc: Version 0.29.2
ncc: Compiling file index.js into CJS
Changes Uploaded Correctly
Changes Uploaded Correctly
Changes Uploaded Correctly
Changes Uploaded Correctly
that is the syntax for a folder and you provide a file, try to provide the folder path at the end
--moralisCloudfolder /Users/saurav/Programs/ama.fans/mvp-contracts
or change the part to something specific to a file