[It looks like the post I was replying to was deleted, so I hope you already solved the issue]
I am not exactly sure why you are seeing that error, but I remember a discussion about the order of loading and execution of the script files may be a bit difficult to control.
construct.net/en/make-games/manuals/construct-3/scripting/using-scripting/script-files
One simple way around this is to put all your scripts in one big file, but I think one of your files is big and minified.
So another way to do this is to load the script files in the order you want by putting the files in the Project Files folder and then in the Project Scripts folder use the default script and load them in the order you want:
runOnStartup(async runtime =>
{
runtime.assets.loadScripts("script1.js", "script2.js", "script3.js")
// This code runs on startup with
// the 'runtime' variable available
});
See: construct.net/en/make-games/manuals/construct-3/scripting/scripting-reference/interfaces/iassetmanager
Interesting project, I also thought about doing something similar with a custom token, I was going to do the token issuing on a Playfab server to have a little more control (e.g. player registration, limits on tokens created, a little authentication, etc.)