Workflow code doesn't have access to built-in Node module

If I need to use existing modules that rely on NodeJS modules, is there a way I can get them to work?

Usually the answer is to put that code in an Activity. Occasionally ignoreModules is a valid option:

If the module both depends on and uses a built-in at runtime, and you’re sure you don’t want to use it in an activity, then the solution is to fork the module and remove the use of the built-in module.