Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Help API Scripts Disabled

Hi Everyone Last night the Combat Master script wasn't working so now I'm looking into it and says: Your scripts are currently disabled due to an error that was detected. Please make appropriate changes to your script's code and click the "Save Script" button. We will then attempt to start running the scripts again.  More info...  If this script was installed from the Script Library, you might find help in the Community API Forum. For reference, the error message generated was:  TypeError: Cannot read property 'id' of undefined TypeError: Cannot read property 'id' of undefined at apiscript.js:669:64 at Function.each (/home/node/d20-api-server/node_modules/underscore/underscore.js:193:9) at changeHandler (apiscript.js:666:16) at eval (eval at <anonymous> (/home/node/d20-api-server/api.js:154:1), <anonymous>:65:16) at Object.publish (eval at <anonymous> (/home/node/d20-api-server/api.js:154:1), <anonymous>:70:8) at TrackedObj.set (/home/node/d20-api-server/api.js:1055:14) at updateLocalCache (/home/node/d20-api-server/api.js:1345:18) at /home/node/d20-api-server/api.js:1557:7 at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560 at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147) This same error message and the "at"s come up for several other scripts. Any help is much appreciated!
Is combat master the only API you have installed? Are you using the One-Click Version or the most recently updated one? The API in general was running slow lastnight as well so is it still happening today?
Just went into the game settings and the API still has the same disabled message It's CombatMaster2.0, but I have other scripts loaded, and some others aren't working as well
When you are running scripts, if any script throws an error, it will shut down the sandbox for you and all the scripts will stop functioning.  All you have to do in that case is open up the API page and click on the blue "Restart API Sandbox" button.  Scripts can throw errors for various reasons, so typically it's not something that will happen often unless you have modified a script yourself or you are using a script that wasn't heavily debugged.  If you are noticing errors happening constantly, I'd suggest disabling scripts individually until you figure out which one is causing problems - it would probably be most efficient to start with the last script you installed and worked backwards.  Sometimes the script error log will have some kind of indication of which script is causing the issue (the name of the script may be included or what type of object is causing the issue) and that can help track things down as well.
Awesome thanks for all of that!